A83: op commands


[Prev][Next][Index][Thread]

A83: op commands




Well...after like 3 years of blandly staring at ASM tutorials, I think I
have found the light!  I would like to thank James Matthews for his
wonderfull, WONDERFULL Asm guru guide!  That thing is soooooo awesome!

I do have a question though....

How can/do I use the romcall _cpop1op2?

What I mean is how exactly does that compare the OP values?  Does it
subtract op2 from op1 or what?  The TI ASM information says:

;  _CPOP1OP2 : COMPARE SIGNED FLOATING POINT OP1 & OP2   |
;                                                        |
;              - OP1 & OP2 ARE KEPT INTACT               |
;                                                        |
;   INPUT : OP1, OP2 = FLOATING POINT #'S                |
;   OUTPUT : CA SET : OP1 < OP2                          |
;            CA NOT SET : OP1 >= OP2                     |
;            ZERO SET : OP1 = OP2                        |
;---------------------------------------------------------

What does CA SET/CA NOT SET mean?  The reason I ask is I need to do a loop
with these Op codes and I get the wrong result if i have:

    call _cpop1op2
    jp nz,loop

While I'm pretty sure Im saying, "Subtract Op2 from Op1.  If the result is
not zero, go to loop."  Am i F.O.S.???

Thanks!

Jake



Follow-Ups: References: