[pypy-commit] pypy continulet-jit-2: Fixes.

arigo noreply at buildbot.pypy.org
Thu Mar 1 17:11:54 CET 2012


Author: Armin Rigo <arigo at tunes.org>
Branch: continulet-jit-2
Changeset: r53062:61962326e5b4
Date: 2012-03-01 17:11 +0100
http://bitbucket.org/pypy/pypy/changeset/61962326e5b4/

Log:	Fixes.

diff --git a/pypy/jit/backend/x86/assembler.py b/pypy/jit/backend/x86/assembler.py
--- a/pypy/jit/backend/x86/assembler.py
+++ b/pypy/jit/backend/x86/assembler.py
@@ -885,8 +885,8 @@
             self.mc.MOVSD_sx(0, loc.value)
         elif WORD == 4 and isinstance(loc, StackLoc) and loc.get_width() == 8:
             # XXX evil trick
-            self.mc.PUSH_b(get_ebp_ofs(loc.position))
-            self.mc.PUSH_b(get_ebp_ofs(loc.position + 1))
+            self.mc.PUSH_b(loc.value + 4)
+            self.mc.PUSH_b(loc.value)
         else:
             self.mc.PUSH(loc)
 
@@ -896,8 +896,8 @@
             self.mc.ADD_ri(esp.value, 8)   # = size of doubles
         elif WORD == 4 and isinstance(loc, StackLoc) and loc.get_width() == 8:
             # XXX evil trick
-            self.mc.POP_b(get_ebp_ofs(loc.position + 1))
-            self.mc.POP_b(get_ebp_ofs(loc.position))
+            self.mc.POP_b(loc.value)
+            self.mc.POP_b(loc.value + 4)
         else:
             self.mc.POP(loc)
 
@@ -1919,8 +1919,9 @@
                 stackloc = frame_addr + get_ebp_ofs(code)
                 value = rffi.cast(rffi.LONGP, stackloc)[0]
                 if kind == self.DESCR_FLOAT and WORD == 4:
-                    value_hi = value
-                    value = rffi.cast(rffi.LONGP, stackloc - 4)[0]
+                    #value_hi = value
+                    #value = rffi.cast(rffi.LONGP, stackloc - 4)[0]
+                    value_hi = rffi.cast(rffi.LONGP, stackloc + 4)[0]
             else:
                 # 'code' identifies a register: load its value
                 kind = code & 3
@@ -2218,6 +2219,7 @@
                                      asmgcroot.FRAME_PTR) + 1)
                 pos = self._regalloc.fm.reserve_location_in_frame(use_words)
                 css = get_ebp_ofs(pos + use_words - 1)
+                xxxxxxxx # ^^^^
                 self._regalloc.close_stack_struct = css
             # The location where the future CALL will put its return address
             # will be [ESP-WORD].  But we can't use that as the next frame's


More information about the pypy-commit mailing list