Docsity

Microprocessors as Building Blocks - Lecture Notes | ECE 6500, Study notes of Computer Architecture and Organization

Toggle sidebar
bg1
1 of 42
Chapter 4
Chapter 4: Microprocessors as Building Blocks
High performance computing has evolved toward scalable systems with structured architectures
that contain many common attributes. The components elements of these architectures seek to
employ commodity parts whenever and wherever possible.
The use of commodity components is most evident when considering the microprocessors used
as the foundation of the processing systems.
4.1 System Development Trends
Shortcomings in modern computer technology:
• The data transfer speed lags behind the processing capability.
> The computation speeds are increasing faster than communications and/or memory
accesses.
> Amdahl’s Rule (MFLOPs to Mbps to MBytes) is a challenge to achieve
• The software lags behind the hardware.
> Software does not allow users to fully utilize hardware (hyperthreading?!)
> Application and system software typically developed after the hardware exists.
Therefore, it can be expected to be one generation behind!
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a

Partial preview of the text

Download Microprocessors as Building Blocks - Lecture Notes | ECE 6500 and more Study notes Computer Architecture and Organization in PDF only on Docsity!

Chapter 4

Chapter 4: Microprocessors as Building Blocks

High performance computing has evolved toward scalable systems with structured architectures that contain many common attributes. The components elements of these architectures seek to employ commodity parts whenever and wherever possible.

The use of commodity components is most evident when considering the microprocessors used as the foundation of the processing systems.

4.1 System Development Trends

Shortcomings in modern computer technology:

  • The data transfer speed lags behind the processing capability.

    The computation speeds are increasing faster than communications and/or memory accesses. Amdahl’s Rule (MFLOPs to Mbps to MBytes) is a challenge to achieve

  • The software lags behind the hardware.

    Software does not allow users to fully utilize hardware (hyperthreading?!) Application and system software typically developed after the hardware exists. Therefore, it can be expected to be one generation behind!

Advances in Hardware

For Processors: Moore’s Law

http://en.wikipedia.org/wiki/Moore's_law

Moore's law is the empirical observation that at our rate of technological development, the complexity of an integrated circuit, with respect to minimum component cost will double in about 24 months.

For Memory DRAM has made tremendous strides of late.

For Storage Media DVD with Blue-Ray coming n*4.7 GB

Communication Subsystems Gigabit Ethernet has vastly improved capabilities. Fiber Optics has allowed a radical increase.

Advances in Software

Advancing more slowly than hardware.

The dominant focus of computer science departments is not on parallel computing at present.

There is a lack of good tools for parallel processing architectures

  • Operating system utilities
  • Application subsystem and middleware tools (databases, transaction processing, etc.)
  • Programming language compilers
  • Software libraries
  • Profiling, debugging, performance monitoring and visualization utilities.

Advances and Good News

  • Problems and issues have been identified and are being worked on
  • There is a consensus for architecture independent tools with portability and generation scalability
  • Open standards and tools are emerging
  • System application vendors are deeply involved IBM, Oracle, Sybase and Informix all provide parallel database management systems, Microsoft and Sun are working with distributed and parallel processing middleware layers.

Examples:

  • Intel Cluster Toolbox for Linux
  • SUN HPC Cluster Tools
  • HP: Compiler and Development Toolchain for Linux

Advances in Applications

Comparison of parallel and sequential programming

Database, Scientific, Engineering, Embedded Systems

Applications:

Algorithm Paradigm

Programming Model

Divide-and-Conquer Dynamic Programming Branch-and-Bound

Sequential Parallel

SISD based Model (Fortran, C, etc.)

Work-Pool, Pipelining, Master-Slave, Asynch. Iteration, etc.

MIMD based Model (Shared Memory/ Variable, Message Passing MPI, etc.)

There is a focus on what can be done based on what is available.

Parallel Processing Paradigms

Structured parallel algorithms are being identified and used. Processing farm (RPC), divide-and-conquer, pipelining, hyperthreading

Parallel Algorithms

Latency hiding communications functions (MPI) Coarse grain parallelism understood and being applied Low interaction requirements Regular structures able to exploit parallelism

Parallel Standards Support

Communications functions (MPI, Ethernet, others) Language support High level language with object oriented code

Application well defined

Scientific: biology, chemistry, physics, astronomy, climate and weather, environmental, geophyics, engineering, imaging, and signal processing Business: database management, e-commerce transaction processing, data warehousing, data mining Networks: WWW, browser services, streaming video, digital libraries, telemedicine

Definitions:

Pipeline cycle or processor cycle: The clock rate driving the processor. It is the time delay or period that is required to complete one stage of the pipelined sequence of operations.

Instruction Issue Latency: The number of processor cycles between the issuing of consecutive instructions.

Cycles per Instruction (CPI): The number of cycles needed to execute a given instruction through the pipeline. The CPI is instruction-dependent, therefore, the average CPI is usually derived or defined for a program.

Instruction Issue Rate: The number of instructions issued per processor cycle.

Simple Operations: Operations requiring only a single clock cycle to complete.

Complex Operations: Operations requiring multiple clock cycles to complete

Resource Conflicts: Where two or more instructions demand use of the same processor resource at the same time. Typically the same execution unit, but also the same register or memory location.

Speed up processing systems by increasing the Instruction Issue Rate

Complex Instruction Set Computer (CISC)

Instruction may consist of multiple words based on the instruction complexity and the addressing mode required.

Origin: Initial Instructions Set and Computer Architecture Hardware designed to facilitate software languages and programming

Addressing: Many modes built in to assembly language

Instructions: Complex, defined based on software and/or application requests

CPI: Cycles per instruction increasing with instruction complexity

Arbitrary pipeline stage delays may be required during the instruction fetch, decode (operand addressing and fetching), execution, or write back (result addressing)

Pipeline flushing needed for branch operations.

F D E WB F D E WB F D E WB F D E WB F D E WB

F E

D WB F D E WB CISC Cycle Based Pipelined Scalar Processor Execution

F D E WB F D E WB F D E WB F D E WB Branching in Cycle Based Pipelined Scalar Processor Execution Branching can require processors to “stall” and/or pipelines to be “flushed”

From CISC to RISC and Beyond

CISC

CISC got out of hand …. How to get more accomplished faster … one way is to reduce CPI < 25 % of instructions executed 95 % of the time …. results in wasted hardware and large size

To Reduce the CPI, the instructions had to get easier and faster. Maximize the rate at which instructions are issued (CPI=1 goal) Instructions should be easily decoded (fewer, simpler instructions)

Memory Accesses are slow and a major processor speed impediment Add more registers for fewer memory accesses Force use of registers by limiting memory accesses to load and store

These and other concepts resulted in a “Reduced Instruction Set Computer” (RISC)

Reduced Instruction Set Computer (RISC)

Origin: 1980 Berkeley: David Patterson and Carlo Sequin 1981 Stanford: John Hennessy

Addressing: Load/Store

Instructions: Fixed length (typically word length), minimal formats

CPI: Cycles per instruction increasing with instruction complexity

RISC Design Principles

All Instructions are directly executed by hardware

Maximize the rate at which instructions are issued

Instructions should be easily decoded

Only load and store instructions should reference memory

Provide plenty of registers

RISC allows a continuous pipeline flow that is not instruction complexity or operand dependent (except when data is not in a register).

RISC allowed the entire CPU to be on one piece of silicon, including the cache. (CISC was having trouble.)

Cache Considerations:

Cache Memory From the French cacher , to hide, it tries to hide main memory latency Pronounced: “cash”

The success of cache in speeding up access to main memory is due to: the Locality of Reference Principles

  • Sequential Programs and data storage tend to be sequential
  • Spatial Data storage areas tend to be in spatial blocks
  • Temporal Memory recently used in time

Cache Architectures: Unified and Split Cache

Inst. Unit

Cache

Proc. Unit

Memory

Bus Interface

Inst. Unit

I-Cache

Proc. Unit

Memory

Bus Interface

D-Cache

Unified Cache Classic CISC

Split Cache (Harvard Architecture) Pure RISC

Architectural Enhancements

CISC and RISC have traded off ideas and innovative techniques to create modern processing architectures.

Superscalar: Multiple Execution Units

Superpipelined: Sub-machine cycles per “pipeline stage”

Hybrid CISC/RISC: Front end is CISC compatible, backend is RISC

VLIW: Very Large Instruction Word (multiple execution units)

The design space for commodity processors from 1980 to 2000. Figure 4.11.

4.3 Microprocessor Architecture Families

Scalar and Scalar Pipelined Processors

Instruction Fetch Decode^ Execute^ Write Back

Instruction Execution

F D E WB F D E WB F D E WB Cycle Based Scalar Execution

F D E WB F D E WB F D E WB F D E WB F D E WB Cycle Based Pipelined Scalar Execution

Time to process in a pipelined scalar processor (a base single-issue machine)

T ( 1 , 1 )= k + N − 1

where k is the number of pipeline stages and N is the number of instructions executed.

Single Issue Superpipelined Processors

Instruction Fetch Decode^ Execute^ Write Back

Instruction Execution

F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W Cycle Based Superpipelined Execution

Time to process in a single issue superpipelined processor

n

N

T n k

Speedup

N n k

n k N

n

N

k

k N T n

T

S n

n N

n N S n N

→∞

Superscalar Superpipelined Processors

Instruction Fetch Decode

ALU

Write Back Floating Point

Load or Store Instruction Execution

F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W F D E W Cycle Based Superscalar Superpipelined Execution

Time to process in a superscalar superpipelined processor

n m

N m T mn k ⋅

Speedup

N n m k m

n m k N

n m

N m k

k N Tmn

T

S mn

  • ⋅ ⋅ −

n m N

n m N S mn N

→∞

4.4 Case Studies of Microprocessors

Instruction Fetch and preprocessing units

On-board Instruction Cache Acquire local copy of most likely instructions to reduce stalls due to instruction fetch

Instruction Queue and pre-decoder Immediate sequential collection of instructions. Provide multiple instruction pointers for current program counter (PC), top of queue, and other instruction locations Allows unit to reorder instructions and to preprocess branch targets Allow instruction translation into a micro-code sequence (replace an instruction with another set of instructions)

Out-of-Order Instruction Issue Look across instruction queue for next executable instruction Check for resource conflicts and data dependency (register conflicts may be avoided using temporary registers or register renaming ) Also allows or invites speculative execution (execute some instructions that you may not want to keep after they are done)

Branch Target Buffer Insure that possible branch targets are in the Instruction Cache Manage Next Instruction Pointer Involved with static and dynamic branch prediction

Static Branch Prediction The compiler instructions forces branch pre-decision Forward branches not taken, backward looping branches taken.

Dynamic Branch Prediction Additional logic used to “remember” previous operation and repeat (follow the same code sequence as was previously performed) Define branch history and a protocol to select what to do next time

Execution Units

Reservation Stations Hold queued μops until data is available to execute Allows μops to be issued while not stalling instruction unit Involved with static and dynamic branch prediction

Out-of-Order Execution Execution happens when instruction and data are available

Retire Unit

Flush non-desired executions Resolve speculative execution operations, keep or discard

Complete Instruction Typically retired in-order, as expected by code Rename temporary registers with correct instruction names Insure that data will eventually be written to cache/memory

Examples

Digital Alpha 21164

Intel P6 Architecture (Pentium Pro, Celeron, Pentium II)