Docsity

Computer Architecture –Course Objectives, Study notes of Computer Architecture and Organization

Toggle sidebar
bg1
1
CS 211: Computer Architecture
CS 211: Computer Architecture
Instructor: Prof. Bhagi Narahari
Dept. of Computer Science
Course URL: www.seas.gwu.edu/~narahari/cs211/
CS 211: Computer Architecture, BhagiNarahari
Computer Architecture – Course Objectives
•Examine the role of computer
architecture (CA) in system/program
performance
What are the key components of CA ?
What are the architectures of today’s
processors ?
What aspects of architecture design affect
performance of application and how ?
How to extract max performance out of
today’s CAs ?
Role of software in architecture performance
What are the emerging trends in CA ?
•quantitative approach to CA
CS 211: Computer Architecture, BhagiNarahari
What it is not..
•What the course is not
Detailed exposition on hardware design
Semiconductor technology details
Case studies
How to assemble/buy a new computer
CS 211: Computer Architecture, BhagiNarahari
Perspective
•Computer architecture design is directly
linked to underlying technology
Semiconductor
Compiler technology
Computational models
•Goal of software designers is to run an
application program efficiently on the
architecture
Compiler plays a key role
interplay between architecture features and
application program properties
Bottom line is performance of application
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16

Partial preview of the text

Download Computer Architecture –Course Objectives and more Study notes Computer Architecture and Organization in PDF only on Docsity!

CS 211: Computer ArchitectureCS 211: Computer Architecture

Instructor: Prof. Bhagi Narahari

Dept. of Computer Science Course URL: www.seas.gwu.edu/~narahari/cs211/

CS 211: Computer Architecture, Bhagi Narahari

Computer Architecture – Course Objectives

  • Examine the role of computer

architecture (CA) in system/program

performance

¾ What are the key components of CA? ¾ What are the architectures of today’s processors? ¾ What aspects of architecture design affect performance of application and how? ¾ How to extract max performance out of today’s CAs? ¾ Role of software in architecture performance ¾ What are the emerging trends in CA?

  • quantitative approach to CA

CS 211: Computer Architecture, Bhagi Narahari

What it is not..

  • What the course is not ¾ Detailed exposition on hardware design ¾ Semiconductor technology details ¾ Case studies ¾ How to assemble/buy a new computer

CS 211: Computer Architecture, Bhagi Narahari

Perspective

  • Computer architecture design is directly

linked to underlying technology

¾ Semiconductor ¾ Compiler technology ¾ Computational models

  • Goal of software designers is to run an

application program efficiently on the

architecture

¾ Compiler plays a key role ¾ interplay between architecture features and application program properties ¾ Bottom line is performance of application

CS 211: Computer Architecture, Bhagi Narahari

Let’s look at Architecture Trends,

Technologies

  • Interplay between hardware and software
  • Implications of technology trends on

emerging architecture designs

CS 211: Computer Architecture, Bhagi Narahari

Today

  • What is Computer Architecture ¾ Architecture levels and our focus
  • Technology Trends ¾ Summary of what has happened in CA ¾ Hardware performance trends and designs ¾ Impact of current trends on new designs
  • Performance models ¾ What to measure and how ¾ Models linking hardware and software ¾ Thumb rules for CA design
  • Read Chapter 1

CS 211: Computer Architecture, Bhagi Narahari

An Important Idea: what are Computers meant to do?

  • We will be solving problems that are

describable in English (or Greek or French or

Hindi or Chinese or ...) and using a box filled

with electrons and magnetism to accomplish

the task.

¾ This is accomplished using a system of well defined (sometimes) transformations that have been developed over the last 50+ years. ¾ As a whole the process is complex, examined individually the steps are simple and straightforward

CS 211: Computer Architecture, Bhagi Narahari

Hardware Vs. Software

Hardware

¾Medium to compute functions

Software

¾Functions to compute

Computational Model connects them

CS 211: Computer Architecture, Bhagi Narahari

The Machine Level - 2

  • Logic Circuits

¾Each functional component of the microarchitecture is built up of circuits that make “decisions” based on simple rules ¾ Not the focus of this course – prerequisite material

  • Devices

¾Finally, each logic circuit is actually built of electronic devices such as CMOS or NMOS or GaAs (etc.) transistors. ¾ Device electronics – not in this course CS 211: Computer Architecture, Bhagi Narahari

Alternate Definitions: The Multi-Level Concept

  • Different levels, each with its unique

functionality

¾ Problem-Oriented Language Level (prog languages) ¾ Assembly Language Level ¾ Operating System machine level ¾ Conventional Machine Level (Instruction Set Architecture -- ISA) ¾ Micro-architecture level (Microprogramming level) ¾ Digital Logic Level (program in VHDL, Verilog) ¾ Device & Semiconductor Level

CS 211: Computer Architecture, Bhagi Narahari

For us, Computer Architecture is ...

Instruction Set Architecture

Organization

(MicroArchitecture)

(Logic Circuits)

Hardware

CS 211: Computer Architecture, Bhagi Narahari

Instruction Set Architecture (ISA)

instruction set

software

hardware

CS 211: Computer Architecture, Bhagi Narahari

The hardware/software interface: Instruction Set Architecture (ISA)

instruction set

software

hardware

Which is easier to change/design???

CS 211: Computer Architecture, Bhagi Narahari

The Backdrop: Users

  • Who will program these machines? ¾ Programmers
  • What do they expect? ¾ Performance ¾ Correctness
  • How? ¾ Write HLL program and Compile
  • Compilation is key to performance ¾ Requires Hardware/Software interaction at ISA level ¾ Knowledge of architecture, application, algorithm

CS 211: Computer Architecture, Bhagi Narahari

Architecture: Introduction

  • What is Computer Architecture ¾ Architecture levels and our focus
  • Technology Trends ¾ Summary of what has happened in CA ¾ Hardware performance trends and designs ¾ Impact of current trends on new designs
  • Performance models ¾ What to measure and how ¾ Models linking hardware and software ¾ Thumb rules for CA design

CS 211: Computer Architecture, Bhagi Narahari

Trends In Technology, Applications,Architectures

CS 211: Computer Architecture, Bhagi Narahari

Why Such Change?

  • Performance

¾ Technology Advances- Moore’s Law ¾ CMOS VLSI dominates older technologies (TTL, ECL) in cost AND performance and is progressing rapidly ¾ Computer architecture advances improves low- end ¾ RISC, superscalar, RAID, …

  • Price: Lower costs due to …

¾ Simpler development, volumes, lower margins

  • Function

¾ Rise of networking/local interconnection technology

CS 211: Computer Architecture, Bhagi Narahari

Memory Capacity (Single Chip DRAM)

size

Year

1000

10000

100000

1000000

10000000

100000000

1000000000

1970 1975 1980 1985 1990 1995 2000

year size(Mb) cyc time 1980 0.0625 250 ns 1983 0.25 220 ns 1986 1 190 ns 1989 4 165 ns 1992 16 145 ns 1996 64 120 ns 2000 256 100 ns

CS 211: Computer Architecture, Bhagi Narahari

Technology Trends summary

Capacity Speed (latency)

Logic 2x in 2 years 2x in 3 years DRAM 4x in 3 years 2x in 10 years Disk 4x in 3 years 2x in 10 years

CS 211: Computer Architecture, Bhagi Narahari

Performance Trends: Summary

  • Workstation performance (measured in

Spec Marks) improves roughly 50% per

year

(2X every 18 months)

  • Improvement in cost performance

estimated at 70% per year

CS 211: Computer Architecture, Bhagi Narahari

Emerging trends in Processor Design

  • CISC to RISC ¾ Based on speeding up common instructions ¾ Shall return to this later
  • What’s the trend in Semiconductor

technology and its impact on new types

of processor architectures?

¾ some aspects to consider: ¾ Delay: switching time of transistor – impacts clock cycle ¾ Feature size: size of transistor – impacts amount of logic in processor ¾ Interconnect delay: clock cycle/delay in sending signal across the interconnect lines on a chip

CS 211: Computer Architecture, Bhagi Narahari

0

5

10

15

20

25

30

35

40

650 500 350 250 180 130 100 Feature Size (nm)

Delay (ps)

Gate Delay (ps) Interconnect Delay (ps) Cu & Low k Interconnect Delay (ps) Al & SiO

Delay vs. Feature Size

2000

Bohr, M. T., “Interconnect Scaling - The Real Limiter To High Performance ULSI”, Proceedings of the IEEE International Electron Devices, pages 241-242.

CS 211: Computer Architecture, Bhagi Narahari

As Wire Delays Become Significant...

  • Focus on architectures that

¾ do not involve long distance communication

¾ distribute control and data processing logic

CS 211: Computer Architecture, Bhagi Narahari

Verification And Test

  • With increasing chip complexity,

verification and test costs form a

significant component of the overall cost

  • Long testing process will also affect time to

market

  • Impact of high costs? ¾ Keep architecture simple and regular

CS 211: Computer Architecture, Bhagi Narahari

Sequential Processor

Sequential Instructions

Processor

Execution unit Execution unit

CS 211: Computer Architecture, Bhagi Narahari

Instruction Level Parallelism: Shrinking of the Parallel Processor

  • Put multiple processors into one chip
  • execute multiple instructions in each cycle
  • move from multiple processor architectures

to multiple issue processors

  • Two classes of Instruction Level Parallel

(ILP) processors

¾ Superscalar processors ¾ Explicitly Parallel Instruction Computers (EPIC) ¾ also known as Very Large Ins Word (VLIW)

CS 211: Computer Architecture, Bhagi Narahari

ILP Processors:Superscalar

Sequential Instructions

Superscalar Processor

Scheduling Logic

Scheduling Logic

Instruction scheduling/ parallelism extraction done by hardware

Instruction scheduling/Instruction scheduling/ parallelism extractionextraction done by hardwaredone by hardware

Example: Intel IA-32/Pentium CS 211: Computer Architecture, Bhagi Narahari

Serial Program (C code)

Serial ProgramSerial Program (C code)(C code)^ Scheduled Instructions

EPIC Processor

ILP Processors:EPIC/VLIW

compiler

Example: Intel IA-64; Itanium

CS 211: Computer Architecture, Bhagi Narahari

Multi-Core Processors

Sequential Instructions

Multi-Core Processor

Multi-processing on Chip; Multiple threads – for each core

MultiMulti--processing on Chip;processing on Chip; Multiple threadsMultiple threads –– for each corefor each core

Example: Intel Core 2 Duo

ILP “processor” ILP “processor”

“core 1” “core 2”

CS 211: Computer Architecture, Bhagi Narahari

Frontend and Optimizer

Determine Dependences

Determine Independences

Bind Operations to Function Units

Bind Transports to Busses

Determine Dependences

Bind Transports to Busses

Execute

Superscalar

Dataflow

Indep. Arch.

VLIW

TTA

Compiler Hardware

Determine Independences

Bind Operations to Function Units

B. Ramakrishna Rau and Joseph A. Fisher. Instruction-level parallel: History overview, and perspective. The Journal ofSupercomputing, 7(1-2):9-50, May 1993.

Who is doing what:

Compiler vs. Processor

CS 211: Computer Architecture, Bhagi Narahari

Importance of Compilers in ILPArchitectures

  • Role of compiler more important than

ever

A optimize code A analyze dependencies between instructions A extract parallelism A schedule code onto processors A EPIC processors does not have any hardware utilities for scheduling, conflict resolution etc. Ahas to be done by the compiler

CS 211: Computer Architecture, Bhagi Narahari

Another aspect: Quantifying Power

Consumption

  • What else is an issue in

processor/system design/performance

  • Power consumption/heat dissipation ¾ Limited energy source (battery) in embedded systems (or even laptops) ¾ Apple switch to Intel chips in 2005?

CS 211: Computer Architecture, Bhagi Narahari

What about the embedded processor?

Source: Richard Newton CS 211: Computer Architecture, Bhagi Narahari

Summary: What’s up with Architecture Trends?

  • Moore’s law: density doubles every 18-

months

¾ smaller processors, faster clocks ¾ leads to more powerful and smaller processors! ¾ Small computing platforms like Palmtop computers, Palm, WinCE

  • Trends/Lessons/Limits?

CS 211: Computer Architecture, Bhagi Narahari

  • Old Conventional Wisdom: Power is free, Transistors expensive
  • New Conventional Wisdom: “Power wall” Power expensive, Xtors free (Can put more on chip than can afford to turn on)
  • Old CW: Sufficiently increasing Instruction Level Parallelism via compilers, innovation (Out-of-order, speculation, VLIW, …)
  • New CW: “ILP wall” law of diminishing returns on more HW for ILP
  • Old CW: Multiplies are slow, Memory access is fast
  • New CW: “Memory wall” Memory slow, multiplies fast (200 clock cycles to DRAM memory, 4 clocks for multiply)

Crossroads: Conventional Wisdom in Comp. Arch

CS 211: Computer Architecture, Bhagi Narahari

Conventional Wisdom…

  • Old CW: Uniprocessor performance 2X / 1.5 yrs
  • New CW: Power Wall + ILP Wall + Memory Wall = Brick Wall ¾ Uniprocessor performance now 2X / 5(?) yrs ⇒ Sea change in chip design: multiple “cores” (2X processors per chip / ~ 2 years) ¾ More simpler processors are more power efficient

CS 211: Computer Architecture, Bhagi Narahari

Multi-Core Processors

Sequential Instructions

Multi-Core Processor

Multi-processing on Chip; Multiple threads – for each core

MultiMulti--processing on Chip;processing on Chip; Multiple threadsMultiple threads –– for each corefor each core

Example: Intel Core 2 Duo

ILP “processor” ILP “processor”

“core 1” “core 2”

CS 211: Computer Architecture, Bhagi Narahari

Déjà vu all over again?

  • Multiprocessors imminent in 1970s, ‘80s, ‘90s, …
  • “… today’s processors … are nearing an impasse as technologies approach the speed of light..” David Mitchell, The Transputer: The Time Is Now (1989)
  • Transputer was premature ⇒ Custom multiprocessors strove to lead uniprocessors ⇒ Procrastination rewarded: 2X seq. perf. / 1.5 years
  • “We are dedicating all of our future product development to multicore designs. … This is a sea change in computing” Paul Otellini, President, Intel (2004)
  • Difference is all microprocessor companies switch to multiprocessors (AMD, Intel, IBM, Sun; all new Apples 2 CPUs) ⇒ Procrastination penalized: 2X sequential perf. / 5 yrs ⇒ Biggest programming challenge: 1 to 2 CPUs

CS 211: Computer Architecture, Bhagi Narahari

Problems with Sea Change

  • Algorithms, Programming Languages, Compilers, Operating Systems, Architectures, Libraries, … not ready to supply Thread Level Parallelism or Data Level Parallelism for 1000 CPUs / chip,
  • Architectures not ready for 1000 CPUs / chip
    • Unlike Instruction Level Parallelism, cannot be solved by just by computer architects and compiler writers alone, but also cannot be solved without participation of computer architects

CS 211: Computer Architecture, Bhagi Narahari

Course Information

  • Course materials placed at ¾ www.seas.gwu.edu/~bhagiweb/cs211/ ¾ All lecture notes, homeworks, simulator s/w info, and announcements ¾ Check at least once a week – before class. ¾ Strong pre-requisite: CS135 or equivalent first course in Computer Organization/Systems ¾ Programming skills and basic system skills

CS 211: Computer Architecture, Bhagi Narahari

Architecture: Introduction

  • What is Computer Architecture ¾ Architecture levels and our focus
  • Technology Trends ¾ Summary of what has happened in CA ¾ Hardware performance trends and designs ¾ Impact of current trends on new designs
  • Performance models ¾ What to measure and how ¾ Models linking hardware and software ¾ Thumb rules for CA design

CS 211: Computer Architecture, Bhagi Narahari

Recurring Theme

Performance

  • Calculating & measuring performance
  • Designing & tuning software

CS 211: Computer Architecture, Bhagi Narahari

Performance

  • How do you measure performance? ¾ Throughput ¾ Number of tasks completed per time unit ¾ Response time/latency ¾ time taken to complete the task ¾ metric chosen depends on user community ¾ System admin vs single user submitting homework

CS 211: Computer Architecture, Bhagi Narahari

The Bottom Line: Performance (and Cost)

Plane

Boeing 747

BAD/Sud Concodre

Speed

610 mph

1350 mph

DC to Paris

6.5 hours

3 hours

Passengers

470

132

Performance?

CS 211: Computer Architecture, Bhagi Narahari

The Bottom Line: Performance (and Cost)

  • Time to run the task (Execution Time/Response Time/Latency)
    • Time to travel from DC to Paris
  • Tasks per unit time (Throughput/Bandwidth)
    • Passenger miles per hour; how many passengers transported per unit time

Plane

Boeing 747

BAD/Sud Concodre

Speed

610 mph

1350 mph

DC to Paris

6.5 hours

3 hours

Passengers

470

132

Throughput (pmph)

286,

178,

CS 211: Computer Architecture, Bhagi Narahari

The Bottom Line: Performance (and Cost)

"X is n times faster than Y" means

ExTime(Y) Performance(X) --------- = --------------- ExTime(X) Performance(Y)

  • Speed of Concorde vs. Boeing 747
  • Throughput of Boeing 747 vs. Concorde

CS 211: Computer Architecture, Bhagi Narahari

How to Model Performance

  • What are we trying to model? ¾ Time taken to run an application program
  • Why not just use “time” function in

Unix?

CS 211: Computer Architecture, Bhagi Narahari

Aspects of CPU Performance

CPU time = Seconds = Instructions x Cycles x Seconds Program Program Instruction Cycle

CPU time = Seconds = Instructions x Cycles x Seconds Program Program Instruction Cycle

CPU = IC * CPI * Clk

Holy grail of CS 211 ☺

CS 211: Computer Architecture, Bhagi Narahari

Measure performance of what applications?

  • CPU A versus CPU B ¾ How to compare?

CS 211: Computer Architecture, Bhagi Narahari

Performance Evaluation

  • “For better or worse, benchmarks shape a field”
  • Good products created when have: ¾ Good benchmarks ¾ Good ways to summarize performance
  • Execution time is the measure of computer performance!

CS 211: Computer Architecture, Bhagi Narahari

SPEC: System Performance Evaluation Cooperative

  • First Round 1989 ¾ 10 programs yielding a single number (“SPECmarks”)
  • Second Round 1992 ¾ SPECInt92 (6 int. programs) and SPECfp92 (14 flt pt.)
  • Third Round 1995 ¾ SPECint95 (8 int programs) and SPECfp95 (10 flt pt)
  • Fourth Round 2000: SPEC CPU ¾ 12 Integer, 14 Floating point ¾ 2 choices on compilation; “aggressive” or “conservative” ¾ multiple data sets so that can train compiler if trying to collect data for input to compiler to improve optimization
  • Why SPEC: characterization of wide spectrum of use

CS 211: Computer Architecture, Bhagi Narahari

What other benchmarks?

  • What if you are targeting the design for

an application domain

  • Some domains have well-

defined/accepted benchmarks

¾ Media Bench– for multimedia apps ¾ Data Intensive Sys. (DIS) – for embedded systems that process input data ¾ MI Bench – for embedded systems ¾ TPC- transaction processing benchmarks to measure trans. proc. systems

CS 211: Computer Architecture, Bhagi Narahari

How to Summarize Performance

  • Arithmetic mean (weighted arithmetic mean) tracks execution time: Σ(Ti)/n or Σ(W (^) i*Ti)
  • Harmonic mean (weighted harmonic mean) of rates (e.g., MFLOPS) tracks execution time: n/Σ(1/R (^) i) or n/Σ(W (^) i/R (^) i)
  • Normalized execution time is handy for scaling performance (e.g., X times faster than SPARCstation 10)

CS 211: Computer Architecture, Bhagi Narahari

Performance

  • How do you measure performance? ¾ Throughput, Response time/latency ¾ metric chosen depends on user community ¾ System admin vs single user submitting homework
  • Models for performance ¾ CPU time equation
  • What to measure ¾ Benchmarks- SPEC, MIBench, etc.
  • Next: How to improve performance –

thumb rules

CS 211: Computer Architecture, Bhagi Narahari

Performance: The AAA rule for designers

  • Application
  • Algorithm
  • Architecture

CS 211: Computer Architecture, Bhagi Narahari

Quantitative Principles of Computer Architecture Design ( Thumb Rules)

  • Performance equation
  • Common case fast ¾ Focus on improving those instructions that are frequently used
  • Amdahl’s Law ¾ Fraction enhanced/optimized runs faster ¾ Parts of program that cannot be enhanced
  • Locality ¾ Spatial ¾ Temporal
  • Concurrency/Parallelism – overlap

instruction execution