2009-11-05 Ivan Maidanski <ivmai@mail.ru>
authorivmai <ivmai>
Thu, 5 Nov 2009 08:12:27 +0000 (08:12 +0000)
committerIvan Maidanski <ivmai@mail.ru>
Tue, 26 Jul 2011 17:06:51 +0000 (21:06 +0400)
* tests/test.c (check_heap_stats): Take into account the unmapped
memory size when checking for "Unexpected heap growth"; remove
FIXME.

ChangeLog
tests/test.c

index f03c613..72bde0d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-11-05  Ivan Maidanski <ivmai@mail.ru>
+
+       * tests/test.c (check_heap_stats): Take into account the unmapped
+       memory size when checking for "Unexpected heap growth"; remove
+       FIXME.
+
 2009-11-03  Hans Boehm <Hans.Boehm@hp.com>
 
        * alloc.c: Revert last change.
index 346436a..783d82f 100644 (file)
@@ -1323,8 +1323,7 @@ void check_heap_stats(void)
         (void)GC_printf("Incorrect execution - missed some allocations\n");
         FAIL;
     }
-    if (GC_get_heap_size() > max_heap_sz*n_tests) {
-        /* FIXME: is the condition correct?     */
+    if (GC_get_heap_size() + GC_get_unmapped_bytes() > max_heap_sz*n_tests) {
         (void)GC_printf("Unexpected heap growth - collector may be broken\n");
         FAIL;
     }