[pypy-commit] pypy unsigned-dtypes: add a ulonglong test and fix code so that it works with the new oopcode

justinpeel noreply at buildbot.pypy.org
Sun Sep 18 08:31:57 CEST 2011


Author: Justin Peel <notmuchtotell at gmail.com>
Branch: unsigned-dtypes
Changeset: r47321:60ff3c16b9da
Date: 2011-09-18 06:30 +0000
http://bitbucket.org/pypy/pypy/changeset/60ff3c16b9da/

Log:	add a ulonglong test and fix code so that it works with the new
	oopcode

diff --git a/pypy/jit/codewriter/support.py b/pypy/jit/codewriter/support.py
--- a/pypy/jit/codewriter/support.py
+++ b/pypy/jit/codewriter/support.py
@@ -333,7 +333,7 @@
 def _ll_1_llong_to_float(xll):
     return float(rffi.cast(lltype.SignedLongLong, xll))
 
-def _ll_1_ullong_to_float(xull):
+def _ll_1_ullong_u_to_float(xull):
     return float(rffi.cast(lltype.UnsignedLongLong, xull))
 
 
diff --git a/pypy/jit/codewriter/test/test_longlong.py b/pypy/jit/codewriter/test/test_longlong.py
--- a/pypy/jit/codewriter/test/test_longlong.py
+++ b/pypy/jit/codewriter/test/test_longlong.py
@@ -195,6 +195,8 @@
                       [lltype.Float], lltype.SignedLongLong)
         self.do_check('cast_longlong_to_float', EffectInfo.OS_LLONG_TO_FLOAT,
                       [lltype.SignedLongLong], lltype.Float)
+        self.do_check('cast_ulonglong_to_float', EffectInfo.OS_LLONG_U_TO_FLOAT,
+                      [lltype.UnsignedLongLong], lltype.Float)
         for T1 in [lltype.SignedLongLong, lltype.UnsignedLongLong]:
             for T2 in [lltype.Signed, lltype.Unsigned]:
                 self.do_check('cast_primitive', EffectInfo.OS_LLONG_TO_INT,


More information about the pypy-commit mailing list