Last active
May 14, 2020 05:46
-
-
Save etaf/6beff8a56aff0ddce6d13f32b8f61e1d to your computer and use it in GitHub Desktop.
arm framepointer stacktrace
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
prologue: | |
mov ip, sp | |
stmdb sp!, {fp, ip, lr, pc} | |
sub fp, ip, #4 | |
epilogue: | |
ldm sp, {fp, sp, pc} | |
====== | |
==stack==== | |
prologue: | |
... <-----pre_sp | |
pre_pc, <-----fp | |
pre_lr // lr of last frame's return address | |
pre_sp // sp of last frame's sp | |
pre_fp // fp of last frame's fp | |
<-----sp | |
epilogue: | |
fp = pre_fp | |
sp = pre_sp | |
pc = pre_lr | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment