Does HINVAL.GVMA provide ordering by itself?
Full ordering is not guaranteed alone. SFENCE.W.INVAL and SFENCE.INVAL.IR provide sequence ordering boundaries; implementations may use full HFENCE.
Svinval/H G-stage translation invalidation: rs1 selects GPA>>2, rs2 selects VMID, and ordering is supplied by split fences.
HINVAL.GVMA is the Hypervisor + Svinval G-stage address-translation-cache invalidation instruction. It invalidates G-stage translation-cache entries matching rs1/rs2; rs1≠x0 contains the guest physical address shifted right by 2 bits (GPA>>2), and rs2≠x0 specifies a VMID. rs1=x0 selects all guest physical addresses, and rs2=x0 selects all VMIDs. It does not guarantee full ordering alone; SFENCE.W.INVAL and SFENCE.INVAL.IR supply the sequence ordering boundaries. Implementations may use the full matching HFENCE.
Svinval/H G-stage invalidation: shows SYSTEM encoding, rs1/rs2 scope selection, and Svinval/H invalidation without modeling TLB or cache implementation.
This example assumes H and Svinval, equal host/guest XLEN, valid addresses, and maximum implemented ID widths (RV32: ASID 9/VMID 7; RV64: ASID 16/VMID 14). High rs2 bits above the ID width are ignored; software should zero reserved high bits. Implementations may fence/invalidate a broader scope. The GPA input is shifted right by two into rs1; the register value is not shifted again.
This animation shows only the local-hart translation fence/invalidation semantics defined by the privileged architecture; it does not show OS shootdown protocols, TLB structures, cache flushes, page-walk latency, or platform interrupt mechanisms.
HINVAL.GVMA is the G-stage invalidation action inside a split-fence sequence: rs1 uses GPA>>2, rs2 uses VMID, and full ordering is not guaranteed by this instruction alone.
Understand this scenario with real code like «sfence.w.inval hinval.gvma a1, a2 # a1 = GPA >> 2; a2 = VMID sfence.inval.ir».
Full ordering is not guaranteed alone. SFENCE.W.INVAL and SFENCE.INVAL.IR provide sequence ordering boundaries; implementations may use full HFENCE.
No. HINVAL.GVMA with rs1≠x0 is GPA>>2; HINVAL.VVMA rs1 is guest virtual address.