From 6da59c10cb9cd59bdc04432f3f2a25df0991fac3 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Wed, 19 Jun 2019 06:48:19 -0700 Subject: internal debug support: reduce noise from sweep_one. * gc.c (sweep_one): If the swept object matches the break_obj, only log it if the object isn't free. Otherwise if break_obj is sitting on the free list, we will uselessly report on it on every sweep operation, which is very often under --gc-debug torture operation. --- gc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gc.c') diff --git a/gc.c b/gc.c index 19032cbe..178e1cc6 100644 --- a/gc.c +++ b/gc.c @@ -521,7 +521,7 @@ static int sweep_one(obj_t *block) #endif #if CONFIG_EXTRA_DEBUGGING - if (block == break_obj) { + if (block == break_obj && (block->t.type & FREE) == 0) { #if HAVE_VALGRIND VALGRIND_PRINTF_BACKTRACE("object %p swept (type = %x)\n", convert(void *, block), -- cgit v1.2.3