core: gc: Enable memory dump debugging.
* src/gc.c (gc): If MES_DUMP is set, dump arena. [POINTER_CELLS && !GC_NOFLIP]: Run gc_ twice to enable comparing memory dumps.
This commit is contained in:
parent
b05558ec00
commit
20595cd044
7
src/gc.c
7
src/gc.c
|
@ -742,6 +742,8 @@ gc_ ()
|
|||
SCM
|
||||
gc ()
|
||||
{
|
||||
if (getenv ("MES_DUMP") != 0)
|
||||
gc_dump_arena (g_cells, gc_free ());
|
||||
if (g_debug > 5)
|
||||
{
|
||||
eputs ("symbols: ");
|
||||
|
@ -753,6 +755,9 @@ gc ()
|
|||
}
|
||||
gc_push_frame ();
|
||||
gc_ ();
|
||||
#if POINTER_CELLS && !GC_NOFLIP
|
||||
gc_ ();
|
||||
#endif
|
||||
gc_pop_frame ();
|
||||
if (g_debug > 5)
|
||||
{
|
||||
|
@ -763,6 +768,8 @@ gc ()
|
|||
write_error_ (R0);
|
||||
eputs ("\n");
|
||||
}
|
||||
if (getenv ("MES_DUMP") != 0)
|
||||
gc_dump_arena (g_cells, gc_free ());
|
||||
return cell_unspecified;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue