Bug #2258 » 0001-make-SET_STACK_END-macro-respect-rb_thread_t.machine.patch
cont.c | ||
---|---|---|
size_t size;
|
||
rb_thread_t *sth = &cont->saved_thread;
|
||
SET_MACHINE_STACK_END(&th->machine_stack_end);
|
||
SET_THREAD_MACHINE_STACK_END(th);
|
||
#ifdef __ia64
|
||
th->machine_register_stack_end = rb_ia64_bsp();
|
||
#endif
|
gc.c | ||
---|---|---|
}
|
||
#ifdef __ia64
|
||
#define SET_STACK_END (SET_MACHINE_STACK_END(&th->machine_stack_end), th->machine_register_stack_end = rb_ia64_bsp())
|
||
#define SET_STACK_END (SET_THREAD_MACHINE_STACK_END(th), th->machine_register_stack_end = rb_ia64_bsp())
|
||
#else
|
||
#define SET_STACK_END SET_MACHINE_STACK_END(&th->machine_stack_end)
|
||
#define SET_STACK_END SET_THREAD_MACHINE_STACK_END(th)
|
||
#endif
|
||
#define STACK_START (th->machine_stack_start)
|
gc.h | ||
---|---|---|
#define USE_CONSERVATIVE_STACK_END
|
||
#endif
|
||
#define SET_THREAD_MACHINE_STACK_END(th) SET_MACHINE_STACK_END(&th->machine_stack_end);\
|
||
/* keep machine stack pointer within the maximum size limit */\
|
||
if (th->machine_stack_end && th->machine_stack_start - th->machine_stack_end > th->machine_stack_maxsize) {\
|
||
th->machine_stack_end = th->machine_stack_start + th->machine_stack_maxsize;\
|
||
}
|
||
/* for GC debug */
|
||
#ifndef RUBY_MARK_FREE_DEBUG
|
thread.c | ||
---|---|---|
void
|
||
rb_gc_save_machine_context(rb_thread_t *th)
|
||
{
|
||
SET_MACHINE_STACK_END(&th->machine_stack_end);
|
||
SET_THREAD_MACHINE_STACK_END(th);
|
||
FLUSH_REGISTER_WINDOWS;
|
||
#ifdef __ia64
|
||
th->machine_register_stack_end = rb_ia64_bsp();
|