Commit 65d1551e authored by Niels Möller's avatar Niels Möller
Browse files

* src/gc.c (gc): Display number of strings.

Rev: src/gc.c:1.19
parent bd145097
......@@ -203,13 +203,15 @@ void gc_kill(struct lsh_object *o)
void gc(struct lsh_object *root)
{
unsigned before = number_of_objects;
unsigned objects_before = number_of_objects;
unsigned strings_before = number_of_strings;
gc_mark(root);
gc_sweep();
verbose("Objects alive: %i, garbage collected: %i\n", live_objects,
before - live_objects);
verbose("Objects alive: %i, garbage collected: %i\n",
live_objects, objects_before - live_objects);
verbose("Used strings: %i, garbage collected: %i\n",
number_of_strings, strings_before - number_of_strings);
}
void gc_maybe(struct lsh_object *root, int busy)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment