+2011-04-02 Ivan Maidanski <ivmai@mail.ru>
+
+ * tests/test.c (reverse_test_inner): Test interior pointer
+ recognition only if ALL_INTERIOR_POINTERS.
+ * tests/test.c (run_one_test): Replace GC_all_interior_pointers
+ with GC_get_all_interior_pointers(); simplify the expression.
+ * tests/test.c (check_heap_stats): Replace GC_bytes_allocd and
+ GC_bytes_allocd_before_gc with GC_get_total_bytes().
+ * tests/test.c (main): Replace GC_gc_no with GC_get_gc_no().
+
2011-03-27 Ivan Maidanski <ivmai@mail.ru>
* dbg_mlc.c (GC_debug_strdup, GC_debug_free): Output a portability
2011-03-22 Ivan Maidanski <ivmai@mail.ru>
- * misc.c (GC_abort): Use _exit() (instead of DebugBreak) on Win32 when
- doing code static analysis (to inform the tool that the function is
- a no-return one).
- * os_dep.c (GC_linux_stack_base): Remove a duplicate validation of the
- length of "stat" file; use signed int type for "i", "buf_offset" and
- "len" local variables (since read() may return -1).
+ * misc.c (GC_abort): Use _exit() (instead of DebugBreak) on Win32
+ when doing code static analysis (to inform the tool that the
+ function is a no-return one).
+ * os_dep.c (GC_linux_stack_base): Remove a duplicate validation
+ of the length of "stat" file; use signed int type for "i",
+ "buf_offset" and "len" local variables (since read() may
+ return -1).
2011-03-20 Ivan Maidanski <ivmai@mail.ru>
for (i = 0; i < 10; i++) {
(void)ints(1, BIG);
}
- /* Superficially test interior pointer recognition on stack */
+# ifdef ALL_INTERIOR_POINTERS
+ /* Superficially test interior pointer recognition on stack */
c = (sexpr)((char *)c + sizeof(char *));
d = (sexpr)((char *)d + sizeof(char *));
+# endif
GC_FREE((void *)e);
# if defined(RS6000) || defined(POWERPC)
if (!TEST_FAIL_COUNT(1))
# else
- if ((GC_all_interior_pointers && !TEST_FAIL_COUNT(1))
- || (!GC_all_interior_pointers && !TEST_FAIL_COUNT(2)))
+ if (!TEST_FAIL_COUNT(GC_get_all_interior_pointers() ? 1 : 2))
# endif
{
GC_printf("GC_is_valid_displacement produced wrong failure indication\n");
}
}
(void)GC_printf("Total number of bytes allocated is %lu\n",
- (unsigned long)
- (GC_bytes_allocd + GC_bytes_allocd_before_gc));
+ (unsigned long)GC_get_total_bytes());
(void)GC_printf("Final heap size is %lu bytes\n",
(unsigned long)GC_get_heap_size());
- if (GC_bytes_allocd + GC_bytes_allocd_before_gc < n_tests *
+ if (GC_get_total_bytes() < n_tests *
# ifdef VERY_SMALL_CONFIG
2700000
# else
check_heap_stats();
(void)fflush(stdout);
pthread_attr_destroy(&attr);
- GC_printf("Completed %u collections\n", (unsigned)GC_gc_no);
+ GC_printf("Completed %u collections\n", (unsigned)GC_get_gc_no());
# ifdef PTW32_STATIC_LIB
pthread_win32_thread_detach_np ();
pthread_win32_process_detach_np ();