Is PREFETCH.R equivalent to a fence?
No. CMO/prefetch has cache-block semantics and is not a general memory-ordering substitute.
data-read prefetch hint (Zicbop).
PREFETCH.R is a Zicbop cache-block prefetch HINT indicating that the cache block at the effective address formed by rs1 plus sign-extended imm[11:0] is likely to be used for data read soon. The immediate requires imm[4:0]=0; an implementation may cache a copy in an appropriate cache to improve latency, but is not required to do so.
Shows the official CMO/prefetch encoding, offset(base) operands, effective-address-to-cache-block selection, and ISA-visible effects.
PREFETCH.R uses a 32-bit encoding; the animation starts by splitting the official fields.
The example cache-block size is 64 bytes only to show how the address selects a block; the real size is discovered from the execution environment and is not fixed at 64 bytes.
This animation shows only architectural semantics from the RISC-V CMO extension: the effective address selects a cache block, execution can be environment-controlled, and prefetch is an ignorable HINT; it does not model concrete cache state, cache-line size, bus transactions, timing, or performance.
PREFETCH.R is a CMO cache-block prefetch hint; it locates a cache block by effective address but is not an ordinary load/store.
Understand this scenario with real code like «prefetch.r offset(base)».
Understand this scenario with real code like «prefetch.r offset(base)».
No. CMO/prefetch has cache-block semantics and is not a general memory-ordering substitute.
prefetch locates the block with base+offset and requires low 5 offset bits to be zero; the effective address follows the official rule.