riscv / riscv-CMOs

https://jira.riscv.org/browse/RVG-59
Creative Commons Attribution 4.0 International
77 stars 12 forks source link

What access permission do CMO instructions require? #64

Closed jinyinghan324 closed 1 year ago

jinyinghan324 commented 1 year ago

cbo.flush, cbo.clean and cbo.zero requires Read or Write or Execute permission?

ingallsj commented 1 year ago

Read Permission, according to this section of the spec (bold emphasis added):

A cache-block management instruction is permitted to access the specified cache block whenever a load instruction or store instruction is permitted to access the corresponding physical addresses. If neither a load instruction nor store instruction is permitted to access the physical addresses, but an instruction fetch is permitted to access the physical addresses, whether a cache-block management instruction is permitted to access the cache block is UNSPECIFIED.