TSK3000A - Comparison Instructions

Frozen Content

These instructions compare two registers and, based on the result, set a third register to either true or false (1 or 0).

Table 1. Comparison Instructions.
         Mnemonic         
Instruction
Description

SLT rC, rA, rB

Set On Less Than

Compares the contents of GPRs rB and rA as 32-bit signed integers. If rA is less than rB, a '1' is placed into GPR rC, otherwise GPR rC is loaded with '0'

SLTI rB, rA, IMM16

Set On Less Than Immediate

Sign-extends the 16-bit immediate value, IMM16 and compares the result with the contents of GPR rA, treating both values as 32-bit signed integers. If rA is less than the sign extended IMM16 value, a '1' is placed into GPR rB, otherwise GPR rB is loaded with '0'

SLTIU rB, rA, IMM16

Set On Less Than Immediate Unsigned

Sign-extends the 16-bit immediate value, IMM16 and compares the result with the contents of GPR rA, treating both values as 32-bit unsigned integers. If rA is less than the sign extended IMM16 value, a '1' is placed into GPR rB, otherwise GPR rB is loaded with '0'

SLTU rC, rA, rB

Set On Less Than Unsigned

Compares the contents of GPRs rB and rA as 32-bit unsigned integers. If rA is less than rB, a '1' is placed into GPR rC, otherwise GPR rC is loaded with '0'

You are reporting an issue with the following selected text and/or image within the active document: