Jump to navigation Jump to search
- The instruction is used to scan a string (SCAS = SCan A String). It compares the content of the accumulator ( , , or ) against the current value pointed at by .
- When used together with the prefix (REPeat while Not Equal), scans the string searching for the first string element which is equal to the value in the accumulator.
The instructionsearches the memory for the byte in , starting at :
- Compare a byte of memory with the AL register
- Increments EDI by 1 after each byte comparison
- Decreases ECX by 1 after each byte comparison
ZF = AL == BYTE PTR[EDI]