DSP on General-Purpose Processors — An Overview or Can ... · What’s Special About DSP...

32
Page 1 of 32 DSP on General-Purpose Processors Page 1 of 32 11/18/97 Copyright © 1997 Berkeley Design Technology, Inc. Berkeley Design Technology, Inc. DSP on General-Purpose Processors — An Overview or Can General-Purpose Processors Replace DSPs? MicroDesign Resources DInner Meeting Santa Clara, California January 9, 1997 Jeff Bier Berkeley Design Technology, Inc. Berkeley, California E-mail: [email protected] Web: www.bdti.com Tel: (510) 665-1600 Copyright © 1997 Berkeley Design Technology, Inc. All rights reserved.

Transcript of DSP on General-Purpose Processors — An Overview or Can ... · What’s Special About DSP...

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

An Overview

ace DSPs?

ts reserved.

Page 1 of 3211/18/97slides_pdf.fm5

Page 1 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

DSP on General-Purpose Processors — or

Can General-Purpose Processors Repl

MicroDesign Resources DInner MeetingSanta Clara, California

January 9, 1997

Jeff Bier

Berkeley Design Technology, Inc.Berkeley, California

E-mail: [email protected]: www.bdti.comTel: (510) 665-1600

Copyright © 1997 Berkeley Design Technology, Inc. All righ

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

deo, motor control,

mmable) in 1996

rward Concepts]

rocessors (GPPs).

bsume the other

Page 2 of 3211/18/97slides_pdf.fm5

Page 2 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Why is this Important?

DSP applications are proliferating dramatically:

• Wired and wireless comms., music, speech, vinoise cancellation, navigation, ...

• Many products are becoming DSP-intensive

The DSP chip market is booming:

• $2.3B (programmable) and $3.6B (non-progra

• Growth rate > 30% per year [Source: Fo

Many products contain DSPs and general-purpose p

• With increasing integration, one will tend to su

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

n

rs

Page 3 of 3211/18/97slides_pdf.fm5

Page 3 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Outline of Today’s Presentatio

Focus: DSP capabilities of general-purpose processo

• Applications and system architectures

• Processor architectural approaches

• Evaluation criteria

• Evaluating GPPs for DSP applications

• Conclusions and Trends

Not included:

• “Media” processors

• Non-programmable devices

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

t

y ?

ony,

gration, cost- many applications

be problematic

ifficult

Page 4 of 3211/18/97slides_pdf.fm5

Page 4 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Short Answer for the Impatien

Can general-purpose processors replace DSPs toda

Yes:

• Especially in personal computers

• Especially for certain applications; e.g., telephvideoconferencing

But, you may not want to, because:

• DSPs have an unbeatable combination of inteperformance, low power, and infrastructure for

• Ensuring strict real-time behavior on GPPs can

• DSP software development on GPPs can be d

Requires application-by-application analysis

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

tures

Page 5 of 3211/18/97slides_pdf.fm5

Page 5 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Applications and System Architec

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

tions?

int

Page 6 of 3211/18/97slides_pdf.fm5

Page 6 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

What’s Special About DSP Applica

Demands:

• Lots of number crunching

• High data bandwidth; limited data locality

• Real-time constraints

• Attention to subtle numeric effects (in fixed-poimplementations)

• Specialized peripherals/interfaces

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

categories:

gnition/synthesis, on

nes, pagers, motor ering machines

eneral-purpose

ow, but embedded

Page 7 of 3211/18/97slides_pdf.fm5

Page 7 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Applications

For this analysis, we divide DSP applications into two

• Personal-computer-based

• E.g., modems, speech compression/recomusic/sound synthesis, video compressi

• Embedded

• E.g., disk drive servo control, cellular phocontrol, navigation, modem banks, answ

Both classes are candidates for implementation on gprocessors.

PC-based applications are receiving more attention napplications are and will be far more numerous.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

rocessor can be

onsumption

Page 8 of 3211/18/97slides_pdf.fm5

Page 8 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

System Architectures

Many existing or emerging products:

• Already contain a µP or µC

• Already contain a µP or µC plus a DSP

• Require µP/µC and DSP functionality

Merging all programmable functionality into a single pattractive:

• High integration can reduce size, cost, power c

• Leverages existing software, tools, know-how

• Few modifications to existing system hardware

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

hes to DSP

Page 9 of 3211/18/97slides_pdf.fm5

Page 9 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Overview of GPP Architectural Approac

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

DSP

iety of approaches

P features)

nted features

Page 10 of 3211/18/97slides_pdf.fm5

Page 10 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

GPP Architectural Approaches to

General-purpose processor vendors have taken a varto addressing DSP performance:

• Baseline GPPs (moderate performance, no DS

• High-performance GPPs with few/no DSP-orie

• GPPs with major DSP-oriented features

• SIMD

• DSP-processor-like

• DSP co-processors

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

s

I

atures perform

tection,

Page 11 of 3211/18/97slides_pdf.fm5

Page 11 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

I: Baseline GPP Architecture

Example: Advanced RISC Machines’ ARM7TDM

Typical moderate-performance GPPs with no DSP fepoorly on DSP tasks.

The main reasons for this are:

• Poor multiplication throughput

• Limited memory bandwidth

• Loop overhead

• Address generation overhead

Also, on fixed-point processors:

• Lack of hardware support for fast overflow proconvergent rounding, etc.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

DSP Features

R4650

s.

ical DSPs)

ations

and multi-issue

ia multi-issue

f DSP code and

Page 12 of 3211/18/97slides_pdf.fm5

Page 12 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

II: High-Performance GPPs with No/Few

Example: Pentium (P54C), PowerPC 604e, IDT

These processors can perform very well on DSP task

The main reasons for this are:

• High clock rates (200+ MHz; 2-5 X those of typ

• Single-cycle multiplication and arithmetic oper

• Good memory bandwidth

• Loop overhead reduced via branch prediction

• Address generation, other overhead reduced v

However, dynamic features complicate optimization oreal-time development.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

(1 of 2)

ns

nce by combining s (group II) with

itioned one)

e.g., 4 multiplies)

data types

ecture can be

Page 13 of 3211/18/97slides_pdf.fm5

Page 13 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

III: GPPs with Major DSP Features

Approach A: Single-instruction, multiple-data operatio

Example: Intel MMX Pentium (P55C)

These processors achieve outstanding DSP performathe features of “conventional” high-performance GPPnew SIMD capabilities:

• Partition existing data path (or add a new, part

• Multiple operations/cycle on small data types (

• Single-cycle operations on various fixed-point

• Specialized instructions

Integration of these features into a pre-existing architawkward.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

(2 of 2)

es

y mimicking DSP

ated registers

addressing,

ecture can be

Page 14 of 3211/18/97slides_pdf.fm5

Page 14 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

III: GPPs with Major DSP Features

Approach B: Integration of DSP-processor-like featur

Example: Hitachi SH-DSP

These processors achieve good DSP performance bprocessors.

To a conventional GPP architecture, they add:

• A DSP-oriented data path, complete with dedic

• Address generators, hardware looping, modulosaturation, etc.

Integration of these features into a pre-existing architawkward.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

on DSP tasks.

Page 15 of 3211/18/97slides_pdf.fm5

Page 15 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

IV: DSP Co-processors

Example: ARM Piccolo

These processors should achieve good performanceNone widely deployed yet.

Approach is similar to IV(B), but:

• Programming can be more complicated

• More parallelism may be possible

Contrast with DSP + GPP on one chip:

• Motorola MC68356

• Texas Instruments TMS320C54x + ARM7

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

Page 16 of 3211/18/97slides_pdf.fm5

Page 16 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Evaluating GPPs for DSP

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

de off vs. speed)

Page 17 of 3211/18/97slides_pdf.fm5

Page 17 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

What’s Most Important?

• DSP speed

• DSP numeric performance (can sometimes tra

• Cost

• Cost/performance

• Power consumption

• Real-time suitability

• Product development time and cost

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

n Time ( µs)

PP

C 6

04e

200

MH

z

PP

C 6

04e-

C20

0 M

Hz

AD

SP

-210

6240

MH

z

AD

SP

-210

62-C

40 M

Hz

110

87

159 158

Floating-Point

on-chip caches preloaded

Page 18 of 3211/18/97slides_pdf.fm5

Page 18 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Speed: BDTI FFT Benchmark Executio

AR

M7T

DM

I40

MH

z

SH

-DS

P60

MH

z

P55

C20

0 M

Hz

P55

C-C

200

MH

z

IDT

R46

5013

3 M

Hz

TM

S32

0C54

x66

MH

z

P54

C20

0 M

Hz

P54

C-C

200

MH

z

1098

211

89 86

217

199

159151

1100

300

200

100

0

Measured

Fixed-Point

Estimated “-C” indicates

(Lower is Better)

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

effects.essors.

t support

ith software, but

Page 19 of 3211/18/97slides_pdf.fm5

Page 19 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

DSP Numeric Performance

DSP applications are often very sensitive to numeric This is typically not a concern with floating-point proc

On fixed-point processors, key issues include:

• Selection of appropriate word widths

• Overflow protection

• Convergent rounding

• Multi-precision/block floating-point/floating-poin

Lack of needed hardware support can be overcome wthe cost may be high.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

.

rom processor

processor plus its hanced GPP.

PPs vs. DSPs:

mance penalty for rice/perf. at high end.

Page 20 of 3211/18/97slides_pdf.fm5

Page 20 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Cost

Cost is surprisingly tricky to analyze.

• Processor cost alone is often not very relevant

Need to compare the overall system costs resulting fchoices.

• E.g., may need to compare the cost of a DSP own memory vs. the cost of upgrading to an en

• Memory usage plays an important role.

Pricing strategies are very different for PC-oriented G

• PC-oriented GPPs command > 2X price/perforthe fastest versions. DSPs have their best p

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

Speed(MHz)

Unit Price(Qty. 1,000)

60 $45

133 $63

133 $34

200 $550

66 $35

200 $509

100 $106

225 $620

100 $173

40 $170

Page 21 of 3211/18/97slides_pdf.fm5

Page 21 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Example Cost

Type Vendor Processor

Fixed-Point

Hitachi SH-DSP

IDTR4650

R4640

IntelMMX Pentium

(projected)

Texas Instr. TMS320C548

Floating-Point

Intel Pentium

Motorola PowerPC 604e

Analog Devices ADSP-21062

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

Benchmark

100

MH

z

PP

C 6

04e-

C13

3 M

Hz

AD

SP

-210

62-C

33 M

Hz

1.25

1.77

ating-Point

on-chip caches preloaded

Page 22 of 3211/18/97slides_pdf.fm5

Page 22 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Cost-Execution Time Product, Block FIR

SH

-DS

P60

MH

z

P55

C-C

200

MH

z

IDT

R46

5013

3 M

Hz

TM

S32

0C54

x50

MH

z

P54

C-C

0.34

1.25

0.18

0.74

1.48

2.00

1.50

1.00

0.50

0

($-µs, Lower is Better)

Measured Estimated

FloFixed-Point

“-C” indicates

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

ria in many

ance with very low e power

geTypical Power Consumption

(W)

.0 0.20 (est.)

3 2.1

.0 0.11

Page 23 of 3211/18/97slides_pdf.fm5

Page 23 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Power Consumption

Power consumption is a key processor selection criteimportant DSP applications.

• Today, only DSPs combine good DSP performpower consumption and application-appropriatmanagement.

Example data:

Vendor ProcessorSpeed(MHz)

Volta(V)

Hitachi SH-DSP 40 3

IDT R4650 133 3.

Texas Instr. TMS320C54x 50 3

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

general-duction?

Page 24 of 3211/18/97slides_pdf.fm5

Page 24 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Real-Time Suitability

Q: Why is running DSP code onpurpose processors like alien ab

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

me.

Page 25 of 3211/18/97slides_pdf.fm5

Page 25 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Real-Time Suitability

A: Both result in inexplicable gaps in ti

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

pplications.

: failure to meet a n.

features:

ar execution, data-

to be stochastic.

P applications.

real-time support

Page 26 of 3211/18/97slides_pdf.fm5

Page 26 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Real-Time Suitability

The most important DSP applications are real-time a

• Many of these are “hard real-time” applicationsreal-time deadline creates a serious malfunctio

High-performance GPPs make heavy use of dynamic

• Caches, branch prediction, dynamic superscaldependent instruction execution times, etc.

These features result in timing behavior that appears

• This seriously complicates development of DS

PC applications are further complicated by the lack ofin PC operating systems.

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

Cost

ent effort:

n

s requires using

ogram for DSP

l support, but DSP-

ar between

Page 27 of 3211/18/97slides_pdf.fm5

Page 27 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Product Development Time and

Among the most important factors affecting developm

• Breadth and quality of tools and documentatio

• Processor ease of use

• Availability of off-the-shelf software libraries

Developing DSP code for general-purpose processorassembly language when efficiency is important.

• High-performance GPPs are very difficult to pr

• The most popular GPPs enjoy unparalleled toooriented tools are rare

• DSP software libraries for GPPs are few and f

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

nge

update

update

eration

pdate

Page 28 of 3211/18/97slides_pdf.fm5

Page 28 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Example of Optimization Challe

Vector addition on PowerPC 604e:

@vec_add_loop:

lfsu fpTemp1,4(rAAddr) # Load A data, ptr.

lfsu fpTemp2,4(rBAddr) # Load B data, ptr.

fadds fpSum,fpTemp1,fpTemp2 # Perform add op

stfsu fpSum,4(rCAddr) # Store sum, ptr. u

bdnz @vec_add_loop # loop

Q: How many instruction cycles per iteration?

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

Page 29 of 3211/18/97slides_pdf.fm5

Page 29 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Conclusions and Trends

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

DSPs?

s strong. ls are weaknesses.

lly where a µP or s are

eeds are modest.

ing the best quality DSPs and other

plications, today’s lled together all of e.

Page 30 of 3211/18/97slides_pdf.fm5

Page 30 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Conclusions: Can GPPs Replace

Today:

Yes:

• In some PC DSP applications, the case iReal-time behavior, OS support, and too

• In some embedded applications, especiaµC is already established, DSP algorithmstraightforward, and DSP performance n

And, no:

• In many PC DSP applications, users needand highest performance will benefit fromspecialized processors.

• In the most important embedded DSP apGPPs cannot compete: they have not puthe necessary attributes and infrastructur

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

asingly important

iented

ructure for GPPs -start

for architectural

ors; DSP and GPP

ed for the wide

f DSP applications

Page 31 of 3211/18/97slides_pdf.fm5

Page 31 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Trends

• DSP applications will continue to become incre

• GPPs will continue to add and expand DSP-orenhancements

• DSP-oriented tools, software, and other infrastwill develop, but DSPs have a significant head

• DSPs will not stand still; there is fertile groundinnovation, clock speed increases, etc.

• There will be an expanding diversity of processfamily trees will mix

• Capabilities will become increasingly specializrange of important DSP applications

• GPPs will be suitable for an expanding range o

DSP on General-Purpose Processors

Berkeley Design Technology, Inc.

eleased)

96, pp. 12-15)

P Strate gies 2000

T, DSP World, etc.

Page 32 of 3211/18/97slides_pdf.fm5

Page 32 of 3211/18/97Copyright © 1997 Berkeley Design Technology, Inc.

Further Resources

• BDTI technical reports:

• DSP on General-Purpose Processors (just r

• Buyer’s Guide to DSP Processors

• Microprocessor Report articles (especially 12/30/

• BDTI’s web site: www.bdti.com

• Forward Concepts market research reports: DS

• DSP-oriented trade shows and conferences: ICSPA

• Join BDTI ... we’re hiring