According to this website, under the "major uses" for CLC, it states:
If there are to be a series of additions (multiple-byte addition), only the first
ADCis preceded byCLCsince the carry feature is necessary.
Under the "major uses" for SBC it states:
You always
SEC(set the carry flag) before anSBCoperation so you can tell if you need a "borrow".
In other words for a series of consecutive ADC operations, you only need a CLC before the first, but before a series of consecutive SBC operations, you should have a SEC before each. Is this correct?
This is written kind of misleadingly. If you are using a series of ADC to implement multiple-precision addition, e.g. adding two 16-bit or 32-bit numbers, then you do want
CLCbefore the first one only. But if you have several consecutive ADC that are adding unrelated 8-bit numbers, then you want a CLC before each of them. Otherwise, a carry from one addition would be propagated into an unrelated sum.Then the case for SBC is exactly analogous. If you are doing several unrelated 8-bit subtractions, you want to SEC before each one. If you are using a series of SBC to implement 16-bit or 32-bit subtraction, etc, then you want SEC before the first one only.