2018-04-25 18:11:59 +02:00
|
|
|
#include <stdint.h>
|
|
|
|
|
2018-06-22 09:12:32 +02:00
|
|
|
typedef enum {
|
|
|
|
UNWF_RIP=0,
|
|
|
|
UNWF_RSP=1,
|
|
|
|
UNWF_RBP=2,
|
2018-06-22 09:14:56 +02:00
|
|
|
UNWF_RBX=3,
|
2018-06-22 09:12:32 +02:00
|
|
|
|
|
|
|
UNWF_ERROR=7
|
|
|
|
} unwind_flags_t;
|
|
|
|
|
2018-04-25 18:11:59 +02:00
|
|
|
typedef struct {
|
2018-06-22 09:12:32 +02:00
|
|
|
uint8_t flags;
|
2018-06-22 09:14:56 +02:00
|
|
|
uintptr_t rip, rsp, rbp, rbx;
|
2018-04-25 18:11:59 +02:00
|
|
|
} unwind_context_t;
|
2018-04-27 11:05:34 +02:00
|
|
|
|
2018-06-01 19:46:43 +02:00
|
|
|
typedef uintptr_t (*deref_func_t)(uintptr_t);
|
2018-06-04 15:17:23 +02:00
|
|
|
|
|
|
|
typedef unwind_context_t (*_fde_func_t)(unwind_context_t, uintptr_t);
|
|
|
|
typedef unwind_context_t (*_fde_func_with_deref_t)(
|
|
|
|
unwind_context_t,
|
|
|
|
uintptr_t,
|
|
|
|
deref_func_t);
|