lxsb
Load scaled indexed byte
This instruction is defined by:
Synopsis
Load 8 bits of data into register xd from the effective address
X[xs2] + X[xs1], where xs2 is the base and xs1 is the index.
Sign extend the result to XLEN.
The lxb mnemonic is an assembler pseudoinstruction for lxsb.
Decode Variables
Bits<5> xs2 = $encoding[24:20];
Bits<5> xs1 = $encoding[19:15];
Bits<5> xd = $encoding[11:7];
Execution
-
Pruned, XLEN == 64
-
Original
XReg virtual_address = X[xs2] + X[xs1];
X[xd] = sext(read_memory(8, virtual_address, $encoding), 8);
XReg virtual_address = X[xs2] + X[xs1];
X[xd] = sext(read_memory(8, virtual_address, $encoding), 8);