Skip to topic | Skip to bottom
Bennington College
r1.4 - 27 Nov 2005 - 15:54 - JoeHolt

Start of topic | Skip to actions
Information regarding the aritmetical logic unit for use in the Logic Machine 3000 microprocessor.

ArithmeticLogicUnit.jpg

As Joe said "Math operations are performed in three steps. 1. Load the first operand into the ALU, 2. Load the second operand into the ALU, 3. Perform the operation (indicating the destination register)."

The ALU I have built grabs any/all eight bit numbers off of the data bus, but only when the instruction decoder tells it to does it it load whatever number is on the bus into one of the 74374s (either A or B, also determined by the instruction decoder). The number in B is then run through an XOR with the second input to the XOR being determined by the instruction decoder (high for subtraction and low for addition (I think)). The result here is that if the instruction decoder tells the ALU to subtract the XORs negate the numbers coming through them and add 1, which is how we subtract numbers, and if the instruction decoder tells the ALU to add the XORs pass the numbers through unchanged. The number coming out of B is then added to the number from A and the result (the sum) is then run into the 74244, which only allows the resulting sum back onto the data bus when the instruction decoder tells it to.

In the diagram, the red arrows represent data (8-bit numbers) flowing through the ALU. The blue arrows represent the instruction decoder telling the different components to do whatever it is they need to do (load number into A or B, add or subtract, and send the sum back onto the data bus). The green arrow represents the sum that is sent back onto the data bus.

(Joe copied the notes from the ALU notes attachment and pasted them right here.)

I Attachment sort Action Size Date Who Comment
ArithmeticLogicUnit.pdf manage 37.3 K 25 Nov 2005 - 18:53 EbenPackwood My first ALU design.
ALUnotes.rtf manage 1.8 K 27 Nov 2005 - 12:23 EbenPackwood Some notes to accompany the diagram
ArithmeticLogicUnit.jpg manage 55.3 K 27 Nov 2005 - 15:52 JoeHolt