72
Lund University / EITF20/ Liang Liu EITF20: Computer Architecture Part1.1.1: Introduction Liang Liu [email protected] 1

EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

  • Upload
    hadat

  • View
    235

  • Download
    0

Embed Size (px)

Citation preview

Page 1: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

EITF20: Computer ArchitecturePart1.1.1: Introduction

Liang Liu

[email protected]

1

Page 2: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Course Factor

Computer Architecture (7.5HP)

http://www.eit.lth.se/kurs/eitf20

2

Page 3: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Q1: How to upgrade with limited budget

3

Page 4: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Q2: More cores or higher frequency

4

Page 5: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Q3: Why not Intel for iphone?

5

Page 6: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

6

Page 7: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Computer is everywhere

7

Page 8: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Build a Computer…

8

Power Consumption: 65 to 250 watts

Page 9: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Build a Computer…

9

Power: 230 mA (1.2W)

Page 10: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Build a Computer…

10

$ 2.98Power: 65 uA/MHz (32kHz-30MHz)

Page 11: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Build a Computer…

11

Power: 80 Megawatts

Page 12: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Class of Computers

12

Page 13: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Intel v.s. ARM

13

Page 14: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

20

Page 15: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu21

The ART of designing computers is

based on engineering principles

and

quantitative performance evaluation

Page 16: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Computer abstraction levels

22

Page 17: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

ISA: Instruction-set architecture

Computer orginization: micro architecture

Specific implementation

Computer architecture

23

Computer architecture is a set of disciplines that

describe the functionality, organization and

implementation of computer systems.

Page 18: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Computer architecture

24

Design and analysis

• ISA

• Orgnization (microarchitecture)

• Implementation

To meet requirements of

• Functionality (application, standards…)

• Price

• Performance

• Power

• Reliability

• Dependability

• Compatability

• ..

Page 19: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

ISA

25

An instruction set architecture (ISA) is the interface between the

computer's software and hardware and also can be viewed as the

programmer's view of the machine (functionality).

Page 20: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Microarchitecture

26

Microarchitecture is the way a given instruction set

architecture (ISA) is implemented on a processor.

von Neumann architecture

Page 21: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Microarchitecture

27

Page 22: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Microarchitecture

28

Page 23: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Implementation

29

Page 24: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

The role of computer architecture?

30

Page 25: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Why computer architecture?

31

Understand how to evaluate and choose

• What do we mean ”one computer is faster than another”?

• How can Gene Amdahl help you decide which enhancement

is the best?

• Is a larger cache better than higher clock frequency?

• Why is pipelining “faster” than combinational circuits?

• Different levels of caches - why?

• ...

Design your own specialized architecture

• Embedded special purpose processors

Axis Communications/Ericsson/Nokia/ARM/SAAB

...

Write better program

Page 26: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

What affects computer architecture?

32

Applications

Page 27: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

X86 Architecture

33

Page 28: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Architecture change due to new applications

34

?

Page 29: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Architecture change due to new applications

35

Page 30: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Programmable devices

•Microprocessors, digital signal processors, FPGA and memories

Application-specific integrated circuits (ASIC)

•Designed for a narrow range of applications

Devices

36

ASIC FPGA

Processor

Power

FlexibilityASIC

DSP

Std. Proc.

FPGA

Reconfiguring

of hardware

Specialization

of processor

Page 31: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Devices (Hybrid Computing)

All Programmable

SoC

Page 32: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Devices (Hybrid Computing)

38

Page 33: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

40

Page 34: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

After this course, you will...

Have a thorough knowledge about the design principles for

modern computer systems

Have an understanding of the relations between

• The design of the instruction set of a processor

• The microarchitecture of a processor

Be able to evaluate design alternatives towards design goals

using quantitative evaluation methods

”Side” effects...

• Better digital IC designer

• Better understanding of compiler, operating system, high-

performance programming

Course Objectives

41

Page 35: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Book Recommendation

Computer Architecture – A Quantitative Approach

• HP: Hennessy, Patterson

• 5th Edition

Page 36: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Course Content & Schedule

43

Overview

Instruction set

architecture

Pipeline

Memory System

Storage System

I/Os

Multiprocessor

Concept &Theory

Assignment & Project

Exams

Page 37: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Lecture

• Liang Liu, Associate Professor

• Email: [email protected]

• Room: E2342

• Homepage: http://www.eit.lth.se/staff/Liang.Liu

Course secretary

• Anne Andersson, Room 3152B

• e-mail: [email protected]

Teaching Assistants

• Mojtaba Mahdavi

• Steffen Malkowsky

Teachers

44

Mojtaba

Mahdavi

Steffen

Malkowsky

Page 38: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Lecture

• Liang Liu, Associate Professor

• Email: [email protected]

• Room: E2342

• Homepage: http://www.eit.lth.se/staff/Liang.Liu

Course secretary

• Anne Andersson, Room 3152B

• e-mail: [email protected]

Teaching Assistants

• Mojtaba Mahdavi

• Steffen Malkowsky

Invited Lecture

• Fuad Tabba, ARM, Lund

• Nov. 28th, Cache coherence, Multi-core

Teachers

45

Page 39: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Lectures and Labs

Lectures (10 or more)

• Tuesday : 13:15-15:00 E:B/Thursday: 08:15-10:00 E:B

• Covers design principles and analysis methodology

• Read the literature before each lecture

• Does NOT cover all of the literature

Seminar/Exercise (1-2)

• Problems in previous exams

Labs (4)

• Tuesday: 08:15-12:00 E:4118-E:4119

• Friday: 13:15-17:00 E:4118-E:4119

• 2 students/group

• Read manual and literature before the lab

• Do Home Assignments before lab

• Experiment and discuss with assistants

• Understand what you have done (or FAIL the exam)

• Finish Lab before DEADLINE

http://www.eit.lth.se/index.php?ciuid=&coursecode=eitf20&L=1

Page 40: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Examination (Written)

Anonymous exam

Pass all labs to be able to attend written exam

Five problems• Highly lab related

• Problem solving

• Descriptive nature

Oral exam before Christmas (only) for exchange students

47

Page 41: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Questions?

48

Page 42: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

49

Page 43: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

The first electronic computer

50

ENIAC-1946

18 000 vacuum tubes, 30 ton, 150m2 ,140kW

Page 44: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

The first electronic computer

51

ENIAC-1946

18 000 tubes, 30 ton, 150m2 ,140kW

How many transistors

of today’s most

advanced CPU?

Page 45: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

The first electronic computer

52

ENIAC-1946

18 000 tubes, 30 ton, 150m2 ,140kW

If we just scale up from

18000 to 2 billion:

4 Mton = 1.7 million Volvo V70

19 Mm2 = 2700 football filed

18 GW = 28 Barsebäcksreaktorer

Page 46: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Development of Microprocessor

53

Page 47: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu54

Moore’s Law

Electronics, Apr. 19, 1965

Gordon Moore (co-founder of Intel)

described a doubling every year in

the number of components per

integrated circuit

16

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

1959

1960

1961

1962

1963

1964

1965

1966

1967

1968

1969

1970

1971

1972

1973

1974

1975

LOG

2 OF

THE

NU

MB

ER O

F

CO

MPO

NEN

TS P

ER IN

TEG

RA

TED

FU

NC

TIO

N

Page 48: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu55

Moore’s Law

Moore reformulates to a doubling every 2 years. (1975)

Interview 2000:

”...change the doubling time again... to maybe four or five

years.”

Gordon Moore

Co-founder of Intel ca. 1 billion transistors in 2007

Page 49: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Performance of Microprocessor

56

Page 50: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu60

Does not Apply to All

Processing power doubles every 18 months

Memory size doubles every 18 months

Disk capacity doubles every 18 months

Disk positioning rate (seek & rotate) doubles every ten years!

Speed of DRAM and disk improves a few % per year

Page 51: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Moore’s Law: power density

61

www.xbitlabs.com

Pentium IV chip area

(in 130 nm technology)1.3 cm2

This gives about 100 W/cm2 that

needs to be transported away (cooling)

Comparison: This little thing

operates at about 10 W/cm2.

Page 52: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Moore’s Law: power density

1

10

100

1000

10000

Po

wer D

en

sit

y [

W/

cm

²]

4004

8008

8080

8085

8086

286386

486

P6

Pentium® proc

Source: Borkar, De Intel

Rocket Nozzle

Nuclear Reactor

Hot Plate

62

Sun’s

Surface

i5, i7

Page 53: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Heating (power) is a issue

63

Page 54: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Heating (power) is a issue

64

Page 55: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Architecture change?

65

Page 56: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Trend: Applications

66

Computation

£17,000

(1832)

Communication

Consumer Control

Page 57: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Trend: Applications

67

Communication

(5G & Beyond)Computation (Cloud,

Mobile, Fog)

Consumer

(IoT, IoE)

Control

(AI, ML, DL)

Page 58: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

68

Page 59: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

What is Performance?

69

Time to complete a task (Texe)

• Execution time, response time, latency

Task per day, hour…

• Total amount of tasks for given time

• Thoughput, bandwidth

Speed of Concorde vs Boeing 747

Throughput of Boeing 747 vs Concorde

Page 60: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Performance

70

How to define execution time?

Page 61: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Performance

71

Page 62: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Program to evaluate performance

72

Real programs: e.g. TeX, spice, SPEC benchmarks, ...

Kernels - small, key pieces of real applications

Toy programs - sort, prime number generation

• Something 100-line programs

Synthetic benchmarks - “The average program”

• Fake programs to mathc the behaviour of real applications

• Real programs are the only true measurement objects

SPEC benchmarks will be used here (plus some toy programs )

• Real programs modified to be portable and to minimize the effect of IO

Page 63: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Which Computer is Faster?

74

A is 10 times faster than B for P1

B is 10 times faster than A for P2

A and B are faster than C for P1

C is faster than A and B if both P1 and P2 are run

Page 64: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Which Computer is Faster?

75

Page 65: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Aspect of CPU performance

76

Page 66: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Instructions are not created equally

77

Page 67: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Average CPI: example

78

Invest resources where time is spent!

Page 68: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Outline

Computers

Computer Architecture

This Course

Trends

Performance

Quantitative Principles

79

Page 69: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Quantitative Principles

80

This is intro to design and analysis

• Take advantage of parallelism

ILP, DLP, TLP, ...

• Principle of locality

90% of execution time in only 10% of the code

• Focus on the common case

In making a design trade-off, favor the frequent case ove the

infrequent case

• Amdahl’s Law

The performance improvement gained from uisng faster mode is

limited by the fraction of the time the faster mode can be used

• The Processor Performance Equation

Page 70: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Amdahl’s Law

81

Best you could ever hope to do:

enhancedmaximum Fraction - 1

1 Speedup

Page 71: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Amdahl’s Law: example

82

New CPU is 10 times faster!

60% for I/O which remains almost the same…

56.1

64.0

1

10

0.4 0.4 1

1

Speedup

Fraction Fraction 1

1 Speedup

enhanced

enhancedenhanced

overall

Apparently, its human nature to be attracted by 10X

faster, vs. keeping in perspective its just 1.6X faster

Page 72: EITF20: Computer Architecture - EIT, Electrical and … ·  · 2017-10-31EITF20: Computer Architecture Part1.1.1: Introduction ... Microarchitecture is the way a given instruction

Lund University / EITF20/ Liang Liu

Amdahl’s Law: example

83

http://www-inst.eecs.berkeley.edu/~n252/paper/Amdahl.pdf