Webcentive RISC-V Reference

sext.w

Pseudo-op

Extension
RV32I/RV64I base integer
XLEN
RV64 only
Operand fields
rs1, rd
Length
32-bit

Encoding

listed in riscv-opcodes as a pseudo-op of addiw

3120191514121176210
000000000000rs1000rd0011011

Match 0x0000001b, mask 0xfff0707f. Source: $pseudo_op rv64_i::addiw sext.w rd rs1 31..20=0 14..12=0 6..2=0x06 1..0=3 in riscv-opcodes/extensions/rv64_i.

FieldBitsriscv-opcodes name
rs119:15rs1
rd11:7rd

Description

Encoding only. riscv-opcodes lists sext.w as a pseudo-op of addiw: the same encoding as addiw with the fixed fields shown above.

Specification and related pages