Author: Richard Plangger <[email protected]>
Branch: vecopt
Changeset: r77960:5d3c3f5b1a5a
Date: 2015-06-08 15:56 +0200
http://bitbucket.org/pypy/pypy/changeset/5d3c3f5b1a5a/
Log: can_be_packed did not consider the case if origin pack is None, some
small other refactorings
diff --git a/rpython/jit/metainterp/optimizeopt/schedule.py
b/rpython/jit/metainterp/optimizeopt/schedule.py
--- a/rpython/jit/metainterp/optimizeopt/schedule.py
+++ b/rpython/jit/metainterp/optimizeopt/schedule.py
@@ -1,6 +1,6 @@
from rpython.jit.metainterp.history import (FLOAT,INT,ConstInt,BoxVector,
- BoxFloat,BoxInt)
+ BoxFloat,BoxInt,ConstFloat)
from rpython.jit.metainterp.resoperation import (rop, ResOperation, GuardResOp)
from rpython.jit.metainterp.optimizeopt.dependency import (DependencyGraph,
MemoryRef, Node, IndexVar)
@@ -525,8 +525,7 @@
LOAD_TRANS = LoadToVectorLoad()
STORE_TRANS = StoreToVectorStore()
-# note that the following definition is x86 machine
-# specific.
+# note that the following definition is x86 arch specific
ROP_ARG_RES_VECTOR = {
rop.VEC_INT_ADD: INT_OP_TO_VOP,
rop.VEC_INT_SUB: INT_OP_TO_VOP,
diff --git a/rpython/jit/metainterp/optimizeopt/test/test_schedule.py
b/rpython/jit/metainterp/optimizeopt/test/test_schedule.py
--- a/rpython/jit/metainterp/optimizeopt/test/test_schedule.py
+++ b/rpython/jit/metainterp/optimizeopt/test/test_schedule.py
@@ -23,7 +23,7 @@
'int': self.int32arraydescr,
}
loop = opparse("
[p0,p1,p2,p3,p4,p5,i0,i1,i2,i3,i4,i5,i6,i7,i8,i9,f0,f1,f2,f3,f4,f5,v103204[i32|4]]\n"
+ source + \
- "\n
jump(p0,p1,p2,p3,p4,p5,i0,i1,i2,i3,i4,i5,i6,i7,i8,i9,f0,f1,f2,f3,f4,f5)",
+ "\n
jump(p0,p1,p2,p3,p4,p5,i0,i1,i2,i3,i4,i5,i6,i7,i8,i9,f0,f1,f2,f3,f4,f5,v103204[i32|4])",
cpu=self.cpu,
namespace=ns)
if inc_label_jump:
diff --git a/rpython/jit/metainterp/optimizeopt/vectorize.py
b/rpython/jit/metainterp/optimizeopt/vectorize.py
--- a/rpython/jit/metainterp/optimizeopt/vectorize.py
+++ b/rpython/jit/metainterp/optimizeopt/vectorize.py
@@ -589,7 +589,8 @@
else:
if self.contains_pair(lnode, rnode):
return None
- return self.accumulates_pair(lnode, rnode, origin_pack)
+ if origin_pack is not None:
+ return self.accumulates_pair(lnode, rnode, origin_pack)
return None
def contains_pair(self, lnode, rnode):
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit