[pypy-svn] r77535 - pypy/branch/larger-writebarrier/pypy/rpython/memory/gctransform
arigo at codespeak.net
arigo at codespeak.net
Fri Oct 1 17:23:52 CEST 2010
Author: arigo
Date: Fri Oct 1 17:23:50 2010
New Revision: 77535
Modified:
pypy/branch/larger-writebarrier/pypy/rpython/memory/gctransform/framework.py
Log:
Fix: write_barrier_from_array() always takes 4 arguments now
(but is inlined and may call remember_young_pointer_from_array()
with less arguments).
Modified: pypy/branch/larger-writebarrier/pypy/rpython/memory/gctransform/framework.py
==============================================================================
--- pypy/branch/larger-writebarrier/pypy/rpython/memory/gctransform/framework.py (original)
+++ pypy/branch/larger-writebarrier/pypy/rpython/memory/gctransform/framework.py Fri Oct 1 17:23:50 2010
@@ -443,6 +443,7 @@
self.write_barrier_from_array_ptr = getfn(func.im_func,
[s_gc,
annmodel.SomeAddress(),
+ annmodel.SomeAddress(),
annmodel.SomeInteger()],
annmodel.s_None,
inline=True)
@@ -1023,6 +1024,8 @@
and not isinstance(v_newvalue, Constant)
and v_struct.concretetype.TO._gckind == "gc"
and hop.spaceop not in self.clean_sets):
+ v_newvalue = hop.genop("cast_ptr_to_adr", [v_newvalue],
+ resulttype = llmemory.Address)
v_structaddr = hop.genop("cast_ptr_to_adr", [v_struct],
resulttype = llmemory.Address)
if (self.write_barrier_from_array_ptr is not None and
@@ -1032,12 +1035,11 @@
assert v_index.concretetype == lltype.Signed
hop.genop("direct_call", [self.write_barrier_from_array_ptr,
self.c_const_gc,
+ v_newvalue,
v_structaddr,
v_index])
else:
self.write_barrier_calls += 1
- v_newvalue = hop.genop("cast_ptr_to_adr", [v_newvalue],
- resulttype = llmemory.Address)
hop.genop("direct_call", [self.write_barrier_ptr,
self.c_const_gc,
v_newvalue,
More information about the Pypy-commit
mailing list