diff options
Diffstat (limited to 'vm/compiler/codegen')
| -rw-r--r-- | vm/compiler/codegen/arm/LocalOptimizations.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/vm/compiler/codegen/arm/LocalOptimizations.c b/vm/compiler/codegen/arm/LocalOptimizations.c index 9f616b836..fbeceef4d 100644 --- a/vm/compiler/codegen/arm/LocalOptimizations.c +++ b/vm/compiler/codegen/arm/LocalOptimizations.c @@ -105,11 +105,13 @@ static void applyLoadStoreElimination(CompilationUnit *cUnit, moveLIR = dvmCompilerRegCopyNoInsert( cUnit, checkLIR->operands[0], nativeRegId); /* - * Insertion is guaranteed to succeed since checkLIR - * is never the first LIR on the list + * Insert the converted checkLIR instruction after the + * the original checkLIR since the optimization is + * scannng in the top-down order and the new instruction + * will need to be checked. */ - dvmCompilerInsertLIRBefore((LIR *) checkLIR, - (LIR *) moveLIR); + dvmCompilerInsertLIRAfter((LIR *) checkLIR, + (LIR *) moveLIR); } checkLIR->isNop = true; continue; |
