mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-09 13:12:37 -05:00
mips: add native backtrace implementation
Should make debugging crashes on native MIPS targets far easier. This is by no means a 100% complete or robust implementation but it seems to handle the vast majority of functions. Change-Id: Id5f430270e02b5092b79026b6876675c784aa649
This commit is contained in:
parent
cade488b08
commit
981e972839
9 changed files with 357 additions and 3 deletions
12
lib/mipsunwinder/init_context_32.S
Normal file
12
lib/mipsunwinder/init_context_32.S
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
#include "mips.h"
|
||||
|
||||
.text
|
||||
.global mips_bt_start
|
||||
|
||||
mips_bt_start:
|
||||
addiu v0, ra, -8
|
||||
sw v0, 0(a0) /* ctx->pc = ra - 8 */
|
||||
sw sp, 4(a0) /* ctx->sp = sp */
|
||||
sw zero, 8(a0) /* ctx->depth = 0 */
|
||||
sw zero, 12(a0) /* ctx->valid = 0 */
|
||||
jr ra
|
||||
Loading…
Add table
Add a link
Reference in a new issue