diff options
Diffstat (limited to 'sysdeps/mach/thread_state.h')
-rw-r--r-- | sysdeps/mach/thread_state.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sysdeps/mach/thread_state.h b/sysdeps/mach/thread_state.h index 9fa3d4e161..431aaf82ed 100644 --- a/sysdeps/mach/thread_state.h +++ b/sysdeps/mach/thread_state.h @@ -38,6 +38,15 @@ #endif #endif +/* Set up the thread state to call the given function on the given state. + Dependning on architecture, this may imply more than just setting PC + and SP. */ +#ifndef MACHINE_THREAD_STATE_SETUP_CALL +#define MACHINE_THREAD_STATE_SETUP_CALL(ts, stack, size, func) \ + (MACHINE_THREAD_STATE_SET_PC (ts, func), \ + MACHINE_THREAD_STATE_SET_SP (ts, stack, size)) +#endif + /* This copies architecture-specific bits from the current thread to the new thread state. */ #ifndef MACHINE_THREAD_STATE_FIX_NEW |