Exercise 1: Why LC-3 Never Needed Carry But the 6502 Does — Possible Solution ==================================================================== THE KEY DIFFERENCE: REGISTER WIDTH VS. WORD SIZE ------------------------------ Per this chapter's own explanation, the 6502 is genuinely an 8-bit CPU -- its registers and internal data paths only ever handle one byte (a value from 0-255) at a time. LC-3, by contrast, used full 16-bit registers that exactly matched its own 16-bit word size (per assembly1-4). WHY THIS MATTERS FOR ARITHMETIC ------------------------------ On LC-3, a register can hold any value the architecture considers a single, complete number -- there was never a situation where a value "didn't fit" in one register during ordinary arithmetic, because the register width and the architecture's own natural number size were the same thing. Adding two registers together on LC-3 just produces another value that fits in a register, full stop. On the 6502, a single register can only hold a number up to 255. Any value larger than that -- which is extremely common in real programs, since most useful numbers exceed 255 -- has to be represented across MULTIPLE bytes (this chapter's own example splits a number into NUM1_LOW and NUM1_HIGH). Adding two such multi-byte numbers means adding their low bytes first, and then adding their high bytes -- but the high-byte addition needs to know whether the low-byte addition "overflowed" past 255 and needs to add one extra to the high byte to stay correct. That overflow signal is exactly what the Carry flag communicates from one ADC instruction to the next. WHY LC-3 SIMPLY NEVER HAD THIS PROBLEM ------------------------------ Because LC-3's registers were always exactly as wide as the numbers it worked with, there was never a "the low part overflowed into the high part" situation to signal in the first place -- there was no "low part" and "high part" to begin with. A Carry flag would have had nothing to communicate. WHY THIS WORKS AS AN ANSWER ------------------------------ It identifies the specific mechanical reason (8-bit registers forcing multi-byte numbers to be split across bytes) rather than a vague "the 6502 is more complex" answer, and explains precisely what information Carry carries between the two additions in this chapter's own multi-byte example.