[pypy-commit] pypy ppc-jit-backend: don't use make_sure_var_in_reg in prepare_same_as

hager noreply at buildbot.pypy.org
Tue Jan 31 17:17:23 CET 2012


Author: hager <sven.hager at uni-duesseldorf.de>
Branch: ppc-jit-backend
Changeset: r51994:4e9490069131
Date: 2012-01-31 08:01 -0800
http://bitbucket.org/pypy/pypy/changeset/4e9490069131/

Log:	don't use make_sure_var_in_reg in prepare_same_as

diff --git a/pypy/jit/backend/ppc/ppcgen/regalloc.py b/pypy/jit/backend/ppc/ppcgen/regalloc.py
--- a/pypy/jit/backend/ppc/ppcgen/regalloc.py
+++ b/pypy/jit/backend/ppc/ppcgen/regalloc.py
@@ -109,7 +109,7 @@
             self.assembler.load(loc, immvalue)
         else:
             loc = self.make_sure_var_in_reg(thing,
-                            forbidden_vars=forbidden_vars)
+                            forbidden_vars=self.temp_boxes + forbidden_vars)
         return loc
 
     def allocate_scratch_reg(self, type=INT, selected_reg=None, forbidden_vars=None):
@@ -765,11 +765,7 @@
 
     def prepare_same_as(self, op):
         arg = op.getarg(0)
-        imm_arg = _check_imm_arg(arg)
-        if imm_arg:
-            argloc = self.make_sure_var_in_reg(arg)
-        else:
-            argloc = self._ensure_value_is_boxed(arg)
+        argloc = self._ensure_value_is_boxed(arg)
         self.possibly_free_vars_for_op(op)
         self.free_temp_vars()
         resloc = self.force_allocate_reg(op.result)


More information about the pypy-commit mailing list