0% found this document useful (0 votes)
74 views14 pages

Cpu - Memory (Disk Drives, DRAM, SRAM, CD) - Input (Mouse, Keyboard) - Output (Display, Printer) - Network - Software

The document discusses computer architecture and its components. It can be summarized as: 1) Computer architecture includes the instruction set architecture and machine organization. 2) The instruction set architecture defines the data types, instructions, and addressing modes that software uses to control the hardware. 3) The machine organization describes how the basic functional units like the ALU and registers are interconnected and how information flows between them.

Uploaded by

anand_duraiswamy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
74 views14 pages

Cpu - Memory (Disk Drives, DRAM, SRAM, CD) - Input (Mouse, Keyboard) - Output (Display, Printer) - Network - Software

The document discusses computer architecture and its components. It can be summarized as: 1) Computer architecture includes the instruction set architecture and machine organization. 2) The instruction set architecture defines the data types, instructions, and addressing modes that software uses to control the hardware. 3) The machine organization describes how the basic functional units like the ALU and registers are interconnected and how information flows between them.

Uploaded by

anand_duraiswamy
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

• CPU

• memory (disk drives, DRAM, SRAM, CD)


• input (mouse, keyboard)
• output (display, printer)
• network
• software

We need abstraction ...


Software:
Application
Operating system
Firmware

Instruction set architecture:


Data type and structures: encodings and machine representation
Instruction set
Instruction formats
Addressing modes and accessing data and instructions

Hardware:
Instruction set processing
I/O System
Digital design
Circuit design
Layout
Computer Architecture =
Instruction Set Architecture +
Machine Organization
Instruction Set Architecture
• Organization of Programmable Storage
• Data type and Structures: encodings and machine representation
• Instruction set
• Instruction Formats
• Addressing Modes and Accessing Data and Instructions
• Exception Handling

Computer Organization

• Capabilities and Performance of the Basic Functional Units


• The Way These Units are Interconnected
• Information Flow between components
• Information Flow Control
software

instruction set

hardware
What is “Computer Architecture”?
Application
Operating
System
Compiler Firmware
Instruction Set
Architecture
Instr. Set Proc. I/O system
Datapath & Control
Digital Design
Circuit Design
Layout
Data

Register #
PC Address Instruction Registers ALU Address
Register #
Instruction
memory Data
Register # memory

Data
Software level

C:
•A=B+C

Assembler
• B -> $s1, C -> $s2
• add $t0, $s1, $s2
• $t0 -> A

Machine instruction:
op rs rt rd … funct
• decimal: 0 17 18 8 0 32
• binary: 000000 10001 10010 01000 00000 100000
0
M
u
x
ALU
Add result 1
Add Shift PCSrc
RegDst left 2
4 Branch
MemRead
Instruction [31 26] MemtoReg
Control
ALUOp
MemWrite
ALUSrc
RegWrite

Instruction [25 21] Read


PC Read register 1
address Read
Instruction [20 16] data 1
Read
register 2 Zero
Instruction 0 Registers Read ALU ALU
[31– 0] 0 Read
M Write data 2 result Address 1
Instruction u register M data
u M
memory Instruction [15 11] x u
1 Write x Data
data x
1 memory 0
Write
data
16 32
Instruction [15 0] Sign
extend ALU
control

Instruction [5 0]
Register file and ALU

ALU operation
Read 3
register 1 Read
Read data 1
register 2 Zero
Instruction
Registers ALU ALU
Write result
register
Read
Write data 2
data

RegWrite
Inside register file

Write
Read register
number 1
C
Register 0 0
Register 0
Register 1 1 D
M
u Read data 1 n-to-1 C
x Register number
Register n – 1 decoder Register 1
Register n D
n– 1
Read register n
number 2

C
M Register n – 1
u Read data 2 D
x
C
Register n
Register data D
Arithmetic Logic Unit (ALU)
CarryIn Operation

a0 CarryIn
Result0
ALU operation b0
ALU0
CarryOut Operation
CarryIn
a
a1 CarryIn
a
Zero ALU1
Result1 0
b1
ALU Result CarryOut
Overflow 1
Result

b a2 CarryIn
Result2 2
ALU2
b2 b
CarryOut
CarryOut
CarryOut

a31 CarryIn
Result31
ALU31
b31
ALU: Carry Out logic

CarryOut = b.CarryIn + a.CarryIn + a.b + a.b.CarryIn

CarryIn or

CarryOut = b.CarryIn + a.CarryIn + a.b


a

Sum
CarryIn
b

a
CarryOut

CarryOut
Logic gates
1. AND gate (c = a . b) a b c=a.b
0 0 0
a
c 0 1 0
b
1 0 0
1 1 1

2. OR gate (c = a + b) a b c=a+b
0 0 0
a
c 0 1 1
b
1 0 1
1 1 1

3. Inverter (c = a) a c=a
a c 0 1
1 0

4. Multiplexor d d c
(if d = = 0, c = a;
else c = b) 0 a
a 0 1 b
c
b 1

You might also like