summaryrefslogtreecommitdiff
path: root/allchblk.c
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2016-10-21 01:54:17 +0300
committerIvan Maidanski <ivmai@mail.ru>2016-10-21 01:54:17 +0300
commite421fee566ab8cd71d557ef838d1f02e196e761a (patch)
tree85ec36c1850e789cd4e054b2a472f441bb2d4fab /allchblk.c
parenta117f6c50b082cdd5696af179e6167e5248358b6 (diff)
downloadbdwgc-e421fee566ab8cd71d557ef838d1f02e196e761a.tar.gz
Eliminate 'printf format specifies type void*' GCC pedantic warnings
Explicitly cast pointer arguments (passed to printf and ABORT_ARGn) to void* to match %p format specifier. * allchblk.c [!NO_DEBUGGING] (GC_dump_regions): Cast arguments to void* those printf format specifier is %p. * alloc.c [!NO_DEBUGGING] (GC_print_heap_sects): Likewise. * backgraph.c [MAKE_BACK_GRAPH] (backwards_height): Likewise. * blacklst.c (GC_default_print_heap_obj_proc): Likewise. * blacklst.c [PRINT_BLACK_LIST] (GC_print_blacklisted_ptr): Likewise. * cord/cordbscs.c (CORD_dump_inner): Likewise. * darwin_stop_world.c [DEBUG_THREADS_EXTRA] (GC_FindTopOfStack): Likewise. * darwin_stop_world.c [DEBUG_THREADS] (GC_stack_range_for): Likewise. * dbg_mlc.c (GC_print_obj): Likewise. * dbg_mlc.c [!SHORT_DBG_HDRS] (GC_print_smashed_obj): Likewise. * dyn_load.c [HAVE_DL_ITERATE_PHDR] (GC_register_dynamic_libraries_dl_iterate_phdr): Likewise. * dyn_load.c [IRIX5] (GC_register_dynamic_libraries): Likewise. * finalize.c [!NO_DEBUGGING] (GC_dump_finalization_links, GC_dump_finalization): Likewise. * include/private/gc_pmark.h [MARK_BIT_PER_GRANULE || MARK_BIT_PER_OBJ] (PUSH_CONTENTS_HDR): Likewise. * mark.c [ENABLE_TRACE] (GC_mark_from): Likewise. * mark_rts.c [!NO_DEBUGGING] (GC_print_static_roots): Likewise. * mark_rts.c [DEBUG_ADD_DEL_ROOTS] (GC_add_roots_inner, GC_remove_root_at_pos): Likewise. * misc.c [ENABLE_TRACE] (GC_init): Likewise. * os_dep.c [LINUX || HURD] (GC_init_linux_data_start): Likewise. * os_dep.c [!OS2 && !MSWIN32] (GC_register_data_segments): Likewise. * os_dep.c [USE_MUNMAP && !USE_WINALLOC && !NACL] (GC_remap): Likewise. * os_dep.c [!DARWIN && !MSWIN32 && !MSWINCE] (GC_write_fault_handler): Likewise. * os_dep.c [PROC_VDB && DEBUG_DIRTY_BITS] (GC_read_dirty): Likewise. * os_dep.c [MPROTECT_VDB && DARWIN && BROKEN_EXCEPTION_HANDLING] (catch_exception_raise): Likewise. * pthread_stop_world.c [DEBUG_THREADS] (GC_push_all_stacks): Likewise. * pthread_support.c [DEBUG_THREADS] (GC_unregister_my_thread_inner, GC_unregister_my_thread, GC_start_rtn_prepare_thread): Likewise. * reclaim.c [!NO_DEBUGGING] (GC_print_free_list): Likewise. * specific.c [USE_CUSTOM_SPECIFIC && GC_ASSERTIONS] (GC_check_tsd_marks): Likewise. * win32_threads.c [DEBUG_THREADS] (GC_push_stack_for): Likewise. * win32_threads.c [GC_PTHREADS && DEBUG_THREADS] (GC_pthread_join, GC_pthread_create, GC_pthread_start_inner, GC_thread_exit_proc): Likewise. * dbg_mlc.c: Remove duplicate check of SHORT_DBG_HDRS. * include/private/gc_pmark.h [MARK_BIT_PER_GRANULE || MARK_BIT_PER_OBJ] (PUSH_CONTENTS_HDR): Add missing parentheses around "source" argument when casting it to ptr_t.
Diffstat (limited to 'allchblk.c')
-rw-r--r--allchblk.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/allchblk.c b/allchblk.c
index 56ee86ef..2c1061e0 100644
--- a/allchblk.c
+++ b/allchblk.c
@@ -182,12 +182,13 @@ void GC_dump_regions(void)
++i;
end = GC_heap_sects[i].hs_start + GC_heap_sects[i].hs_bytes;
}
- GC_printf("***Section from %p to %p\n", start, end);
+ GC_printf("***Section from %p to %p\n", (void *)start, (void *)end);
for (p = start; (word)p < (word)end; ) {
hdr *hhdr = HDR(p);
if (IS_FORWARDING_ADDR_OR_NIL(hhdr)) {
- GC_printf("\t%p Missing header!!(%p)\n", p, (void *)hhdr);
+ GC_printf("\t%p Missing header!!(%p)\n",
+ (void *)p, (void *)hhdr);
p += HBLKSIZE;
continue;
}
@@ -196,8 +197,8 @@ void GC_dump_regions(void)
divHBLKSZ(hhdr -> hb_sz));
int actual_index;
- GC_printf("\t%p\tfree block of size 0x%lx bytes%s\n", p,
- (unsigned long)(hhdr -> hb_sz),
+ GC_printf("\t%p\tfree block of size 0x%lx bytes%s\n",
+ (void *)p, (unsigned long)(hhdr -> hb_sz),
IS_MAPPED(hhdr) ? "" : " (unmapped)");
actual_index = free_list_index_of(hhdr);
if (-1 == actual_index) {
@@ -209,8 +210,8 @@ void GC_dump_regions(void)
}
p += hhdr -> hb_sz;
} else {
- GC_printf("\t%p\tused for blocks of size 0x%lx bytes\n", p,
- (unsigned long)(hhdr -> hb_sz));
+ GC_printf("\t%p\tused for blocks of size 0x%lx bytes\n",
+ (void *)p, (unsigned long)(hhdr -> hb_sz));
p += HBLKSIZE * OBJ_SZ_TO_BLOCKS(hhdr -> hb_sz);
}
}