summaryrefslogtreecommitdiffstats
path: root/parser.y
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2014-10-18 20:12:23 -0700
committerKaz Kylheku <kaz@kylheku.com>2014-10-18 20:12:23 -0700
commit88e7e54b5b415c7ab4e6fedd3e3e519d8bf3a68b (patch)
tree4ebcdb7b7981ec6f47caedb36881323ba4de210f /parser.y
parent415f36f296efa0b286e6f55013e7ca554232a0c9 (diff)
downloadtxr-88e7e54b5b415c7ab4e6fedd3e3e519d8bf3a68b.tar.gz
txr-88e7e54b5b415c7ab4e6fedd3e3e519d8bf3a68b.tar.bz2
txr-88e7e54b5b415c7ab4e6fedd3e3e519d8bf3a68b.zip
Deal with situation when GC is disabled and the freshobj array runs out
of room. This could happen when parsing a really large TXR program, since gc is disabled during parsing. Currently it asserts, which is not acceptable. * gc.c (make_obj): If after gc, the freshobj array has not been emptied (obviously because gc is disabled), do not assert. Rather, set the full_gc flag to request a full garbage collection when gc is re-enabled. Furthermore, only place newly allocated objects into freshobj if full_gc has not been set. Thus, if we exhaust the freshobj array while gc is off, the full_gc flag is set, and we discontinue use of that array. When gc is re-enabled, we will do a full gc pass. A full gc pass ignores freshobj array, so it doesn't matter that its use was discontinued.
Diffstat (limited to 'parser.y')
0 files changed, 0 insertions, 0 deletions