[pypy-svn] r62909 - pypy/branch/pyjitpl5/pypy/jit/backend/x86/test
fijal at codespeak.net
fijal at codespeak.net
Thu Mar 12 21:54:19 CET 2009
Author: fijal
Date: Thu Mar 12 21:54:16 2009
New Revision: 62909
Modified:
pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_regalloc.py
pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_runner.py
Log:
fix tests. now it passes
Modified: pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_regalloc.py
==============================================================================
--- pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_regalloc.py (original)
+++ pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_regalloc.py Thu Mar 12 21:54:16 2009
@@ -213,10 +213,11 @@
none_ptr = ConstPtr(lltype.cast_opaque_ptr(llmemory.GCREF,
lltype.nullptr(TP)))
const_code = none_ptr
- const_ptr = none_ptr
stuff = lltype.malloc(TP)
stuff_2 = lltype.malloc(TP.y.TO)
stuff.y = stuff_2
+ const_ptr = ConstPtr(lltype.cast_opaque_ptr(llmemory.GCREF,
+ stuff))
p12 = const_code.clonebox()
const_name = none_ptr
ops = [
Modified: pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_runner.py
==============================================================================
--- pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_runner.py (original)
+++ pypy/branch/pyjitpl5/pypy/jit/backend/x86/test/test_runner.py Thu Mar 12 21:54:16 2009
@@ -18,9 +18,13 @@
def handle_guard_failure(self, gf):
assert isinstance(gf, GuardFailed)
self.gf = gf
- self.recordedvalues = [
- gf.cpu.getvaluebox(gf.frame, gf.guard_op, i).value
- for i in range(len(gf.guard_op.liveboxes))]
+ j = 0
+ self.recordedvalues = []
+ for box in guard_op.liveboxes:
+ if isinstance(box, Box):
+ value = gf.cpu.getvaluebox(gf.frame, gf.guard_op, j).value
+ self.recordedvalues.append(value)
+ j += 1
if len(gf.guard_op.liveboxes) > 0:
gf.make_ready_for_return(gf.cpu.getvaluebox(gf.frame, gf.guard_op, 0))
else:
More information about the Pypy-commit
mailing list