Closed GoogleCodeExporter closed 8 years ago
Original comment by collinw
on 6 Jan 2010 at 11:40
I think happens like this:
First y() becomes hot and is compiled. The LOAD_GLOBAL_fast optimization is
used for
the lookup of "Exception". The next iteration of the loop modifies the global
"i"
and invalidates the compiled code by setting co_assumed_globals to NULL. It
leaves
the CO_FDO_GLOBALS flag set so that no attempt will be made to execute the
code. All
the remaining calls go through the interpreter which is unfortunate but not
this bug.
When the IR has to be regenerated it tries to use the LOAD_GLOBAL_fast path
again but
now we don't have a co_assumed_globals anymore so trying to do a lookup crashes
inside PyDict_GetItem().
Original comment by abbeyj
on 12 Jan 2010 at 1:37
Original comment by collinw
on 10 Mar 2010 at 2:38
This was fixed as part of the watcher redesign in r1120. I added a regression
test for
this segfault in r1130.
Original comment by collinw
on 10 Mar 2010 at 7:27
Original issue reported on code.google.com by
joerg...@gmail.com
on 6 Jan 2010 at 11:39