On Thu, Apr 4, 2024 at 5:02 AM Eric DeVolder <eric_devol...@yahoo.com> wrote: > > I've been using QEMU8 to collect instruction information on U-Boot + OpenSBI. > > I'm running QEMU in this fashion to collect the information: > > # qemu-system-riscv64 -plugin file=qemu/build/contrib/plugins/libexeclog.so > -singlestep -d plugin,nochain -D execlog.txt ... > > When examining the instruction trace in execlog, I've noticed that the > disassembly for pmpcfg0 is erroneous, for example: > > 0, 0x5456, 0x3a002573, "csrrs a0,pmpcfg3,zero" > > the CSR encoded in the instruction above is 0x3a0, which is pmpcfg0 (which > also matches the code I'm examining). > > For the Uboot+OpenSBI code I'm examining, pmpcfg0/3 is the only one that > appears to have a problem. > > I also checked QEMU9 and it behaves as described above as well. > > I'm willing to provide a fix if I can get some advice/pointers on how this > disassembly statement is generated...I did take a quick look but it didn't > appear obvious how...
Thanks for pointing this out. This should fix the issue for you: https://patchew.org/QEMU/20240514051615.330979-1-alistair.fran...@wdc.com/ Alistair > > Thanks, > eric >