Instruction Set 9-177
subfc
Subtract From Carrying
subfc
Subtract From Carrying
(RT) ←¬(RA) + (RB) + 1
if
¬(RA) + (RB) + 1 2
32
– 1 then
XER[CA]
← 1
else
XER[CA]
← 0
The sum of the ones complement of register RA, register RB, and 1 is stored into register RT.
XER[CA] is set to a value determined by the unsigned magnitude of the result of the subtract
operation.
Registers Altered
•RT
• XER[CA]
• CR[CR0]
LT, GT, EQ, SO
if Rc contains 1
• XER[SO, OV] if OE contains 1
Architecture Note
This instruction is part of the PowerPC User Instruction Set Architecture.
subfc RT, RA, RB OE=0, Rc=0
subfc. RT, RA, RB OE=0, Rc=1
subfco RT, RA, RB OE=1, Rc=0
subfco. RT, RA, RB OE=1, Rc=1
31 RT RA RB OE 8 Rc
0 6 11 16 21 22 31
Table 9-31. Extended Mnemonics for subfc, subfc., subfco, subfco.
Mnemonic Operands Function
Other Registers
Altered
subc RT, RA, RB Subtract (RB) from (RA).
(RT)
←¬(RB) + (RA) + 1.
Place carry-out in XER[CA].
Extended mnemonic for
subfc RT,RB,RA
subc.
Extended mnemonic for
subfc. RT,RB,RA
CR[CR0]
subco
Extended mnemonic for
subfco RT,RB,RA
XER[SO, OV]
subco.
Extended mnemonic for
subfco. RT,RB,RA
CR[CR0]
XER[SO, OV]
>
u