293
Comparison Instructions Section 3-7
Description The input comparison instruction compares S
1
and S
2
as signed or unsigned
values and creates an ON execution condition when the comparison condition
is true. Unlike instructions such as CMP(020) and CMPL(060), the result of an
input comparison instruction is reflected directly as an execution condition, so
it is not necessary to access the result of the comparison through an Arith-
metic Flag and the program is simpler and faster.
Inputting the Instructions
The input comparison instructions are treated just like the LD, AND, and OR
instructions to control the execution of subsequent instructions.
Options
The input comparison instructions can compare signed or unsigned data and
they can compare one-word or double values. If no options are specified, the
Index Registers IR0 to IR15 (for unsigned data only)
Indirect addressing
using Index Registers
,IR0 to ,IR15
–2048 to +2047 ,IR0 to –2048 to +2047 ,IR15
DR0 to DR15, IR0 to IR15
,IR0+(++) to ,IR15+(++)
,–(– –)IR0 to, –(– –)IR15
Area S
1
S
2
Input type Operation
LD The instruction can be connected directly to the left bus bar.
AND The instruction cannot be connected directly to the left bus bar.
OR The instruction can be connected directly to the left bus bar.
<
<
<
LD connection
AND connection
OR connection
ON execution condition when
comparison result is true.
ON execution condition when
comparison result is true.
ON execution condition when
comparison result is true.