[pypy-commit] pypy ppc-vsx-support: removed comments, fixed problem with rewrite (was changed slightly for vectorization)
plan_rich
pypy.commits at gmail.com
Tue Jul 19 10:46:09 EDT 2016
Author: Richard Plangger <planrichi at gmail.com>
Branch: ppc-vsx-support
Changeset: r85772:1932988064a3
Date: 2016-07-19 16:45 +0200
http://bitbucket.org/pypy/pypy/changeset/1932988064a3/
Log: removed comments, fixed problem with rewrite (was changed slightly
for vectorization)
diff --git a/rpython/jit/backend/llsupport/rewrite.py b/rpython/jit/backend/llsupport/rewrite.py
--- a/rpython/jit/backend/llsupport/rewrite.py
+++ b/rpython/jit/backend/llsupport/rewrite.py
@@ -160,10 +160,9 @@
def _emit_mul_if_factor_offset_not_supported(self, index_box,
factor, offset):
factor, offset, new_index_box = cpu_simplify_scale(self.cpu, index_box, factor, offset)
- if new_index_box is not None:
+ if new_index_box is not None and index_box is not new_index_box:
self.emit_op(new_index_box)
- return factor, offset, new_index_box
- return factor, offset, index_box
+ return factor, offset, new_index_box
def emit_gc_load_or_indexed(self, op, ptr_box, index_box, itemsize,
factor, offset, sign, type='i'):
@@ -195,14 +194,6 @@
NOT_SIGNED = 0
CINT_ZERO = ConstInt(0)
opnum = op.getopnum()
- #if opnum == rop.CALL_MALLOC_NURSERY_VARSIZE:
- # v_length = op.getarg(2)
- # scale = op.getarg(1).getint()
- # if scale not in self.cpu.load_supported_factors:
- # scale, offset, v_length = \
- # self._emit_mul_if_factor_offset_not_supported(v_length, scale, 0)
- # op.setarg(1, ConstInt(scale))
- # op.setarg(2, v_length)
if rop.is_getarrayitem(opnum) or \
opnum in (rop.GETARRAYITEM_RAW_I,
rop.GETARRAYITEM_RAW_F):
@@ -786,10 +777,6 @@
arraydescr.lendescr.offset != gc_descr.standard_array_length_ofs)):
return False
self.emitting_an_operation_that_can_collect()
- #scale = itemsize
- #if scale not in self.cpu.load_supported_factors:
- # scale, offset, v_length = \
- # self._emit_mul_if_factor_offset_not_supported(v_length, scale, 0)
op = ResOperation(rop.CALL_MALLOC_NURSERY_VARSIZE,
[ConstInt(kind), ConstInt(itemsize), v_length],
descr=arraydescr)
@@ -986,6 +973,5 @@
index_box = ResOperation(rop.INT_MUL,
[index_box, ConstInt(factor)])
factor = 1
- return factor, offset, index_box
- return factor, offset, None
+ return factor, offset, index_box
diff --git a/rpython/jit/backend/ppc/regalloc.py b/rpython/jit/backend/ppc/regalloc.py
--- a/rpython/jit/backend/ppc/regalloc.py
+++ b/rpython/jit/backend/ppc/regalloc.py
@@ -603,8 +603,6 @@
loc = self.loc(accuminfo.getoriginal())
args[i] = loc
accuminfo = accuminfo.next()
-
- self.possibly_free_vars(op.getfailargs())
return args
def load_condition_into_cc(self, box):
More information about the pypy-commit
mailing list