Fix setter trivial pattern matching.
Add extra rule to match "return null". Don't permit > 3 ins for the
setter pattern due to a bug in register allocation.
Change-Id: I3c0c0d9055021a68ce3454be7661c6ce047329cb
diff --git a/src/compiler/codegen/arm/Thumb2/Gen.cc b/src/compiler/codegen/arm/Thumb2/Gen.cc
index 8e72227..21c995f 100644
--- a/src/compiler/codegen/arm/Thumb2/Gen.cc
+++ b/src/compiler/codegen/arm/Thumb2/Gen.cc
@@ -118,6 +118,9 @@
int fieldOffset;
bool isVolatile;
uint32_t fieldIdx = mir->dalvikInsn.vC;
+ if (cUnit->numIns > 3) {
+ return NULL; // TODO: fix register allocation for many in arguments
+ }
bool fastPath = fastInstance(cUnit, fieldIdx, fieldOffset, isVolatile,
false);
if (!fastPath) {