Check vl first
The current vl determines the number of body elements. Typical code executes vsetvli, vsetivli, or vsetvl before this instruction.
Vector rotate right by scalar amount; each vs2 element uses the low log2(SEW) bits of the amount.
VROR.VX is a Zvbb vector rotate-right instruction. Each active element takes data from vs2 and rotates it by the amount from x[rs1]; only the low log2(SEW) bits of the amount are used.
VROR.VX performs a Zvbb rotate right on each active element; the scalar operand supplies only the rotate amount and data comes from vs2.
When reading VROR.VX, do not stop at the mnemonic. Official V-extension semantics also depend on the current vl, vtype, and mask state. .vx: one vector source and one integer scalar source participate.
The current vl determines the number of body elements. Typical code executes vsetvli, vsetivli, or vsetvl before this instruction.
The current vtype supplies SEW, LMUL, tail policy, and mask policy; these affect element width, register-group size, and inactive/tail destination elements.
For ordinary vector instructions with vm, vm=0 uses v0 as the execution mask and vm=1 is unmasked. A few forms such as VMERGE use v0 as data-selection input.
Understand this scenario with real code like «vror.vx vd, vs2, a1».
Understand this scenario with real code like «vror.vx vd, vs2, a1».
No. The result element width remains the current SEW.
Rotate keeps the same width and wraps bits; VWSLL is a widening logical left shift with a 2*SEW destination.