summaryrefslogtreecommitdiff
path: root/misc.c
diff options
context:
space:
mode:
authorivmai <ivmai>2011-04-02 17:57:23 +0200
committerIvan Maidanski <ivmai@mail.ru>2011-07-26 19:06:57 +0200
commit4b9291d6231d2b702e25b035e6e8c73aebc8473f (patch)
treef017d0405dce8885d25fe66b63895342d719ca67 /misc.c
parentc722dc23c07dc73f0a3f73d5f54d9b39a25bea2d (diff)
2011-04-02 Ivan Maidanski <ivmai@mail.ru>
* allchblk.c (GC_print_hblkfreelist): Adjust (make uniform across BDWGC) printed message (adjust letters case, terminating dot and new line symbols). * alloc.c (GC_check_fl_marks): Ditto. * backgraph.c (new_back_edges): Ditto. * checksums.c (GC_check_dirty): Ditto. * darwin_stop_world.c (GC_push_all_stacks, GC_suspend_thread_list): Ditto. * dbg_mlc.c (GC_print_type, GC_debug_free, GC_debug_realloc, store_old): Ditto. * dyn_load.c (GC_register_dynamic_libraries): Ditto. * mark.c (GC_initiate_gc, GC_mark_some, GC_mark_from, GC_push_all, GC_push_selected, GC_push_next_marked_dirty): Ditto. * mark_rts.c (GC_exclude_static_roots_inner): Ditto. * os_dep.c (GC_remap, GC_default_push_other_roots, GC_push_thread_structures, GC_dirty_init, GC_read_dirty, catch_exception_raise_state, catch_exception_raise_state_identity, GC_mprotect_thread_notify, GC_mprotect_thread, catch_exception_raise): Ditto. * pthread_stop_world.c (GC_print_sig_mask, GC_push_all_stacks, GC_stop_world, GC_stop_init): Ditto. * pthread_support.c (GC_thr_init, GC_register_my_thread_inner, GC_start_routine): Ditto. * win32_threads.c (GC_register_my_thread_inner, GC_push_all_stacks, GC_win32_start_inner, GC_pthread_join, GC_pthread_start_inner): Ditto. * alloc.c (GC_expand_hp_inner): Realign the code. * mark.c (GC_mark_from, GC_mark_local, GC_do_parallel_mark): Ditto. * misc.c (GC_init): Ditto. * os_dep.c (GC_dirty_init, GC_read_dirty): Ditto. * include/private/gc_pmark.h (PUSH_CONTENTS_HDR): Ditto. * tests/test.c (run_one_test): Ditto. * misc.c (GC_err_puts): Document. * misc.c (GC_err_write): Remove. * os_dep.c (dump_maps): Ditto. * include/private/gc_priv.h (GC_err_write): Ditto. * os_dep.c (GC_print_address_map): Call GC_err_puts() instead of dump_maps() and GC_err_write(). * os_dep.c (GC_read_dirty): Remove redundant brackets.
Diffstat (limited to 'misc.c')
-rw-r--r--misc.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/misc.c b/misc.c
index 6533843..b9a01e5 100644
--- a/misc.c
+++ b/misc.c
@@ -924,8 +924,7 @@ GC_API void GC_CALL GC_init(void)
if (sz_str != NULL) {
initial_heap_sz = (word)STRTOULL(sz_str, NULL, 10);
if (initial_heap_sz <= MINHINCR * HBLKSIZE) {
- WARN("Bad initial heap size %s - ignoring it.\n",
- sz_str);
+ WARN("Bad initial heap size %s - ignoring it.\n", sz_str);
}
initial_heap_sz = divHBLKSZ(initial_heap_sz);
}
@@ -935,8 +934,7 @@ GC_API void GC_CALL GC_init(void)
if (sz_str != NULL) {
word max_heap_sz = (word)STRTOULL(sz_str, NULL, 10);
if (max_heap_sz < initial_heap_sz * HBLKSIZE) {
- WARN("Bad maximum heap size %s - ignoring it.\n",
- sz_str);
+ WARN("Bad maximum heap size %s - ignoring it.\n", sz_str);
}
if (0 == GC_max_retries) GC_max_retries = 2;
GC_set_max_heap_size(max_heap_sz);
@@ -1301,18 +1299,12 @@ void GC_log_printf(const char *format, ...)
ABORT("write to log failed");
}
+/* This is equivalent to GC_err_printf("%s",s). */
void GC_err_puts(const char *s)
{
if (WRITE(GC_stderr, s, strlen(s)) < 0) ABORT("write to stderr failed");
}
-#if defined(LINUX) && !defined(SMALL_CONFIG)
- GC_INNER void GC_err_write(const char *buf, size_t len)
- {
- if (WRITE(GC_stderr, buf, len) < 0) ABORT("write to stderr failed");
- }
-#endif
-
STATIC void GC_CALLBACK GC_default_warn_proc(char *msg, GC_word arg)
{
GC_err_printf(msg, arg);