Assembly Language Help (alang.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
CMPXCHG Instruction
 Detail Key                               Up Contents Index Back
────────────────────────────────────────────────────────────────────────────
 
  Title:    Compare and Exchange                  Flags: O D I T S Z A P C
            80486 Only                                   ═════════════════
                                                         ±       ± ± ± ± ±
  Syntax:   CMPXCHG dest,src
 
  See also: .486, CMP, XCHG
 
  Description:
 
     Compares the destination operand to the accumulator (AL, AX, or
     EAX). If equal, the source operand is copied to the destination.
     Otherwise, the destination is copied to the accumulator. The
     instruction sets flags according to the result of the comparison.
                                    -♦-