summaryrefslogtreecommitdiff
path: root/mark_rts.c
diff options
context:
space:
mode:
authorivmai <ivmai>2009-10-21 11:33:39 +0200
committerIvan Maidanski <ivmai@mail.ru>2011-07-26 19:06:51 +0200
commitbad4c7acb6060861cd4be55968c1f58b2026a747 (patch)
treee4772ccd33aeec9ccd4d9baadbadb48a913a13e2 /mark_rts.c
parentc4e4721f491632c2039cece14400f353794273f4 (diff)
2009-10-21 Ivan Maidanski <ivmai@mail.ru>
* allchblk.c (DEBUG): Remove macro (since unused). * allchblk.c: Include private/gc_priv.h before other includes and definitions. * alloc.c: Ditto. * gc_dlopen.c: Ditto. * headers.c: Ditto. * mallocx.c: Ditto. * mark_rts.c: Ditto. * new_hblk.c: Ditto. * reclaim.c: Ditto. * mark.c: Include private/gc_pmark.h before other includes. * misc.c: Ditto. * dyn_load.c (_GNU_SOURCE): Move the definition to gc_priv.h. * pthread_support.c (_USING_POSIX4A_DRAFT10): Ditto. * pthread_support.c (_POSIX4A_DRAFT10_SOURCE): Remove (since already defined in gc_config_macros.h). * dyn_load.c (GC_init_dyld): Remove parameter cast for _dyld_register_func_for_add_image() and _dyld_register_func_for_remove_image(); add the comment about possible warnings; add FIXME for the deprecated _dyld_bind_fully_image_containing_address(). * include/private/gc_priv.h: Include gc.h before the standard headers inclusion. * tests/test.c: Ditto. * include/private/gcconfig.h (DebugBreak): Update the comment. * typd_mlc.c (ED_INITIAL_SIZE): Remove ';'. * alloc.c: Reformat the code (partly adjust indentation). * backgraph.c: Ditto. * blacklst.c: Ditto. * checksums.c: Ditto. * finalize.c: Ditto. * gcj_mlc.c: Ditto. * mach_dep.c: Ditto. * mark_rts.c: Ditto. * obj_map.c: Ditto. * os_dep.c: Ditto. * ptr_chck.c: Ditto. * stubborn.c: Ditto. * thread_local_alloc.c: Ditto. * typd_mlc.c: Ditto.
Diffstat (limited to 'mark_rts.c')
-rw-r--r--mark_rts.c25
1 files changed, 13 insertions, 12 deletions
diff --git a/mark_rts.c b/mark_rts.c
index 62bc041..b872319 100644
--- a/mark_rts.c
+++ b/mark_rts.c
@@ -11,8 +11,10 @@
* provided the above notices are retained, and a notice that the code was
* modified is included with the above copyright notice.
*/
-# include <stdio.h>
-# include "private/gc_priv.h"
+
+#include "private/gc_priv.h"
+
+#include <stdio.h>
/* Data structure for list of root sets. */
/* We keep a hash table, so that we can filter out duplicate additions. */
@@ -35,13 +37,12 @@ struct roots GC_static_roots[MAX_ROOT_SETS];
int GC_no_dls = 0; /* Register dynamic library data segments. */
static int n_root_sets = 0;
-
/* GC_static_roots[0..n_root_sets) contains the valid root sets. */
-# if !defined(NO_DEBUGGING)
-/* For debugging: */
-void GC_print_static_roots(void)
-{
+#if !defined(NO_DEBUGGING)
+ /* For debugging: */
+ void GC_print_static_roots(void)
+ {
int i;
size_t total = 0;
@@ -57,12 +58,11 @@ void GC_print_static_roots(void)
GC_err_printf("GC_root_size incorrect: %ld!!\n",
(long) GC_root_size);
}
-}
-# endif /* NO_DEBUGGING */
+ }
+#endif /* !NO_DEBUGGING */
/* Primarily for debugging support: */
-/* Is the address p in one of the registered static */
-/* root sections? */
+/* Is the address p in one of the registered static root sections? */
GC_bool GC_is_static_root(ptr_t p)
{
static int last_root_set = MAX_ROOT_SETS;
@@ -654,7 +654,8 @@ STATIC void GC_push_current_stack(ptr_t cold_gc_frame, void * context)
/* "activation frame" in backing store. */
if (GC_activation_frame != NULL && cold_gc_bs_pointer <
GC_activation_frame->backing_store_end)
- cold_gc_bs_pointer = GC_activation_frame->backing_store_end;
+ cold_gc_bs_pointer =
+ GC_activation_frame->backing_store_end;
GC_push_all_register_frames(BACKING_STORE_BASE,
cold_gc_bs_pointer, FALSE, GC_activation_frame);
GC_push_all_eager(cold_gc_bs_pointer, bsp);