This commit is contained in:
Justin Ethier 2015-11-24 23:29:44 -05:00
parent b6dc8c8285
commit 46dff7fc38

View file

@ -67,12 +67,18 @@ typedef struct gc_free_list_t gc_free_list;
struct gc_free_list_t { struct gc_free_list_t {
// somehow this size param is being overwritten by a "mark() =". // somehow this size param is being overwritten by a "mark() =".
// how could that happen? // how could that happen?
somehow it appears free list pointers are being used where heap objects are //somehow it appears free list pointers are being used where heap objects are
expected. could this be as simple as objects being sweeped that should not //expected. could this be as simple as objects being sweeped that should not
have been? unfortunately it is harder to figure how why the objects were //have been? unfortunately it is harder to figure how why the objects were
sweeped. were they not marked properly? is there a race condition? maybe //sweeped. were they not marked properly? is there a race condition? maybe
more than one issue? what is going on? //more than one issue? what is going on?
unsigned int dummy; // just for testing/evaluation, this line is NOT a fix!! //
// the following line does not solve the problem. in fact, with this in
// place there are still cases where the tag is a multiple of 32, implying
// again that a free list node is being used as a heap object. IE, the
// size value is being read into the tag field by code expecting a heap obj.
//
//unsigned int dummy; // just for testing/evaluation, this line is NOT a fix!!
unsigned int size; unsigned int size;
gc_free_list *next; gc_free_list *next;
}; };