OSDN Git Service

The failure of dx test 105 wasn't actually spurious. Fixed the code.
authorDan Bornstein <danfuzz@android.com>
Wed, 27 Oct 2010 18:51:16 +0000 (11:51 -0700)
committerDan Bornstein <danfuzz@android.com>
Wed, 27 Oct 2010 19:09:55 +0000 (12:09 -0700)
commit9c907e0f7dd74ef351d0116783e088bb9ed68bdb
tree49d8f1fa5e3214a2d56b6d5128cca8cd7f93d30c
parent4fb99d4d390ba06bbbcea2b270b498a2431914dc
The failure of dx test 105 wasn't actually spurious. Fixed the code.

In particular, for array load and store instructions, dx was being too
aggressive about letting the contents of the stack override the
implied type expected by the instructions. This led to cases where dx
would emit code instead of reporting an error.

The failure on the array load side of things implied that there also
needed to be a new regression test on the store side, since the
existing array store test didn't catch this. So, I added that too in
this change.

Finally, I took this opportunity to do minor whitespace-type cleanups
in a couple of related files that I opened during the course of the
investigation.

Change-Id: I72c644f66afb1108ae43a129ac81b010d072155a
dx/src/com/android/dx/cf/code/BytecodeArray.java
dx/src/com/android/dx/cf/code/Simulator.java
dx/src/com/android/dx/rop/type/Type.java
dx/tests/105-verify-load-store-ops/expected.txt
dx/tests/105-verify-load-store-ops/op_aastore2.j [new file with mode: 0644]
dx/tests/105-verify-load-store-ops/run