[pypy-commit] pypy arm-backend-2: replace a conditional jump with conditional execution

bivab noreply at buildbot.pypy.org
Thu Jan 26 10:45:29 CET 2012


Author: David Schneider <david.schneider at picle.org>
Branch: arm-backend-2
Changeset: r51783:5e16783d7519
Date: 2012-01-26 09:17 +0100
http://bitbucket.org/pypy/pypy/changeset/5e16783d7519/

Log:	replace a conditional jump with conditional execution

diff --git a/pypy/jit/backend/arm/opassembler.py b/pypy/jit/backend/arm/opassembler.py
--- a/pypy/jit/backend/arm/opassembler.py
+++ b/pypy/jit/backend/arm/opassembler.py
@@ -559,9 +559,9 @@
             self.mc.BL(func)
 
         # patch the JZ above
-        offset = self.mc.currpos() - jz_location
+        offset = self.mc.currpos()
         pmc = OverwritingBuilder(self.mc, jz_location, WORD)
-        pmc.ADD_ri(r.pc.value, r.pc.value, offset - PC_OFFSET, cond=c.EQ)
+        pmc.B_offs(offset, c.EQ)
         return fcond
 
     emit_op_cond_call_gc_wb_array = emit_op_cond_call_gc_wb


More information about the pypy-commit mailing list