4.4.9 Count Trailing Zero
Format:
CTTZ | Rb.rq,Rc.wq | ! Operate format |
Operation:
temp = 0
FOR i FROM 0 TO 63
IF { Rbv<i> EQ 1 } THEN BREAK temp = temp + 1
END
Rc<6:0> ← temp<6:0> Rc<63:7> ← 0
Exceptions:
None
Instruction mnemonics:
CTTZ | Count Trailing Zero |
Qualifiers:
None
Description:
The number of trailing zeros in Rb, starting at the least significant bit position, is written to Rc. Ra must be R31.
Instruction Descriptions