riscv-non-isa/riscv-trace-spec

trigger[2:0] behaviors for exception

zhonghochen opened this issue · 5 comments

Hi, Guys

https://github.com/riscv/riscv-trace-spec/blob/9896e28a5b35d86178c08e77e0ae6daaafeba072/ingressPort.tex#L492-L493

Could you help to clarify whether trigger[2:0] should be generated for non-retired instruction?

  • mcontrol.execute is set,
  • An instruction matches the trigger, and
  • The instruction causes an exception (e.g. ecall, illegal instruction, and address misaligned)

Regards,
Zhong-Ho

Hi, Iain,

Thanks for your replies. Since the behavior is dependent on usage, do you think the timing field in mcontrol can be used to control the behavior of trigger[2:0] ?

Regards,
Zhong-Ho

That behavior is a property of the trigger module, not trace. Trace does whatever the trigger module tells it to do.

I opened riscv/riscv-debug-spec#670 about this. There I gave what I'm reasonably sure is the correct answer but we'll see if there are any other opinions. That debug spec issue will make sure that the spec gets clarified by the debug task group (which will likely be done by me).

Resolved