Lines Matching refs:_thread
58 #define CONTEXT(_thread) (&(_thread)->md.context)
65 #define _MD_INIT_CONTEXT(_thread, _sp, _main, status) \
68 getcontext(CONTEXT(_thread)); \
69 CONTEXT(_thread)->uc_stack.ss_sp = (char*) (_thread)->stack->stackBottom; \
70 CONTEXT(_thread)->uc_stack.ss_size = (_thread)->stack->stackSize; \
71 _MD_GET_SP(_thread) = (greg_t) (_sp) - 64; \
72 makecontext(CONTEXT(_thread), _main, 0); \
75 #define _MD_SWITCH_CONTEXT(_thread) \
76 if (!getcontext(CONTEXT(_thread))) { \
77 (_thread)->md.errcode = errno; \
84 #define _MD_RESTORE_CONTEXT(_thread) \
86 ucontext_t *uc = CONTEXT(_thread); \
89 _MD_SET_CURRENT_THREAD(_thread); \
90 errno = (_thread)->md.errcode; \
178 #define _MD_CLEAN_THREAD(_thread)