lwr

Operands

$reg, [imm($reg) / ($reg) / imm / id / id($reg) / id+imm / id+imm($reg)]

Load word right (unaligned) : Loads 1-4 bytes into the least-significant (right) bytes of $t1 starting from the effective byte address and working toward the high byte of the containing word. Use together with 'lwl' to load a full 32-bit word from an unaligned address.

Variants

  • Load word right (unaligned) : Loads 1-4 bytes into the least-significant (right) bytes of $t1 starting from the effective byte address and working toward the high byte of the containing word. Use together with 'lwl' to load a full 32-bit word from an unaligned address. lwr $t1,-100($t2)
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,($t2)
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,-100
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100000
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100($t2)
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,100000($t2)
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label($t2)
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label+100000
  • Load Word Right : Load from 1 to 4 bytes right-justified into $t1, starting with effective memory byte address and continuing through the high-order byte of its word lwr $t1,label+100000($t2)
.data
.align 2
data: .word 0x12345678, 0
.text
# Start $t0 at 0xAABBCCDD; lwr merges bytes from the unaligned word at offset 1. Inspect $t0: 0xAA123456.
la $t1, data
li $t0, 0xAABBCCDD
lwr $t0, 1($t1)