Hello,
I met a problem that Rocket Chips could not identify the custom instruction. I applied the example ROCC in my design and it shows there are some illegal instructions.
Here are the links to the repositories I used in my design:
I added the example ROCC by editing the system/config.scala in the fpga-rocket-chip and added mstatus_xs support to riscv-pk as the recommendation of the rocket-rocc-examples. Finally, I compiled the pk test program in rocket-rocc-examples.
Then, I met such an error:
# ./example
[INFO] Write R[1example[44]: unhandled signal 4 code 0x1 at 0x00000000000101f2 in example[10000+e000]
] = 0xdead
CPU: 0 PID: 44 Comm: example Not tainted 4.19.288 #8
sepc: 00000000000101f2 ra : 00000000000101ea sp : 0000003fffe8bdc0
gp : 000000000001f418 tp : 00000000000d2760 t0 : 00000000000104fc
t1 : ffffffffffffffff t2 : 0000000000000001 s0 : 0000003fffe8be10
s1 : 00000000000d3778 a0 : 000000000000001b a1 : 0000000000020010
a2 : 000000000000001b a3 : 000000000000001b a4 : 0000000000000001
a5 : 000000000000dead a6 : 0000000000000004 a7 : 0000000000000040
s2 : 00000000000bdfa6 s3 : 000000000009b1a0 s4 : 00000000000d37b0
s5 : 0000000000000008 s6 : 00000000000d27e0 s7 : 00000000000d3788
s8 : 00000000000d3798 s9 : 0000000000000000 s10: 0000000000000000
s11: 0000000000000000 t3 : 0000000000000078 t4 : 0000003fff8369b0
t5 : 00000000000d11d8 t6 : 00000000000c4988
sstatus: 8000000200006020 sbadaddr: 0000000000e7f78b scause: 0000000000000002
Illegal instruction
Do you have an idea about this error? What could I do to fix it?
Thanks,
Yuhe Zhao