![](http://datasheet.mmic.net.cn/380000/-PD98501_datasheet_16745028/-PD98501_100.png)
CHAPTER 2 V
R
4120A
100
Preliminary User’s Manual S14767EJ1V0UM00
Table 2-35. Load and Store Instructions (2/3)
Instruction
Format and Description
Load Word Unsigned
LWU ry, offset (rx)
The 5-bit immediate is shifted left two bits, zero extended to 64 bits, and then added to the contents of
general register rx to form the virtual address. The word of the memory location specified by the
address is zero extended and loaded to general register ry.
If either of the two lower bits of the address is not 0, an address error exception is generated.
This operation is defined in the 64-bit mode and the 32-bit kernel mode. When this instruction is
executed in the 32-bit user/supervisor mode, a reserved instruction exception is generated.
LD ry, offset (rx)
The 5-bit immediate is shifted left three bits, zero extended to 64 bits, and then added to the contents
of general register rx to form the virtual address. The 64-bit doubleword of the memory location
specified by the address is loaded to general register ry.
If any of the lower three bits of the address is not 0, an address error exception is generated.
This operation is defined in the 64-bit mode and the 32-bit kernel mode. When this instruction is
executed in the 32-bit user/supervisor mode, a reserved instruction exception is generated.
LD ry, offset (pc)
The lower three bits of the base PC value related to the instruction are cleared to form the masked
BasePC value. The 5-bit immediate is shifted left three bits, zero extended to 64 bits, and then added
to the masked BasePC to form the virtual address. The 64-bit doubleword at the memory location
specified by the address is loaded to general register ry.
This operation is defined in the 64-bit mode and the 32-bit kernel mode. When this instruction is
executed in the 32-bit user/supervisor mode, a reserved instruction exception is generated.
Load Doubleword
LD ry, offset (sp)
The 5-bit immediate is shifted left three bits, zero extended to 64 bits, and added to the contents of
general register sp to form the virtual address. The 64-bit doubleword at the memory location specified
by the address is loaded to general register ry.
If any of the three lower bits of the address is not 0, an address error exception is generated.
This operation is defined in the 64-bit mode and the 32-bit kernel mode. When this instruction is
executed in the 32-bit user/supervisor mode, a reserved instruction exception is generated.
Store Byte
SB ry, offset (rx)
The 5-bit immediate is zero extended and then added to the contents of general register rx to form the
virtual address. The least significant byte of general register ry is stored to the memory location
specified by the address.
Store Halfword
SH ry, offset (rx)
The 5-bit immediate is shifted left one bit, zero extended, and then added to the contents of general
register rx to form the virtual address. The lower halfword of general register ry is stored to the
memory location specified by the address.
If the least significant bit of the address is not 0, an address error exception is generated.