One of the components that has not been addressed yet is the alu. Most of the instructions require some form of mathematical operation between two values. At this point we can combine the operation needed to define what capabilities the alu must have. In the 6502 Cpu, the basic operations are Add, Subtract, XOr, And, Decrement, Increment, Shift Left/Right, and Through (No op).
The connectivity through the datapath, how the register input and outputs are connected to each other and the alu, is slightly more complicated. The separate instruction timing diagrams which were sketched out in Section 4 above did not take into account how the other instructions might be using the same hardware like the alu. The main difficulty in the datapath design is the trying to minimize the connectivity and muxing necessary to perform all the operations.
In developing the 6502 CPU, many different attempts where drafted and improved upon. Most of the time was spent in determining which side of the alu inputs should the different registers be on. Largely this was determined by the instructions which required usage of both inputs of the alu (and add instruction for example) however the optimal connectivity becomes a lot more complex when we begin to consider the different addressing modes.