]> gitweb.factorcode.org Git - factor.git/blob - vm/os-linux-x86.64.hpp
Merge branch 'hashcash' of git://github.com/martind/factor
[factor.git] / vm / os-linux-x86.64.hpp
1 #include <ucontext.h>
2
3 namespace factor
4 {
5
6 inline static void *ucontext_stack_pointer(void *uap)
7 {
8         ucontext_t *ucontext = (ucontext_t *)uap;
9         return (void *)ucontext->uc_mcontext.gregs[15];
10 }
11
12 #define UAP_PROGRAM_COUNTER(ucontext) \
13         (((ucontext_t *)(ucontext))->uc_mcontext.gregs[16])
14
15 }