cmpX b,a computes a-b without assigning result to destination.

CF is set if carry out from MSB is 1

ZF set if a == b

SF set if (a-b)<0 (as signed)

OF set if two's-complement overflow

OR testX b, a computes a&b without assigning result to destination (useful for determining whether an operand is negative, zero, or positive)

ZF set when a&b == 0

SF set when a&b < 0

OF & CF not set