Advertisements
ALU - Arithmetic and logic unit
- It has hardware circuits that performs arithmetic & logical operation
- H/w section are
- Adder
- Accumulator
- General purpose register (GPR)
- Counters
- Shifters
- Complementer
Adder ->
Circuit which adds 2 numbers & gives result
Accumulator ->
Register that temporarily holds results of previous operation in ALU
General Purpose Register (GPR)
-
Operand in CPU – immediately available
-
GPR stores
- operand
- operand address(all used for multiple purposes)
- constant
Scratch Pad Memory or Registers:
-
To store intermediate results temp
-
There are usually one or more scratch pad registers
-
Purely internal h/w resources
-
Not addressable by program
Shifter & complementer
-
provides left shift & right shift required for various arithmetic operation
-
complementer provides 2’s complement of binary numbers
Positive & negative no.s
ALU Size:
-
Performance of computer is dependent on ALU Size
-
Need not be same as memory word length
-
In original IBM PC< 16 bit , ALU whereas memory word length is 8 bit