OSDN Git Service

Fix for Issue 3161543 - Remove stray line of code in JIT
authorbuzbee <buzbee@google.com>
Wed, 3 Nov 2010 17:44:15 +0000 (10:44 -0700)
committerbuzbee <buzbee@google.com>
Tue, 30 Nov 2010 19:21:56 +0000 (11:21 -0800)
During Change 22370 "Thumb/Thumb2 instruction selection rework"
line 1689 of Codegen.c was inadvertently duplicated and deposited
in the unrelated function genPuntToInterp() at line 1732.

genPuntToInterp() is rarely used and half of the time (if the
roll-back Dalvik PC was word-aligned) the error would have been
benign.  However, if the Dalvik PC is not word-aligned, the result
would be a seg fault.

The fix is to remove the line of code.

Change-Id: Ib2ffb80059a639923c342a36797eb6c4995c5218

vm/compiler/codegen/arm/CodegenDriver.c

index 657533b..011679b 100644 (file)
@@ -1219,7 +1219,6 @@ static void genPuntToInterp(CompilationUnit *cUnit, unsigned int offset)
     /* r0 = dalvik pc */
     dvmCompilerFlushAllRegs(cUnit);
     loadConstant(cUnit, r0, (int) (cUnit->method->insns + offset));
-    loadWordDisp(cUnit, r0, offsetof(Object, clazz), r3);
     loadWordDisp(cUnit, rGLUE, offsetof(InterpState,
                  jitToInterpEntries.dvmJitToInterpPunt), r1);
     opReg(cUnit, kOpBlx, r1);