Author: Armin Rigo <[email protected]>
Branch: stmgc-c7
Changeset: r70104:c0537b11889f
Date: 2014-03-20 10:30 +0100
http://bitbucket.org/pypy/pypy/changeset/c0537b11889f/
Log: Don't produce stm_write() for writes of a Void value.
diff --git a/rpython/memory/gctransform/stmframework.py
b/rpython/memory/gctransform/stmframework.py
--- a/rpython/memory/gctransform/stmframework.py
+++ b/rpython/memory/gctransform/stmframework.py
@@ -71,7 +71,9 @@
v_struct = hop.spaceop.args[0]
assert opname in ('setfield', 'setarrayitem', 'setinteriorfield',
'raw_store')
- if not var_needsgc(v_struct):
+ if hop.spaceop.args[-1].concretetype == lltype.Void:
+ pass # ignore setfields of a Void type
+ elif not var_needsgc(v_struct):
if (var_needsgc(hop.spaceop.args[-1]) and
'is_excdata' not in
hop.spaceop.args[0].concretetype.TO._hints):
raise Exception("%s: GC pointer written into a non-GC location"
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit