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

si. (Subtract Immediate and Record) Instruction


Subtracts the value of a signed integer from the contents of a general-purpose register and places the result in a second general-purpose register.




The si. instruction subtracts the 16-bit signed integer specified by the SINT parameter from the contents of general-purpose register (GPR) RA and stores the result into the target GPR RT. This instruction has the same effect as the ai. instruction used with a negative SINT. The assembler negates SINT and places this value (SI) in the machine instruction:


The si. instruction has one syntax form and can set the Carry Bit of the Fixed-Point Exception Register. This instruction also affects the Less Than (LT) zero, Greater Than (GT) zero, Equal To (EQ) zero, or Summary Overflow (SO) bit in Condition Register Field 0.


RT Specifies target general-purpose register for operation.
RA Specifies source general-purpose register for operation.
SINT Specifies 16-bit signed integer for operation.
SI Specifies the negative of the SINT value.


The following code subtracts 0xFFFF F800 from the contents of GPR 4, stores the result in GPR 6, and sets the Carry bit in the Fixed-Point Exception Register and Condition Register Field 0 to reflect the result of the operation:

# Assume GPR 4 contains 0xEFFF FFFF.
si. 6,4,0xFFFFF800
# GPR 6 now contains 0xF000 07FF.
# This instruction has the same effect as
#     ai. 6,4,-0xFFFFF800.

Related Information

The addic. or ai. (Add Immediate Carrying and Record) instruction.

Fixed-Point Processor.

Fixed-Point Arithmetic Instructions.

[ Previous | Next | Contents | Home | Search ]