1. Pypy
  2. Untitled project
  3. pypy


Armin Rigo  committed 35fdf44

Issue #1817: missing support for virtual_refs pointing to several different types in the same RPython program

  • Participants
  • Parent commits dbdcc05
  • Branches default

Comments (0)

Files changed (2)

File rpython/jit/metainterp/test/test_virtualref.py

View file
  • Ignore whitespace
         def check_call(op, fname):
             assert op.opname == 'direct_call'
-            assert op.args[0].value._obj._name == fname
+            assert op.args[0].value._obj._name.startswith(fname)
         ops = [op for block, op in graph.iterblockops()]
         check_call(ops[-3], 'virtual_ref')

File rpython/rlib/jit.py

View file
  • Ignore whitespace
 # ____________________________________________________________
 # VRefs
 def virtual_ref(x):
     """Creates a 'vref' object that contains a reference to 'x'.  Calls
     to virtual_ref/virtual_ref_finish must be properly nested.  The idea
     return DirectJitVRef(x)
 virtual_ref.oopspec = 'virtual_ref(x)'
 def virtual_ref_finish(vref, x):
     """See docstring in virtual_ref(x)"""
     keepalive_until_here(x)   # otherwise the whole function call is removed