Вы находитесь на странице: 1из 20

Computer Architecture

CS401
Sabanci University erkays@sabanciuniv.edu

5/5/2012

Erkay Savas

Outline
Brief Overview What is under a computer program Components Roadmap for this class

5/5/2012

Erkay Savas

Things You will be Learning


How computers work; the basic foundation How to analyze their performance and how not to Key technologies determining the modern processor performance
Datapath Pipeline Cache Memory Hierarchy I/O Multiprocessors

5/5/2012

Erkay Savas

Below the Software


Abstraction
Delving into the depths reveals more information An abstraction omits unneeded detail, helps us cope with complexity Computers might be very different from what we think they are when we look at it at the hardware level. In fact, they can be communicated only by sending them electrical signals: HIGH/LOW voltage First level of abstraction is to designate these signals as TRUE/FALSE and 1/0 We often think that the true language of the computers is binary numbers
Erkay Savas 4

5/5/2012

Instruction Set Architecture


Important abstraction

Or features available to programmers

interface between hardware and low-level software instructions e.g. does a computer have an multiply instruction? instruction coding number of bits to represent data I/O mechanism. addressing mechanism 80x86/Pentium/K6, PowerPC, DEC Alpha, MIPS, SPARC, HP, ARM.
Erkay Savas 5

Modern instruction set architectures:

5/5/2012

Organization
Organization is how features are implemented in hardware
Transparent to programmers different implementations of the same architecture Control signals, interfaces, memory technology. e.g. Is there a hardware multiply unit or is it done by repeated addition?

5/5/2012

Erkay Savas

How to Program a Computer?


Most natural way is to encode whatever you want to tell the computer to do with electrical signals (on and off) Of course, we need something simpler to work with Machine Code Assembly language High-level languages
C/C++, Pascal, Fortran, Java, C# since this is the only thing it understands

5/5/2012

Erkay Savas

Processing a C Program
High-level language program (in C)
swap (int v[], int k){ int temp; temp = v[k]; v[k] = v[k+1]; v[k+1] = temp; }

Assembly language program for MIPS C compiler


swap: muli add lw lw sw sw jr

$2, $2, $15, $16, $16, $15, $31

$5, 4 $4, $2 0($2) 4($2) 0($2) 4($2)

Binary machine language program for MIPS

0000000010100001000000000001 10000000000010001110000110000 01000011000110001100010000000 00000000001000110011110010000 00000000001001010110011110010 00000000000000001010110001100 01000000000000001000000001111 1000000000000000001000


Erkay Savas

Assembler

5/5/2012

Functions of a Computer
Data processing Data storage Data movement Control

5/5/2012

Erkay Savas

Functions of a Computer
source & destination of data data movements apparatus

Control mechanism Data storage facility


5/5/2012 Erkay Savas

Data processing facility

10

Five Classic Components


Computer Processor
Datapath Memory Input

Control

Output

5/5/2012

Erkay Savas

System Interconnection

11

Motherboard
PS/2 connectors

USB 2.0

Parallel/Serial

Sound

SIMM Sockets PCI Card Slots

Processor

IDE Connectors
Erkay Savas 12

5/5/2012

Inside the Processor Chip


Instruction Cache Control
branch prediction

Data Cache

Bus

integer floating-point datapath datapath

5/5/2012

Erkay Savas

13

Computer
peripherals CPU

I/O

computer

System interconnection
Memory

network

5/5/2012

Erkay Savas

14

CPU

ALU

Registers

CPU

Internal CPU interconnection Cache Memory Control Unit

5/5/2012

Erkay Savas

15

Memory
Nonvolatile:
ROM Hard disk, floppy disk, magnetic tape, CDROM, USB Memory

Volatile
DRAM used usually for main memory SRAM used mainly for on-chip memory such as register and cache DRAM is much less expensive than SRAM SRAM is much faster than DRAM
5/5/2012 Erkay Savas 16

DRAM and Processor Characteristics

5/5/2012

Erkay Savas

17

Solutions to Memory Problems


Increase number of bits retrieved at one time
Make DRAM wider rather than deeper

Change DRAM interface


Cache

Reduce frequency of memory access


More complex cache and cache on chip

Increase interconnection bandwidth


High speed buses Hierarchy of buses
5/5/2012 Erkay Savas 18

Computer Networks
Very essential aspect of computer systems
Communication Resource sharing Remote access

Ethernet is the most popular LAN

Wide Area Networks (WAN)

Range is limited to 1 kilometer 3 Mbit/s to 10 Gbit/s Coaxial cable to twisted pair to optical fiber Cross continents and backbone of the Internet
Erkay Savas 19

5/5/2012

Roadmap
Performance issues Instruction set of MIPS Arithmetic and ALU Constructing a processor to execute our instructions (datapath design) Pipelining Memory hierarchy: caches and virtual memory I/O Multiprocessors
5/5/2012 Erkay Savas 20

Вам также может понравиться