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