Comment 6 for bug 579320

Revision history for this message
Debjit Biswas (debjitbis08) wrote :

Hi Aanjhan,

Although there is no result, the flags should be checked and set/unset. The intel 8080 manual (i don't have a reference to 8085 at present) says that the CMP instruction affects the following flags: C, Z, S, P and AC.

From what I know, internally a subtraction is performed but without changing either of the operands. It is only logical to do the same thing here, perform a subtraction set/unset flags based on the result but do not save the result.

Thanks,
Debjit