slli.uw

Shift unsigned word left by immediate RV64 only

Sets the first register to the low 32 bits of the second, zero-extended and shifted left by an immediate amount.

RISC-V manual: slli.uw

Forms

  • slli.uw , ,

Operands

t1
Any integer register, x0 to x31, or its named alias, such as zero, t0 or t6.
t2
An integer register. It may be the same register as t1.
imm5
An unsigned 5-bit immediate, 0 to 31, used for values such as a shift count or a CSR immediate.

Scales an unsigned 32 bit index without a separate zero extension

This example runs on RV64.

.text
li t0, 13
# t0=13, immediate 2; slli.uw writes 52 to t2.
slli.uw t2, t0, 2