[pypy-svn] r65132 - in pypy/branch/pyjitpl5/pypy/jit/backend: test x86

arigo at codespeak.net arigo at codespeak.net
Thu May 7 13:13:48 CEST 2009


Author: arigo
Date: Thu May  7 13:13:47 2009
New Revision: 65132

Modified:
   pypy/branch/pyjitpl5/pypy/jit/backend/test/runner_test.py
   pypy/branch/pyjitpl5/pypy/jit/backend/x86/assembler.py
Log:
Fix, according to test_ovf_operations_reversed.


Modified: pypy/branch/pyjitpl5/pypy/jit/backend/test/runner_test.py
==============================================================================
--- pypy/branch/pyjitpl5/pypy/jit/backend/test/runner_test.py	(original)
+++ pypy/branch/pyjitpl5/pypy/jit/backend/test/runner_test.py	Thu May  7 13:13:47 2009
@@ -208,6 +208,7 @@
             loop.inputargs = [v1, v2]
             self.cpu.compile_operations(loop)
             for x, y, z in testcases:
+                assert not self.cpu.get_exception()
                 self.cpu.set_future_value_int(0, x)
                 self.cpu.set_future_value_int(1, y)
                 op = self.cpu.execute_operations(loop)

Modified: pypy/branch/pyjitpl5/pypy/jit/backend/x86/assembler.py
==============================================================================
--- pypy/branch/pyjitpl5/pypy/jit/backend/x86/assembler.py	(original)
+++ pypy/branch/pyjitpl5/pypy/jit/backend/x86/assembler.py	Thu May  7 13:13:47 2009
@@ -803,7 +803,8 @@
         exc = False
         if ovf:
             regalloc.position = -1
-            self.generate_ovf_set()
+            if guard_op.opnum == rop.GUARD_NO_EXCEPTION:
+                self.generate_ovf_set()
             exc = True
         if (guard_op.opnum == rop.GUARD_EXCEPTION or
             guard_op.opnum == rop.GUARD_NO_EXCEPTION):



More information about the Pypy-commit mailing list