Arithmetic Logic Shift Unit (original) (raw)

Last Updated : 13 Oct, 2025

An Arithmetic Logic Shift Unit (ALSU) is an enhanced version of the Arithmetic Logic Unit (ALU) used in computer systems. It is a combinational digital circuit capable of performing arithmetic, logic, and shift micro-operations on binary data, and is a core part of the CPU datapath.

**Basic Working of ALSU

Rather than having registers perform micro-operations independently, the system routes their data to a central ALSU via a common bus. The operation is completed in a single clock pulse, and the result is stored in a destination register.

**ALSU Functional Units

An ALSU integrates three primary sub-units: the arithmetic unit, the logic unit, and the shift unit. These sub-units work in parallel, and a multiplexer selects the final output based on control signals.

One stage of ALSU

**Control Signals and Operation Selection

Operations within the ALSU are selected using five control inputs: S3 S2 S1 S0 (4-bit opcode) and Cin (carry-in). The result from the arithmetic, logic, or shift unit is chosen via a 4×1 multiplexer based on these control signals.

**Shift Operation Handling in ALSU

Shift operations are treated as special cases within ALSU and utilize neighboring bit values for computation. For left shift (SHL), the value of the next lower bit is used; for right shift (SHR), the next higher bit is used.

**Operation Mapping in ALSU

The ALSU is designed to perform 14 distinct operations using the control signals S3 S2 S1 S0 and Cin. These are logically grouped into arithmetic, logic, and shift operations.

Function table of ALSU