chipsalliance / Cores-VeeR-EL2

VeeR EL2 Core
https://chipsalliance.github.io/Cores-VeeR-EL2/html/
Apache License 2.0
243 stars 73 forks source link

WFI instruction is missing? #104

Open Risto97 opened 1 year ago

Risto97 commented 1 year ago

I am not sure if I understood the documentation correctly, but it seems like the WFI (wait for interrupt) instruction is not implemented? Or rather just implemented as NOP

These are the only references I could find to wfi:

Docs 5.5.2

Note: WFI is another candidate for a function that stops the core temporarily. Currently, the WFI instruction is
implemented as NOP, which is a fully RISC-V-compliant option. 

This one is in the Core Pause section, and it could mean that the core can be paused with WFI, but it is equivalent to NOP in the EL2 implementation?

And 7.5

37 NOP is an ALU operation. WFI is implemented as a NOP in VeeR EL2 and, hence, counted as an ALU operation was well. 

Any plans to support it, so that the core goes to C3 (sleep) state after the WFI? If so can you estimate the complexity and give guidelines on implementing it?