summaryrefslogtreecommitdiff
path: root/win32_threads.c
diff options
context:
space:
mode:
authorivmai <ivmai>2009-12-08 10:09:06 +0100
committerIvan Maidanski <ivmai@mail.ru>2011-07-26 19:06:52 +0200
commit02b76359f5f6429151a9d1c15ccf4302eb927e80 (patch)
tree6b44914424930622f553ce6b799d9a29cf646a1e /win32_threads.c
parent176d5bda1e4416a306005d5ee66a902e9db6af6d (diff)
2009-12-08 Ivan Maidanski <ivmai@mail.ru> (really mostly Hans Boehm)
* darwin_stop_world.c (GC_push_all_stacks): Rename activation_frame to traced_stack_sect. * include/private/gc_priv.h (GC_push_all_stack_frames, GC_push_all_register_frames): Ditto. * include/private/pthread_support.h (GC_Thread_Rep): Ditto. * mark_rts.c (GC_push_all_register_frames, GC_push_all_stack_frames, GC_push_all_stack_part_eager_frames, GC_push_current_stack): Ditto. * pthread_stop_world.c (GC_push_all_stacks): Ditto. * pthread_support.c (GC_call_with_gc_active): Ditto. * win32_threads.c (GC_Thread_Rep, GC_call_with_gc_active, GC_push_stack_for): Ditto. * include/private/gc_priv.h (GC_activation_frame_s): Rename to GC_traced_stack_sect_s. * include/private/gc_priv.h (GC_activation_frame): Rename to GC_traced_stack_sect. * misc.c (GC_activation_frame, GC_call_with_gc_active): Ditto. * doc/README.macros (UNICODE): Document.
Diffstat (limited to 'win32_threads.c')
-rw-r--r--win32_threads.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/win32_threads.c b/win32_threads.c
index 53e9fff..bd988c3 100644
--- a/win32_threads.c
+++ b/win32_threads.c
@@ -218,7 +218,7 @@ struct GC_Thread_Rep {
/* pointer manipulations. Thus it does */
/* not need to stop this thread. */
- struct GC_activation_frame_s *activation_frame;
+ struct GC_traced_stack_sect_s *traced_stack_sect;
/* Points to the "frame" data held in stack by */
/* the innermost GC_call_with_gc_active() of */
/* this thread. May be NULL. */
@@ -776,7 +776,7 @@ GC_INNER void GC_do_blocking_inner(ptr_t data, void * context)
GC_API void * GC_CALL GC_call_with_gc_active(GC_fn_type fn,
void * client_data)
{
- struct GC_activation_frame_s frame;
+ struct GC_traced_stack_sect_s frame;
GC_thread me;
LOCK(); /* This will block if the world is stopped. */
me = GC_lookup_thread_inner(GetCurrentThreadId());
@@ -802,18 +802,18 @@ GC_API void * GC_CALL GC_call_with_gc_active(GC_fn_type fn,
/* but that probably doesn't hurt. */
frame.saved_backing_store_ptr = me -> backing_store_ptr;
# endif
- frame.prev = me -> activation_frame;
+ frame.prev = me -> traced_stack_sect;
me -> thread_blocked_sp = NULL;
- me -> activation_frame = &frame;
+ me -> traced_stack_sect = &frame;
UNLOCK();
client_data = fn(client_data);
GC_ASSERT(me -> thread_blocked_sp == NULL);
- GC_ASSERT(me -> activation_frame == &frame);
+ GC_ASSERT(me -> traced_stack_sect == &frame);
/* Restore original "frame". */
LOCK();
- me -> activation_frame = frame.prev;
+ me -> traced_stack_sect = frame.prev;
# ifdef IA64
me -> backing_store_ptr = frame.saved_backing_store_ptr;
# endif
@@ -1143,8 +1143,8 @@ STATIC word GC_push_stack_for(GC_thread thread, DWORD me)
int dummy;
ptr_t sp, stack_min;
- struct GC_activation_frame_s *activation_frame =
- thread -> activation_frame;
+ struct GC_traced_stack_sect_s *traced_stack_sect =
+ thread -> traced_stack_sect;
if (thread -> id == me) {
GC_ASSERT(thread -> thread_blocked_sp == NULL);
sp = (ptr_t) &dummy;
@@ -1207,24 +1207,24 @@ STATIC word GC_push_stack_for(GC_thread thread, DWORD me)
if (thread -> last_stack_min == ADDR_LIMIT) {
# ifdef MSWINCE
if (GC_dont_query_stack_min) {
- stack_min = GC_wince_evaluate_stack_min(activation_frame != NULL ?
- (ptr_t)activation_frame : thread -> stack_base);
+ stack_min = GC_wince_evaluate_stack_min(traced_stack_sect != NULL ?
+ (ptr_t)traced_stack_sect : thread -> stack_base);
/* Keep last_stack_min value unmodified. */
} else
# endif
/* else */ {
- stack_min = GC_get_stack_min(activation_frame != NULL ?
- (ptr_t)activation_frame : thread -> stack_base);
+ stack_min = GC_get_stack_min(traced_stack_sect != NULL ?
+ (ptr_t)traced_stack_sect : thread -> stack_base);
UNPROTECT_THREAD(thread);
thread -> last_stack_min = stack_min;
}
} else {
/* First, adjust the latest known minimum stack address if we */
/* are inside GC_call_with_gc_active(). */
- if (activation_frame != NULL &&
- thread -> last_stack_min > (ptr_t)activation_frame) {
+ if (traced_stack_sect != NULL &&
+ thread -> last_stack_min > (ptr_t)traced_stack_sect) {
UNPROTECT_THREAD(thread);
- thread -> last_stack_min = (ptr_t)activation_frame;
+ thread -> last_stack_min = (ptr_t)traced_stack_sect;
}
if (sp < thread -> stack_base && sp >= thread -> last_stack_min) {
@@ -1257,7 +1257,7 @@ STATIC word GC_push_stack_for(GC_thread thread, DWORD me)
GC_printf("Pushing stack for 0x%x from sp %p to %p from 0x%x\n",
(int)thread -> id, sp, thread -> stack_base, (int)me);
# endif
- GC_push_all_stack_frames(sp, thread->stack_base, activation_frame);
+ GC_push_all_stack_frames(sp, thread->stack_base, traced_stack_sect);
} else {
/* If not current thread then it is possible for sp to point to */
/* the guarded (untouched yet) page just below the current */
@@ -1271,7 +1271,7 @@ STATIC word GC_push_stack_for(GC_thread thread, DWORD me)
(int)thread -> id, stack_min,
thread -> stack_base, (int)me);
# endif
- /* Push everything - ignore activation "frames" data. */
+ /* Push everything - ignore "traced stack section" data. */
GC_push_all_stack(stack_min, thread->stack_base);
}
return thread->stack_base - sp; /* stack grows down */