[pypy-commit] pypy default: don't use specialize.ll for these calls, but call_location instead. otherwise

cfbolz noreply at buildbot.pypy.org
Wed Nov 30 15:19:07 CET 2011


Author: Carl Friedrich Bolz <cfbolz at gmx.de>
Branch: 
Changeset: r50012:5a5d0bfd04c9
Date: 2011-11-30 15:18 +0100
http://bitbucket.org/pypy/pypy/changeset/5a5d0bfd04c9/

Log:	don't use specialize.ll for these calls, but call_location instead.
	otherwise you cannot use is_constant on high-level objects.

diff --git a/pypy/rlib/jit.py b/pypy/rlib/jit.py
--- a/pypy/rlib/jit.py
+++ b/pypy/rlib/jit.py
@@ -176,7 +176,6 @@
     return decorator
 
 @oopspec("jit.isconstant(value)")
- at specialize.ll()
 def isconstant(value):
     """
     While tracing, returns whether or not the value is currently known to be
@@ -186,9 +185,9 @@
     This is for advanced usage only.
     """
     return NonConstant(False)
+isconstant._annspecialcase_ = "specialize:call_location"
 
 @oopspec("jit.isvirtual(value)")
- at specialize.ll()
 def isvirtual(value):
     """
     Returns if this value is virtual, while tracing, it's relatively
@@ -197,6 +196,7 @@
     This is for advanced usage only.
     """
     return NonConstant(False)
+isvirtual._annspecialcase_ = "specialize:call_location"
 
 class Entry(ExtRegistryEntry):
     _about_ = hint


More information about the pypy-commit mailing list