feature (memory management): implemented a function to read the caller from the stack
This commit is contained in:
parent
7d33377806
commit
263e7305cf
|
@ -11,4 +11,6 @@
|
||||||
void stack_dump_call_info (uint64_t rip, symbol_T* symbol);
|
void stack_dump_call_info (uint64_t rip, symbol_T* symbol);
|
||||||
void stack_trace_call_stack (uint64_t rbp);
|
void stack_trace_call_stack (uint64_t rbp);
|
||||||
|
|
||||||
|
extern uint64_t stack_get_caller();
|
||||||
|
|
||||||
#endif //NOX_STACK_H
|
#endif //NOX_STACK_H
|
||||||
|
|
|
@ -0,0 +1,7 @@
|
||||||
|
; This file is part of noxos and licensed under the MIT open source license
|
||||||
|
|
||||||
|
stack_get_caller:
|
||||||
|
mov rax, [rbp + 0x8]
|
||||||
|
ret
|
||||||
|
|
||||||
|
GLOBAL stack_get_caller
|
Loading…
Reference in New Issue