A - 108
DSP96002 USER’S MANUAL
MOTOROLA
FCMPG
Graphics Compare
FCMPG
with Trivial Accept/Reject Flags
Operation:
S2 - S1 (parallel data bus move)
Assembler Syntax:
FCMPG S1,S2 (move syntax - see the MOVE in-
struction description.)
Description:
Subtract the two operands as specified in the operation column above. No result is stored; however, the
condition codes are affected as described. This instruction differs from FSUB when S1=S2; in this case,
the result is 0 and therefore, N is cleared. Note that this is true even if S1, S2 are infinity.
FCMPG and FCMP differ primarily in the definition of the CCR condition code bits LR and R. These differ-
ences are particularly useful in performing clipping operations in graphics applications. In the code seg-
ment, the FCMP instruction tests the first point of a line, X0, against X
min
and sets LR accordingly; the FC-
MPG instruction tests the second point of a line, X1, against X
min
and sets
–
R depending on the condition
of LR. Note that the line segment will be trivially accepted if A is set (and R=1), whereas the line will be
trivially rejected if
–
R is cleared (and A=0). This choice of accept/reject conditions was selected to permit
the CCR to be initialized by a single ORI instruction.
ORI
#$E0,CCR
;SET A,
–
R, LR – i. e.,
;assume line is initially
;accepted and not rejected.
MOVE
X:(R0)+N0,D0.S
Y:(R4)+,D1.S
;get X0, X
min
FCMP
D1, D0
X:(R0)-N0, D0.S
;X0-X
min
, get X1
FCMPG
D1, D0
;X1=X
min
Input Operand(s) Precision: SEP Floating-Point.
Output Operand Precision: n.a.
Summary of Contents for DSP96002
Page 3: ...1 2 DSP96002 USER S MANUAL MOTOROLA ...
Page 38: ...MOTOROLA DSP96002 USER S MANUAL 3 15 Figure 3 4 Modulo Arithmetic Unit Block Diagram ...
Page 39: ...3 16 DSP96002 USER S MANUAL MOTOROLA ...
Page 53: ...4 14 DSP96002 USER S MANUAL MOTOROLA ...
Page 76: ...MOTOROLA DSP96002 USER S MANUAL 5 23 Figure 5 8 Address Modifier Summary ...
Page 86: ...6 10 DSP96002 USER S MANUAL MOTOROLA ...
Page 101: ...MOTOROLA DSP96002 USER S MANUAL 7 15 Figure 7 9 HI Block Diagram One Port ...
Page 140: ...7 54 DSP96002 USER S MANUAL MOTOROLA ...
Page 166: ...9 10 DSP96002 USER S MANUAL MOTOROLA ...
Page 181: ...MOTOROLA DSP96002 USER S MANUAL 10 15 Figure 10 8 Program Address Bus FIFO ...
Page 337: ...MOTOROLA DSP96002 USER S MANUAL A 149 ...
Page 404: ...A 216 DSP96002 USER S MANUAL MOTOROLA PC xxxx D ...
Page 460: ...A 272 DSP96002 USER S MANUAL MOTOROLA SIOP Not affected ...
Page 484: ...A 296 DSP96002 USER S MANUAL MOTOROLA SSH PC SSL SR SP 1 SP ...
Page 519: ...MOTOROLA DSP96002 USER S MANUAL A 331 ...
Page 718: ...MOTOROLA DSP96002 USER S MANUAL B 199 ...
Page 871: ... MOTOROLA INC 1994 MOTOROLA TECHNICAL DATA SEMICONDUCTOR M Addendum ...
Page 888: ...MOTOROLA INDEX 1 INDEX ...
Page 889: ......