HFENCE.GVMA
Hypervisor Fence for G-stage Address Translation
HFENCE.GVMA rs1, rs2
Orders prior stores before later implicit G-stage (guest-physical) translation reads.
Encoding
Binary Layout
0110001
31:25
rs2
24:20
rs1
19:15
000000001110011
14:0
Operands
-
rs1
Guest physical address shifted right by 2 (x0 for all addresses) -
rs2
VMID (x0 for all VMIDs)
Example
HFENCE.GVMA x0, x0
// Order all G-stage translations.
Related
More in H
Reference
View in RISC-V Unprivileged ISA Specification ↗
RISC-V ISA Manual
Description
HFENCE.GVMA guarantees that previous stores visible to this hart are ordered before the implicit reads it makes for G-stage address translation for later instructions. If rs1 is not x0 it names a single guest physical address, shifted right by 2 bits; if rs2 is not x0 it names a single VMID. HFENCE.GVMA x0, x0 orders all G-stage translation. Valid in HS-mode when mstatus.TVM=0, or in M-mode; when V=1 it raises a virtual-instruction exception.
Operation
Fence(GuestPageTable);