Commits

David Schneider committed 93c961f

add single precission VFP register locations

Comments (0)

Files changed (2)

rpython/jit/backend/arm/locations.py

     width = 2 * WORD
 
     def __repr__(self):
-        return 'vfp%d' % self.value
+        return 'vfp(d%d)' % self.value
 
     def is_core_reg(self):
         return False
     def is_float(self):
         return True
 
+class SVFPRegisterLocation(VFPRegisterLocation):
+    """Single Precission VFP Register"""
+    _immutable_ = True
+    width = WORD
+    type = 'S'
+
+    def __repr__(self):
+        return 'vfp(s%d)' % self.value
 
 class ImmLocation(AssemblerLocation):
     _immutable_ = True

rpython/jit/backend/arm/registers.py

 from rpython.jit.backend.arm.locations import VFPRegisterLocation
+from rpython.jit.backend.arm.locations import SVFPRegisterLocation
 from rpython.jit.backend.arm.locations import RegisterLocation
 
 registers = [RegisterLocation(i) for i in range(16)]
 vfpregisters = [VFPRegisterLocation(i) for i in range(16)]
+svfpregisters = [SVFPRegisterLocation(i) for i in range(32)]
 [r0, r1, r2, r3, r4, r5, r6, r7,
     r8, r9, r10, r11, r12, r13, r14, r15] = registers
 
 [d0, d1, d2, d3, d4, d5, d6, d7,
     d8, d9, d10, d11, d12, d13, d14, d15] = vfpregisters
 
+# single precission VFP registers, 32-bit
+for i in range(32):
+    globals()['s%d' % i] = svfpregisters[i]
+
 # aliases for registers
 fp = r11
 ip = r12
 callee_restored_registers = callee_resp + [pc]
 
 vfp_argument_regs = caller_vfp_resp = [d0, d1, d2, d3, d4, d5, d6, d7]
+svfp_argument_regs = [globals()['s%i' % i] for i in range(16)]
 callee_vfp_resp = [d8, d9, d10, d11, d12, d13, d14, d15]
 
 callee_saved_vfp_registers = callee_vfp_resp
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.