[pypy-svn] r68176 - pypy/trunk/pypy/jit/backend/test

arigo at codespeak.net arigo at codespeak.net
Mon Oct 5 17:10:15 CEST 2009


Author: arigo
Date: Mon Oct  5 17:10:14 2009
New Revision: 68176

Modified:
   pypy/trunk/pypy/jit/backend/test/runner_test.py
Log:
Add a new test, which fails on the x86 backend.
Will be refactored, but I check it in anyway temporarily.


Modified: pypy/trunk/pypy/jit/backend/test/runner_test.py
==============================================================================
--- pypy/trunk/pypy/jit/backend/test/runner_test.py	(original)
+++ pypy/trunk/pypy/jit/backend/test/runner_test.py	Mon Oct  5 17:10:14 2009
@@ -256,6 +256,19 @@
             res = self.execute_operation(opnum, boxargs, rettype)
             assert res.value == retvalue
 
+        box = BoxFloat()
+        zbox = BoxFloat()
+        operations = [
+            ResOperation(rop.FLOAT_MUL, [box, box], zbox),
+            ResOperation(rop.FINISH, [zbox], None,
+                         descr=BasicFailDescr()),
+            ]
+        looptoken = LoopToken()
+        self.cpu.compile_loop([box], operations, looptoken)
+        self.cpu.set_future_value_float(0, 1.5)
+        res = self.cpu.execute_token(looptoken)
+        assert self.cpu.get_latest_value_float(0) == 2.25
+
     def test_ovf_operations(self, reversed=False):
         minint = -sys.maxint-1
         boom = 'boom'



More information about the Pypy-commit mailing list