mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Merge branch 'bugfix/xtensa_extra_info_register_values' into 'master'
espcoredump.py: Parse EPS and EPC register values using register index See merge request espressif/esp-idf!14448
This commit is contained in:
commit
3e84e5e668
@ -89,19 +89,19 @@ class ExceptionRegisters(object):
|
|||||||
# extra regs IDs used in EXTRA_INFO note
|
# extra regs IDs used in EXTRA_INFO note
|
||||||
EXCCAUSE_IDX = 0
|
EXCCAUSE_IDX = 0
|
||||||
EXCVADDR_IDX = 1
|
EXCVADDR_IDX = 1
|
||||||
EPS2_IDX = 2
|
EPC1_IDX = 177
|
||||||
EPS3_IDX = 3
|
EPC2_IDX = 178
|
||||||
EPS4_IDX = 4
|
EPC3_IDX = 179
|
||||||
EPS5_IDX = 5
|
EPC4_IDX = 180
|
||||||
EPS6_IDX = 6
|
EPC5_IDX = 181
|
||||||
EPS7_IDX = 7
|
EPC6_IDX = 182
|
||||||
EPC1_IDX = 8
|
EPC7_IDX = 183
|
||||||
EPC2_IDX = 9
|
EPS2_IDX = 194
|
||||||
EPC3_IDX = 10
|
EPS3_IDX = 195
|
||||||
EPC4_IDX = 11
|
EPS4_IDX = 196
|
||||||
EPC5_IDX = 12
|
EPS5_IDX = 197
|
||||||
EPC6_IDX = 13
|
EPS6_IDX = 198
|
||||||
EPC7_IDX = 14
|
EPS7_IDX = 199
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def registers(self): # type: () -> dict[str, int]
|
def registers(self): # type: () -> dict[str, int]
|
||||||
@ -142,19 +142,16 @@ def print_exc_regs_info(extra_info): # type: (list[int]) -> None
|
|||||||
exccause_str = ('Invalid EXCCAUSE code', 'Invalid EXCAUSE description or not found.')
|
exccause_str = ('Invalid EXCCAUSE code', 'Invalid EXCAUSE description or not found.')
|
||||||
print('exccause 0x%x (%s)' % (exccause, exccause_str[0]))
|
print('exccause 0x%x (%s)' % (exccause, exccause_str[0]))
|
||||||
print('excvaddr 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EXCVADDR_IDX + 1])
|
print('excvaddr 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EXCVADDR_IDX + 1])
|
||||||
print('epc1 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC1_IDX + 1])
|
|
||||||
print('epc2 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC2_IDX + 1])
|
# skip crashed_task_tcb, exccause, and excvaddr
|
||||||
print('epc3 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC3_IDX + 1])
|
for i in range(5, len(extra_info), 2):
|
||||||
print('epc4 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC4_IDX + 1])
|
if (extra_info[i] >= ExceptionRegisters.EPC1_IDX and extra_info[i] <= ExceptionRegisters.EPC7_IDX):
|
||||||
print('epc5 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC5_IDX + 1])
|
print('epc%d 0x%x' % ((extra_info[i] - ExceptionRegisters.EPC1_IDX + 1), extra_info[i + 1]))
|
||||||
print('epc6 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC6_IDX + 1])
|
|
||||||
print('epc7 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPC7_IDX + 1])
|
# skip crashed_task_tcb, exccause, and excvaddr
|
||||||
print('eps2 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS2_IDX + 1])
|
for i in range(5, len(extra_info), 2):
|
||||||
print('eps3 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS3_IDX + 1])
|
if (extra_info[i] >= ExceptionRegisters.EPS2_IDX and extra_info[i] <= ExceptionRegisters.EPS7_IDX):
|
||||||
print('eps4 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS4_IDX + 1])
|
print('eps%d 0x%x' % ((extra_info[i] - ExceptionRegisters.EPS2_IDX + 2), extra_info[i + 1]))
|
||||||
print('eps5 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS5_IDX + 1])
|
|
||||||
print('eps6 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS6_IDX + 1])
|
|
||||||
print('eps7 0x%x' % extra_info[1 + 2 * ExceptionRegisters.EPS7_IDX + 1])
|
|
||||||
|
|
||||||
|
|
||||||
# from "gdb/xtensa-tdep.h"
|
# from "gdb/xtensa-tdep.h"
|
||||||
|
@ -45,19 +45,17 @@ Crashed task handle: 0x3ffb5e80, name: 'main', GDB name: 'process 1073438336'
|
|||||||
================== CURRENT THREAD REGISTERS ===================
|
================== CURRENT THREAD REGISTERS ===================
|
||||||
exccause 0x1d (StoreProhibitedCause)
|
exccause 0x1d (StoreProhibitedCause)
|
||||||
excvaddr 0x1
|
excvaddr 0x1
|
||||||
epc1 0x0
|
epc1 0x400e38bf
|
||||||
epc2 0x0
|
epc2 0x0
|
||||||
epc3 0x0
|
epc3 0x0
|
||||||
epc4 0x0
|
epc4 0x0
|
||||||
epc5 0x0
|
epc5 0x0
|
||||||
epc6 0x0
|
epc6 0x0
|
||||||
epc7 0x0
|
|
||||||
eps2 0x0
|
eps2 0x0
|
||||||
eps3 0x0
|
eps3 0x0
|
||||||
eps4 0x0
|
eps4 0x0
|
||||||
eps5 0x0
|
eps5 0x0
|
||||||
eps6 0x0
|
eps6 0x0
|
||||||
eps7 0x400e38bf
|
|
||||||
pc 0x400e37f7 0x400e37f7
|
pc 0x400e37f7 0x400e37f7
|
||||||
lbeg 0x0 0
|
lbeg 0x0 0
|
||||||
lend 0x0 0
|
lend 0x0 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user