[pypy-svn] r47817 - in pypy/dist/pypy/rpython/memory/gctransform: . test
cfbolz at codespeak.net
cfbolz at codespeak.net
Wed Oct 24 13:43:49 CEST 2007
Author: cfbolz
Date: Wed Oct 24 13:43:48 2007
New Revision: 47817
Modified:
pypy/dist/pypy/rpython/memory/gctransform/framework.py
pypy/dist/pypy/rpython/memory/gctransform/test/test_framework.py
Log:
humpf, fix bugs so that integer stores work again
Modified: pypy/dist/pypy/rpython/memory/gctransform/framework.py
==============================================================================
--- pypy/dist/pypy/rpython/memory/gctransform/framework.py (original)
+++ pypy/dist/pypy/rpython/memory/gctransform/framework.py Wed Oct 24 13:43:48 2007
@@ -41,8 +41,10 @@
if op.args[0] in mallocvars:
mallocvars[op.result] = True
elif op.opname in ("setfield", "setarrayitem", "setinteriorfield"):
+ TYPE = op.args[-1].concretetype
if (op.args[0] in mallocvars and
- op.args[-1].concretetype.TO._gckind == "gc"):
+ isinstance(TYPE, lltype.Ptr) and
+ TYPE.TO._gckind == "gc"):
result[op] = True
else:
if collect_analyzer.analyze(op):
Modified: pypy/dist/pypy/rpython/memory/gctransform/test/test_framework.py
==============================================================================
--- pypy/dist/pypy/rpython/memory/gctransform/test/test_framework.py (original)
+++ pypy/dist/pypy/rpython/memory/gctransform/test/test_framework.py Wed Oct 24 13:43:48 2007
@@ -65,6 +65,7 @@
class WriteBarrierTransformer(FrameworkGCTransformer):
+ initializing_stores = {}
GC_PARAMS = {}
class GCClass(MarkSweepGC):
needs_write_barrier = True
@@ -133,6 +134,7 @@
a = A()
b = B()
b.a = a
+ b.b = 1
t = rtype(f, [])
etrafo = ExceptionTransformer(t)
graphs = etrafo.transform_completely()
More information about the Pypy-commit
mailing list