Arithmetic and Logic Unit
Arithmetic and Logic Unit
UNIT
RASHED OBAID
BRIXENDOR HERNANDEZ
BSIT 2
ARITHMETIC LOGIC UNIT
• Subtract
• Multiply
• OR
• XOR
• NOT
• L- Shift
• R- Shift
BASIC COMPONENTS
• A transistor is a binary switch and the
fundamental building block of computer
circuitry. Like a light switch on the wall, the
transistor either prevents or allows current to
flow through.
FLOATING POINT OPERATIONS
• F add
• F sub
• F Mul
• F Div
FUNCTIONS
• 3 types of functions-
Arithmetic operations
Bitwise Logical Operations
Bit Shift operations
A 1-BIT ALU
• The logical operations are easiest, because they map directly onto the hardware
components.
• The 1-bit logical unit for AND and OR looks like figure below. The multiplexor on
the right then selects a AND b or a OR b, depending on whether the value of
Operation is 0 or 1. The line that controls the multiplexor is shown in color to
distinguish it from the lines containing data. In the figure below control and output
lines of the multiplexor were renamed to names that reflect the function of the ALU.
A 32-BIT ALU
• 32-bit ALU is created by connecting adjacent “black boxes”. Using xi to mean the each bit of x, blow
shows a 32-bit ALU. The adder created by directly linking the carries of 1-bit adders is called a ripple
carry adder.
NUMERICAL SYSTEMS
• An ALU must process numbers using the same format as the rest of the digital
circuit. For modern processors, that almost always is the two’s complement binary
number representation. Early computers used a wide variety of number systems,
including one’s complement, sign-magnitude format, and even true decimal
systems, with ten tubes per digit.
• ALUs for each one of these numeric systems had different designs, and that
influenced the current preference for two’s complement, as this is the representation
that makes it easier for the ALUs to calculate additions and subtractions.
PRACTICAL OVERVIEW