Input registers for the 6502's ALU?
Posted: Thu Jan 15, 2015 6:55 pm
Hi everyone, I'm back to trying to figure out the internal structure of the 6502 chip, and I thought I'd ask a question about how data gets to the ALU. Does anyone know if the ALU has input registers or not? When looking at Hanson's block diagram, there are clearly two items labeled "A input register (AI)" and "B input register (BI)" that feed into the ALU. However, when I check the Balazs transistor-level schematic, I don't see anything that resembles a register going into the ALU; it seems like the ALU gets its inputs directly from the internal buses.
I've been trying to figure out how you even WOULD make a register which can receive data from two buses at once. Hanson's block diagram shows that the B input register can store the contents of either the data bus (DB) or the low address bus (ADL). This is simple enough to do with tri-state buffers if the two buses just go directly to the ALU (well, directly through a tri-state buffer), but I actually don't know of any type of register chip that can make use of multiple input lines for each bit. Is there any type of D flip-flop (which is basically what a register is made of) that could actually be made to selectively take its data from multiple inputs? Normally when trying to do something like this, you'd use a multiplexer, but I don't see anything resembling a multiplexer anywhere in the inputs to the ALU, and I doubt that that's what the 6502 actually uses. Can anyone shed some light on this? Thanks!
I've been trying to figure out how you even WOULD make a register which can receive data from two buses at once. Hanson's block diagram shows that the B input register can store the contents of either the data bus (DB) or the low address bus (ADL). This is simple enough to do with tri-state buffers if the two buses just go directly to the ALU (well, directly through a tri-state buffer), but I actually don't know of any type of register chip that can make use of multiple input lines for each bit. Is there any type of D flip-flop (which is basically what a register is made of) that could actually be made to selectively take its data from multiple inputs? Normally when trying to do something like this, you'd use a multiplexer, but I don't see anything resembling a multiplexer anywhere in the inputs to the ALU, and I doubt that that's what the 6502 actually uses. Can anyone shed some light on this? Thanks!