summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Make a more verbose too many id error message.Yohann Roussel2013-08-281-1/+3
| | | | | | | | | | | This restores the old message, replacing "ids" by "references" and advertising for multidex otpions. Updates dalvik/tests/089-many-methods accordingly. (cherry picked from commit d352de04f03b848e0246119344ea13e7233018f0) Change-Id: I5934bc9fb7812b66c0e38935946cacdf1c35a402
* Fix native allocation tracking on Dalvik.Mathieu Chartier2013-08-233-0/+68
| | | | | | | | | | | | | | | Fixed issue where we had inverted logic when checking for pending exceptions. Changed the logic to not update the native allocation watermarks after concurrent GC since the finalizers may not have been run at this point. Copied over the test from ART for ensuring that it is working. Bug: 10444866 Change-Id: Ie26170f9c4703f11e993233cdc9c5f46396fca84
* Run-test for suspend in an infinite loop.buzbee2013-08-123-0/+111
| | | | | | | Make sure that we can break out of an infinite loop for gc or other purposes. Change-Id: I467a5f4383707b2952901d90444ef95e21a0caba
* Fix inner class access flags and array modifiers.Elliott Hughes2013-06-142-2/+54
| | | | | | | | | Inner class access flags should come from the InnerClass attribute. Array classes should all have the ACC_ABSTRACT modifier set. Bug: https://code.google.com/p/android/issues/detail?id=56267 Change-Id: If4793ee6c7a6b24bf4d32ef05167d81b58011188
* Fix dalvik tests post-conscrypt.Elliott Hughes2013-05-031-1/+1
| | | | Change-Id: I36b942916330a3d6a06fad93dd9aa0533b47ff85
* Fix flakiness in test 080-oom-throw.Elliott Hughes2013-04-112-34/+31
| | | | | | | | | | | The problem was that the instance test could potentially fill the heap close enough to the edge that you'd hit a follow-on OOME in the attempt to print the success message, causing the test to fail. I've also made the code a bit clearer while I'm here. Bug: https://code.google.com/p/android/issues/detail?id=54114 Change-Id: I39127c3ea6a99940fa66ad8763bbbf6c01d308ef
* [x86] FPU stack needs to be reset after double conversionUdayan Banerji2013-04-013-0/+48
| | | | | | | | | The x86 codegen uses the FPU stack for double/float to long conversions. We need to clear out the FPU stack after done, to prevent an eventual stack overflow. Change-Id: I2f306d7c228ad3da2b84faf9f08326769a9417af Signed-off-by: Udayan Banerji <udayan.banerji@intel.com>
* javac should have matching -source and -target flags.Elliott Hughes2013-03-211-1/+1
| | | | Change-Id: I2ac5f0685bd5844252cc334d4040d68e01d39429
* Abstract methods aren't implementations.Elliott Hughes2013-02-223-0/+37
| | | | | | | | | We should only be checking the visibility of actual implementations of interface methods. Intervening abstract methods are allowed to be non-public. Bug: https://code.google.com/p/android/issues/detail?id=42991 Change-Id: I510d0cc6c1f89d161d4ebad7ef058c03fa09e9b0
* Expand test 004-annotations to cover package annotations.Elliott Hughes2013-02-204-0/+26
| | | | | Bug: https://code.google.com/p/android/issues/detail?id=16149 Change-Id: I0fa26a5201fc80a6f049d61d34e403d4cb5c505a
* dvz: remove dead code.Nick Kralevich2013-01-291-36/+24
| | | | | | dvz is never used. Delete it. Change-Id: If2b5ccbf6668a1044a0d57e09ce6d0c0923c6c76
* Fix handling of annotations whose classes are missing at runtime.Elliott Hughes2012-12-173-0/+41
| | | | | Bug: http://code.google.com/p/android/issues/detail?id=39854 Change-Id: I3089b693ff3084b093f991f991ac9273dea7356d
* ExceptionInInitializerError should wrap only non Error exceptions.Elliott Hughes2012-12-103-0/+36
| | | | | | | Backport from dalvik-dev, due to customer demand. Bug: http://code.google.com/p/android/issues/detail?id=41196 Change-Id: I53ef57e54983f2173546463ac78e265ff5dd3284
* [X86] X86 trace JIT compiler supportDong-Yuan Chen2012-07-202-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch provides a fully functional x86 trace JIT compiler for Dalvik VM. It is built on top of the existing x86 fast interpreter with bug fixes and needed extension to support trace JIT interface. The x86 trace JIT code generator was developed independent of the existing template-based code generator and thus does not share exactly the same infrastructure. Included in this patch are: * Deprecated and removed the x86-atom fast interpreter that is no longer functional since ICS. * Augmented x86 fast interpreter to provide interfaces for x86 trace JIT compiler. * Added x86 trace JIT code generator with full JDWP debugging support. * Method JIT and self-verification mode are not supported. The x86 code generator uses the x86 instruction encoder/decoder library from the Apache Harmony project. Additional wrapper extension and bug fixes were added to support the x86 trace JIT code generator. The x86 instruction encoder/decoder is embedded inside the x86 code generator under the libenc subdirectory. Change-Id: I241113681963a16c13a3562390813cbaaa6eedf0 Signed-off-by: Dong-Yuan Chen <dong-yuan.chen@intel.com> Signed-off-by: Yixin Shou <yixin.shou@intel.com> Signed-off-by: Johnnie Birch <johnnie.l.birch.jr@intel.com> Signed-off-by: Udayan <udayan.banerji@intel.com> Signed-off-by: Sushma Kyasaralli Thimmappa <sushma.kyasaralli.thimmappa@intel.com> Signed-off-by: Bijoy Jose <bijoy.a.jose@intel.com> Signed-off-by: Razvan A Lupusoru <razvan.a.lupusoru@intel.com> Signed-off-by: Tim Hartley <timothy.d.hartley@intel.com>
* Avoid method overriding if its super method is inaccessible.Im Sooin2012-07-105-0/+68
| | | | | | | | | | | A call to package private method could be redirected to subclass which was not in the same package. Modified vtable to retain virtual super methods which cannot be accessed. This change affects vtable index in optimized dex. Change-Id: I9cc7e309c305bca12e5061009c4245fb70014681 Signed-off-by: Im Sooin <ciecet@gmail.com>
* Missing zero-checks in JIT compilerMattias Petersson2012-07-106-8/+96
| | | | | | | | Zero-checks were not generated by the JIT compiler for some instructions. This caused crashes instead of the expected ArithmeticException. Change-Id: Ic8041741a7cccc1bd6b8c3c0723ba55a55af856b
* am 90d3e3b3: Merge "Add test cases for concurrent gc and System.arraycopy"Elliott Hughes2012-06-053-0/+91
|\ | | | | | | | | * commit '90d3e3b3999aa22d0cecc4f064e5686c555ad700': Add test cases for concurrent gc and System.arraycopy
| * Add test cases for concurrent gc and System.arraycopyJohannes Carlsson2012-06-053-0/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When System.arraycopy runs at the same time as a concurrent gc the phone will sometimes crash since System.arraycopy was implemented using memmove and memcpy. In current implementation of mememove bytes are copied one at a time. If for instance only 3 out of 4 bytes to an object reference were copied when the thread switch to the gc thread occurred and the gc was scanning the marked objects the gc read an invalid address. The parameters to dvmWriteBarrierArray in one case was also corrected (they are currently not used). The fix itself for this crash is made elsewhere, this commit just adds test cases to verify that this works. Change-Id: I0a8cfd43561b3d5de4bba818993bcf8b40413045
* | Update test 089 expectationsBrian Carlstrom2012-05-171-1/+2
| | | | | | | | Change-Id: I9023d20d1bc68204f932449b5e90fcb455da7a0b
* | am 67feae03: am 4cda226f: am c1052f9a: Merge "Add a test for a dalvikvm ↵Jean-Baptiste Queru2012-02-133-0/+13
|\| | | | | | | | | | | | | \'switch\' bug." * commit '67feae038c9e6f076223335aa308f25d24a3a51e': Add a test for a dalvikvm 'switch' bug.
| * am c1052f9a: Merge "Add a test for a dalvikvm \'switch\' bug."Jean-Baptiste Queru2012-02-133-0/+13
| |\ | | | | | | | | | | | | * commit 'c1052f9a61539f212885555b0b2c110582f11e28': Add a test for a dalvikvm 'switch' bug.
| | * Add a test for a dalvikvm 'switch' bug.Elliott Hughes2012-02-103-0/+13
| | | | | | | | | | | | | | | Bug: http://code.google.com/p/android/issues/detail?id=22344 Change-Id: I3bf9f8a0732876d758bc5378c5d25ad0c8a71684
* | | am 81894b3a: am 2fe129bf: Merge "Updates to the VM tests."Jean-Baptiste Queru2012-02-018-578/+76
|\| | | | | | | | | | | | | | * commit '81894b3aa4215d389a0673826a76a1839f578dcb': Updates to the VM tests.
| * | am 2fe129bf: Merge "Updates to the VM tests."Jean-Baptiste Queru2012-02-0139-608/+976
| |\| | | | | | | | | | | | | * commit '2fe129bf176c32f8b507da813ffa02868ff32604': Updates to the VM tests.
| | * Updates to the VM tests.Elliott Hughes2012-01-3139-608/+976
| | | | | | | | | | | | | | | | | | Bug: http://code.google.com/p/android/issues/detail?id=21599 Bug: http://code.google.com/p/android/issues/detail?id=21597 Change-Id: I9c6d67cd18943eb6fa68104f0ec2fbec5ea9e0ec
| * | am 232c385b: Bug fix for control-flow construction involving nested loops.Ben Cheng2012-01-183-0/+23
| |\ \ | | |/ | |/| | | | | | | * commit '232c385b9ece322d677a48947ab1e052c1e2427c': Bug fix for control-flow construction involving nested loops.
| | * Bug fix for control-flow construction involving nested loops.Ben Cheng2012-01-183-0/+23
| | | | | | | | | | | | | | | Bug: 5884080 Change-Id: Ic2f42abae3e71f9c0729984902396f92902184a3
* | | Tweak Dalvik testsAndy McFadden2012-01-245-9/+119
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 030 - adjust sleep duration so it's not a multiple of the 10-second timeout (and hence less likely to hit edge) 070 - added tests for all "view buffers", both big and little endian, plus a quick check for array() on direct buffers 092 - fixed date format test so it doesn't fail late at night, and added a getISO3Language test Change-Id: Ibc6f1111861a2ec8c69ded28d5e3de08f4ed2bc2
* | | Update and extend Dalvik testsAndy McFadden2012-01-2028-27/+787
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 029 - exercise setDefaultAssertionStatus 031 - enable some tests that were disabled back when our generics support didn't exist. Added new FancyClass test. 034 - print success/fail rather than matching exact exception text 038 - (same as 034) 042 - added new test for bug 5861201, currently disabled 045 - added a bunch of new tests, including one that fails 046 - added new tests, including some for bug 5861201 (the latter are disabled) 068 - loadClass() wants class names with dots, not slashes 086 - (same as 068) 087 - (same as 068) 092 - new test, exercises some locale-specific classes 093 - new test, exercises object serialization 094 - new test, exercises regex code Test 045 now fails, because it's exercising a feature that should work but doesn't. All others pass. Change-Id: I6481bfa88681c4ac8af629cb60797b2708bdeba4
* | | Merge "Bug fix for control-flow construction involving nested loops."Ben Cheng2012-01-183-0/+23
|\ \ \
| * | | Bug fix for control-flow construction involving nested loops.Ben Cheng2012-01-183-0/+23
| | | | | | | | | | | | | | | | | | | | Bug: 5884080 Change-Id: Ic2f42abae3e71f9c0729984902396f92902184a3
* | | | am 9e8b05e4: am a669206d: Merge "cleanup redundant interfaces from iftable ↵Jean-Baptiste Queru2012-01-173-0/+81
|\ \ \ \ | |/ / / |/| / / | |/ / | | | | | | | | | to avoid excessive LinearAlloc use" * commit '9e8b05e4529c4f9bf66d3db21ae79ccbbe97a1dc': cleanup redundant interfaces from iftable to avoid excessive LinearAlloc use
| * / cleanup redundant interfaces from iftable to avoid excessive LinearAlloc useJohannes Rudolph2012-01-133-0/+81
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | In deep interface hierarchies super-interfaces are recursively concatenated to create the iftable. There was no checking for duplicated entries so that the iftable could get pretty large with just a few layers of interfaces up to the point where the LinearAlloc was exceeded completely. This change scans the iftable linearly for existing entries before it adds another one. Issue: http://code.google.com/p/android/issues/detail?id=22586 Change-Id: Idb4a13ca7a52f390661629cf2539930242526876 Signed-off-by: Johannes Rudolph <johannes.rudolph@gmail.com>
* / Admit to not supporting over 65,536 methods.Jesse Wilson2011-12-0910-1019/+9
|/ | | | | | | | | This was previously a work in progress, but that work wasn't completed and the test shouldn't assume the work is complete. Bug: http://code.google.com/p/android/issues/detail?id=22545 Change-Id: I44a9532d96ab548283278ca3218773ea449f8318
* Fix the watchdog test to handle the failure from managed code.Jesse Wilson2011-06-213-30/+14
| | | | | Change-Id: I9691f414b953c7e11791069a574441b993611238 http://b/4144865
* Adjust basis against which enum performance is compared.Jesse Wilson2011-04-182-39/+35
| | | | | | | | | The new basis assumes how much work Enum.valueOf() needs to do and checks that it does just that and little else. It makes no attempt to compute a general speed of the VM or to compare ratios of unrelated operations. Change-Id: I0014fb37cfcf36016e72e97ca182e3836044782e
* Generate code for loops formed with the new builderBen Cheng2011-03-313-0/+64
| | | | | | | | | | | | | | | | Adapt the existing counted loop analysis and range/null check elimination code to work with the new loop building heuristics. Cleaned up the old ad-hoc loop builder. Suspend polling is enabled by default for loops. The backward chaining cell will be used in self-verification and profiling mode. If the loop includes accesses to resolved fields/classes, abort code generation for now and revert to the basic acyclic trace. Added tests/090-loop-formation to make sure the JIT won't choke on such instructions. Change-Id: Idbc57df0a745be3b692f68c1acb6d4861c537f75
* Update a test to handle a different anonymous class name.Jesse Wilson2011-03-301-1/+1
| | | | Change-Id: Ie39f76b9aa7478c39e10165eba122e3aa2834461
* Fix dalvik test 089Andy McFadden2011-03-221-1/+1
| | | | | | | | | The local variable used to hold the field reference was a u2. Also, removed the "don't include debug info" options from the build script. Change-Id: I14b0fd4ae5af8dcd52f4b22e6b8fe9f68fd7bc89
* Replace jumbo opcodes in certain circumstancesAndy McFadden2011-03-141-0/+78
| | | | | | | | | | | | | | With this change we will start using some dexopt-generated "jumbo" opcodes for volatile field accesses and calls to Object.<init>. These are necessary for correctness. Fixed a bug that could prevent volatile fields in huge objects from being handled correctly. Also, return "void" from some functions whose return value is never examined. Change-Id: I2a7fc66b59953ed3a6f4ac507873101de5d101d5
* This test stopped being useful quite a while ago.Dan Bornstein2011-02-173-1121/+0
| | | | Change-Id: I2069770f9b7456e4f3cde692d9a6b929ec7fe067
* Ensure a dalvik-cache directory exists before running dalvik.Carl Shapiro2011-02-111-0/+5
| | | | | | | | | | The dalvik tests require a dalvik-cache directory otherwise dalvikvm will fail with an unhelpful error message. On the device it is safe to assume a dalvik-cache directory exists but this is not a safe assumption on the host. With this change the script tries to create a dalvik-cache directory on the host if it does not exist. Change-Id: Ie0c69ff8dcd68b6b04a763f06861edd308406f69
* Add huge-array OOM testAndy McFadden2011-02-092-0/+18
| | | | | | Added a regression test for allocation of 4GB+ arrays. Change-Id: Ibac82bbba9ef25b0850386a35e0f5b8554abbaa3
* resolved conflicts for merge of d6e32b81 to dalvik-devAndy McFadden2011-02-042-0/+116
|\ | | | | | | Change-Id: Ib038cc0e68651c63dbcf9a0df2a5607ab2c2d6c7
| * Ensure word atomicity in System.arraycopyAndy McFadden2011-02-042-0/+116
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The VM needs to ensure that updates to 16-bit and 32-bit fields and array elements happen atomically. System.arraycopy was calling memmmove(), which in bionic happens to copy a byte at a time. The new plan is to have bionic provide a platform-optimized memmove variant that makes guarantees about word sizes. If it is not present (either because it hasn't been written for the current platform, or we're not linking against bionic), we will use a trivial copy loop. We assume that the memmove-by-word implementation does whatever it needs to for best performance. For example, if the function determines that memcpy() is word-safe and will be faster, it can call that. The VM no longer makes assumptions about the internal workings of libc functions. I also rearranged the code to avoid making indirect calls, reading function addresses from memory, and using integer multiplication instructions when a simple shift will do. (gcc now generates the whole thing as one function.) Also, added some primitive array copy tests to 011-array-copy. Bug 3398352 Change-Id: I4677ee1c87998697a93e61f39a48b3f391e8e11b
* | Expand the "--dev" mode to cover VM development.Ben Cheng2011-01-271-4/+9
| | | | | | | | | | | | | | When specified, print the VM invocation command line too. Also made minor cleanup on the class path to simply the invocation command. Change-Id: I7af0a2c1df15c0e435d2e5c0b2aa0713455db0de
* | am 4482a157: am d50993ff: am 6ff6ec6b: Fix dalvik test 084.Andy McFadden2011-01-202-7/+19
|\| | | | | | | | | * commit '4482a1573b3ec0d3d312a8a6c1af52952d5d02d8': Fix dalvik test 084.
| * Fix dalvik test 084.Andy McFadden2011-01-202-7/+19
| | | | | | | | | | | | | | | | | | | | Two threads were waiting for initialization of a class to complete. There was nothing encouraging one thread to resume execution first, but on single-core devices it always worked out the same way. Bug 3366697 Change-Id: I29430d398dfbd9509d7db2b7db2800d340b29d19
* | am f18a4274: am 6210c50d: am eef67346: Merge "Fix proxy expectation." into ↵Jesse Wilson2011-01-181-1/+1
|\| | | | | | | | | | | | | honeycomb * commit 'f18a427413d1cea7e245256810346837bd88cd8c': Fix proxy expectation.
| * Fix proxy expectation.Jesse Wilson2011-01-181-1/+1
| | | | | | | | Change-Id: I70589302c686387a1f89e8f79eb58c4b6b8214a6