[ Previous | Next | Contents | Home | Search ]
AIX Version 4.3 Assembler Language Reference

stbx (Store Byte Indexed) Instruction

Purpose

Stores a byte from a general-purpose register into a specified location in memory.

Syntax

stbx RS,RA,RB

Description

The stbx instruction stores bits 24-31 from general-purpose register (GPR) RS into a byte of storage addressed by the effective address (EA). The contents of GPR RS are unchanged.

If GPR RA is not 0, the EA is the sum of the contents of GPR RA and the contents of GPR RB. If GPR RA is 0, then the EA is the contents of GPR RB.

The stbx instruction has one syntax form and does not affect the Fixed-Point Exception Register or Condition Register Field 0.

Parameters

RS Specifies source general-purpose register of stored data.
RA Specifies source general-purpose register for EA calculation.
RB Specifies source general-purpose register for EA calculation.

Examples

The following code stores bits 24-31 of GPR 6 into a location in memory:

.csect data[rw]
buffer: .long 0
# Assume GPR 4 contains the address of buffer.
# Assume GPR 6 contains 0x4865 6C6F.
.csect text[pr]
stbx 6,0,4
# buffer now contains 0x6F.

Related Information

Fixed-Point Processor.

Fixed-Point Load and Store Instructions.


[ Previous | Next | Contents | Home | Search ]