DAA Decimal Adjust after Addition Flags: O D I T S Z A P C ? - - - * * * * * DAA
Logic if ((AL AND 0Fh) > 9) OR (AF = 1) AL ← AL + 6 AF ← 1 else AF ← 0 endif if (AL > 9Fh) OR (CF = 1) AL ← AL + 60h CF ← 1 else CF ← 0 endif
Execute DAA after executing an ADD or ADC instruction on two packed BCD operands. The addition leaves a two-digit byte result in the AL register. The DAA instruction adjusts AL to contain the correct two-digit packed decimal result.