1. Dario Bertini
  2. another-pypy

Commits

David Schneider  committed bccfb0d

add type based indirection to convert_to_imm

  • Participants
  • Parent commits 7c83ac5
  • Branches arm-backed-float

Comments (0)

Files changed (1)

File pypy/jit/backend/arm/regalloc.py

View file
             return self.rm.make_sure_var_in_reg(var, forbidden_vars,
                                         selected_reg, need_lower_byte)
 
+    def convert_to_imm(self, value):
+        if isinstance(value, ConstInt):
+            return self.rm.convert_to_imm(value)
+        else:
+            assert isinstance(value, ConstFloat)
+            return self.vfprm.convert_to_imm(value)
 
     def update_bindings(self, locs, frame_depth, inputargs):
         used = {}