adds information for debugging
This commit is contained in:
parent
3422c7cd5c
commit
f0a004be9d
|
@ -76,7 +76,53 @@ template <> struct traits<tgc5c> {
|
|||
|
||||
static constexpr std::array<const uint32_t, 43> reg_byte_offsets{
|
||||
{0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,137,141,145,149,157,165,173,177}};
|
||||
/*
|
||||
For easy lookup:
|
||||
X0 (zero): 0x0000
|
||||
X1 (ra) : 0x0004
|
||||
X2 (sp) : 0x0008
|
||||
X3 (gp) : 0x000c
|
||||
X4 (tp) : 0x0010
|
||||
X5 (t0) : 0x0014
|
||||
X6 (t1) : 0x0018
|
||||
X7 (t2) : 0x001c
|
||||
X8 (s0/fp): 0x0020
|
||||
X9 (s1) : 0x0024
|
||||
X10 (a0) : 0x0028
|
||||
X11 (a1) : 0x002c
|
||||
X12 (a2) : 0x0030
|
||||
X13 (a3) : 0x0034
|
||||
X14 (a4) : 0x0038
|
||||
X15 (a5) : 0x003c
|
||||
X16 (a6) : 0x0040
|
||||
X17 (a7) : 0x0044
|
||||
X18 (s2) : 0x0048
|
||||
X19 (s3) : 0x004c
|
||||
X20 (s4) : 0x0050
|
||||
X21 (s5) : 0x0054
|
||||
X22 (s6) : 0x0058
|
||||
X23 (s7) : 0x005c
|
||||
X24 (s8) : 0x0060
|
||||
X25 (s9) : 0x0064
|
||||
X26 (s10) : 0x0068
|
||||
X27 (s11) : 0x006c
|
||||
X28 (t3) : 0x0070
|
||||
X29 (t4) : 0x0074
|
||||
X30 (t5) : 0x0078
|
||||
X31 (t6) : 0x007c
|
||||
PC : 0x0080
|
||||
NEXT_PC : 0x0084
|
||||
PRIV : 0x0085
|
||||
DPC : 0x0089
|
||||
trap_state : 0x008d
|
||||
pending_trap : 0x0091
|
||||
icount : 0x0095
|
||||
cycle : 0x009d
|
||||
instret : 0x00a5
|
||||
instruction : 0x00ad
|
||||
last_branch : 0x00b1
|
||||
|
||||
*/
|
||||
static const uint64_t addr_mask = (reg_t(1) << (XLEN - 1)) | ((reg_t(1) << (XLEN - 1)) - 1);
|
||||
|
||||
enum sreg_flag_e { FLAGS };
|
||||
|
|
Loading…
Reference in New Issue