[pypy-svn] pypy jit-shadowstack: Reorder the locations, for no real good reason.

arigo commits-noreply at bitbucket.org
Thu Mar 31 16:56:03 CEST 2011


Author: Armin Rigo <arigo at tunes.org>
Branch: jit-shadowstack
Changeset: r43055:1400f4d7ecb2
Date: 2011-03-31 16:55 +0200
http://bitbucket.org/pypy/pypy/changeset/1400f4d7ecb2/

Log:	Reorder the locations, for no real good reason.

diff --git a/pypy/jit/backend/x86/arch.py b/pypy/jit/backend/x86/arch.py
--- a/pypy/jit/backend/x86/arch.py
+++ b/pypy/jit/backend/x86/arch.py
@@ -8,20 +8,21 @@
 import sys
 if sys.maxint == (2**31 - 1):
     WORD = 4
-    # ebp + ebx + esi + edi + force_index + 4 extra words = 9 words
+    # ebp + ebx + esi + edi + 4 extra words + force_index = 9 words
     FRAME_FIXED_SIZE = 9
-    FORCE_INDEX_OFS = -4*WORD
+    FORCE_INDEX_OFS = -8*WORD
+    MY_COPY_OF_REGS = -7*WORD
     IS_X86_32 = True
     IS_X86_64 = False
 else:
     WORD = 8
-    # rbp + rbx + r12 + r13 + r14 + r15 + force_index + 11 extra words = 18
+    # rbp + rbx + r12 + r13 + r14 + r15 + 11 extra words + force_index = 18
     FRAME_FIXED_SIZE = 18
-    FORCE_INDEX_OFS = -6*WORD
+    FORCE_INDEX_OFS = -17*WORD
+    MY_COPY_OF_REGS = -16*WORD
     IS_X86_32 = False
     IS_X86_64 = True
 
-MY_COPY_OF_REGS = -(FRAME_FIXED_SIZE-1)*WORD
 # The extra space has room for almost all registers, apart from eax and edx
 # which are used in the malloc itself.  They are:
 #   ecx, ebx, esi, edi               [32 and 64 bits]


More information about the Pypy-commit mailing list