sext.h

Sign-extends the least-significant halfword in the source to XLEN by copying the most-significant bit in the halfword (i.e., bit 15) to all of the more-significant bits.

Synopsis

sext.h xd, xs1

Encoding

Type:

067111214151920310010011xd001xs1011000000101
funct7: 0110000
funct3: 001
opcode: 0010011

RISC-V Instruction Encoder/Decoder

open sext.h in rvcodecjs

Availability