<<

EmbeddedEmbedded SystemsSystems ComputerComputer ArchitectureArchitecture

JakobJakob EngblomEngblom VirtutechVirtutech ABAB && UppsalaUppsala UUniversityniversity [email protected] EmbeddedEmbedded SystemsSystems

29 November 2002 Embedded Architecture 2 EmbeddedEmbedded SystemsSystems Now what is this elephant thing? You’re all wrong, it is a fan! No, a It is a wall! snake!

No, it is a treetrunk!

No, a pillar!

29 November 2002 Embedded 3 EmbeddedEmbedded SystemsSystems

»»““AA computercomputer thatthat doesn’tdoesn’t looklook likelike aa computer”computer” »»InteractsInteracts withwith worldworld »»PrimitivePrimitive oror nono useruser interfaceinterface »»PartPart ofof otherother productsproducts

29 November 2002 Embedded Computer Architecture 4 EmbeddedEmbedded SystemsSystems

»»TheThe vastvast majoritymajority ofof processors!processors! ¡¡200200 millionmillion PCPC andand serverserver ¡¡80008000 millionmillion embeddedembedded

"Embedded" 98% "Desktop" 2%

29 November 2002 Embedded Computer Architecture 5 EmbeddedEmbedded SystemsSystems

»»SingleSingle purposepurpose productsproducts ¡NotNot generalgeneral purposepurpose likelike desktopdesktop PCsPCs ¡DoDo oneone tthhinging veryvery efficientefficientllyy »»SoftwareSoftware veryvery important:important: ¡GivesGives charactercharacter toto productproduct –Used to differentiate inside a “platform” ¡CanCan bebe changedchanged latelate ¡ProcessorProcessor cheapercheaper thanthan specialspecial HWHW ¡DominatesDominates HWHW developmentdevelopment cost!cost!

29 November 2002 Embedded Computer Architecture 6 RealReal--TimeTime SystemSystem

»»TimingTiming asas importantimportant asas resultresult »»HardHard realreal--time:time: ¡HardHard deadlinesdeadlines ¡DeadDead ifif missedmissed deadlindeadlinee ¡WorstWorst--casecase »»SoftSoft realreal--time:time: ¡FuzzierFuzzier deadlindeadlineess ¡CanCan missmiss somesome deadlinesdeadlines ¡AverageAverage--casecase

29 November 2002 Embedded Computer Architecture 7 RealReal--TimeTime SystemsSystems

»»EmbeddedEmbedded andand RealReal--TimeTime ¡Synonymous?Synonymous? »»Most embedded Most embedded embeddedembedded systemssystems areare realreal--timetime embeddedembedded realreal--timetime »»MostMost realreal--timetime systemssystems areare embeddedembedded realreal--timetime

29 November 2002 Embedded Computer Architecture 8 ExamplesExamples:: SimpleSimple

8- 8051, standard Behavior, talk, IR communications

8-bit Hitachi H8/300 32 kB ROM, 32 kB RAM Standard microcontroller -code machine, drivers, …

29 November 2002 Embedded Computer Architecture 9 NoNo UpgradesUpgrades PossiblePossible

»»OnceOnce aa productproduct ships…ships… »»…it…it oftenoften cannotcannot bebe servicedserviced ¡NoNo downloaddownload abilityability ¡NoNo writablewritable persistentpersistent storagestorage ¡NoNo disksdisks ¡NoNo loaderloader »»SoftwareSoftware isis writewrite--onceonce »»(There(There areare exceptions)exceptions)

29 November 2002 Embedded Computer Architecture 10 ExamplesExamples:: ConsumerConsumer

Heterogeneous multiprocessor 8-bit AVR for UI, control, SMS, … 16-bit fixed-point TI C54 DSP for GSM coding, radio interface, … 32-bit ARM7 in module + maybe ARM7 in IRDA interface All embedded in custom ASICs

29 November 2002 Embedded Computer Architecture 11 ExamplesExamples:: DistributedDistributed

CAN network for body : 30 nodes? CAN network for engine control: few nodes LIN network for instruments

8-bit CPUs (PIC, HC08) for door locks, lights, etc. 16-bit CPUs (C167, HC11, HC12) for most functions 32-bit CPUs (PPC,) for engine control, airbags Total: up to 100 CPUs in a high-end car Total amount of code: 40-50 MB

29 November 2002 Embedded Computer Architecture 12 Examples:Examples: DistributedDistributed

»»FormForm followsfollows functionfunction ¡ProcessingProcessing wherewhere thethe actionaction isis ¡ArchitectureArchitecture givengiven byby applicationapplication ¡SensorsSensors andand actuatorsactuators distributeddistributed »»HeterogeneousHeterogeneous systemssystems ¡ManyMany differentdifferent makesmakes ofof CPUsCPUs ¡StandardizedStandardized atat thethe networknetwork//bus

29 November 2002 Embedded Computer Architecture 13 TimingTiming AspectsAspects

»»InterruptInterrupt latencylatency ¡ImportantImportant criterioncriterion forfor embeddedembedded ¡AA fewfew clockclock cyclescycles atat mostmost ¡MeasureMeasure ofof RTOSRTOS performanceperformance »»RealReal--TimeTime == predictabilitypredictability ¡InIn--orderorder pipelinespipelines ¡SRAMSRAM insteadinstead ofof cachescaches ¡LockableLockable cachescaches ¡SeveralSeveral smallsmall CPUsCPUs insteadinstead ofof oneone bigbig

29 November 2002 Embedded Computer Architecture 14 ExamplesExamples:: ExtremeExtreme

Standard multiprocessor UltraSparc servers for radar, target tracking, combat control, …

Many CPUs in missiles, gun controls, engines, …

29 November 2002 Embedded Computer Architecture 15 TrendsTrends

»»HardwareHardware toto softwaresoftware ¡ IncreaseIncrease flexibility,flexibility, lowerlower costcost ¡ SoftwareSoftware onon fastfast processorprocessor cancan equalequal HWHW »»SoftwareSoftware toto hardwarehardware ¡ BetterBetter powerpower consumptionconsumption && performanceperformance ¡ DesignDesign customcustom hardwarehardware forfor applicationapplication »»HardwareHardware--softwaresoftware codesigncodesign ¡ DelayDelay divisiondivision HW/SWHW/SW toto latelate inin projectproject ¡ ObtainObtain “optimal”“optimal” HW/SWHW/SW divisiondivision

29 November 2002 Embedded Computer Architecture 16 EmbeddedEmbedded ProcessorsProcessors

29 November 2002 Embedded Computer Architecture 17 MicrocontrollersMicrocontrollers

»»:Microcontrollers: RAM (small) ¡CPUCPU CoreCore ROM CPU (big) ¡IntegratedIntegrated memorymemory Core ¡IntegratedIntegrated peripheralsperipherals A/D UART ¡IntegratedIntegrated servicesservices LCD D »»Goal:Goal: Outside World ¡SystemSystem onon oneone chipchip ¡NoNo externalexternal HWHW ¡FitFit applicationapplication “perfectly”“perfectly”

29 November 2002 Embedded Computer Architecture 18 Microcontrollers:Microcontrollers: WideWide SpanSpan

»»ProcessorProcessor size:size: 44 toto 6464 bitsbits ¡MostMost common:common: 88 bitbit (4G(4G units)units) ¡32/6432/64--bitbit outnumbersoutnumbers desktopdesktop ¡3232--bitbit growinggrowing fastestfastest »»Frequency:Frequency: DCDC toto 11 GhzGhz »»Memory:Memory: FromFrom 0.50.5 toto 512512 kBkB »»:Power: mWmW (and(and up)up) »»1/301/30 toto 1010 instructionsinstructions perper cyclecycle

29 November 2002 Embedded Computer Architecture 19 Example:Example: PICPIC 12CE67412CE674

» Architecture:Architecture: HarvardHarvard » ProgramProgram memory:memory: 20482048 xx 1414 (OTP/Flash)(OTP/Flash) » EEPROM:EEPROM: 1616 bytesbytes » RAM:RAM: 128128 bytesbytes » ADCADC channels:channels: 44 (8(8 )bits) » I/OI/O ports:ports: 66 » :Timers: OneOne 88--bit,bit, OneOne WDTWDT » Clock:Clock: onchiponchip crystal,crystal, 10MHz10MHz » Package:Package: 88 pinspins (Pentium(Pentium 4:4: 500500 pins)pins) » Cost:Cost: $1.00$1.00 (Pentium(Pentium 4:4: >$200.00)>$200.00)

29 November 2002 Embedded Computer Architecture 20 Example:Example: ARMARM 926EJ926EJ--SS

» VonVon NeumannNeumann architecturearchitecture » InstructionInstruction sets:sets: ¡ 32-bit ARM v5TE ISA ¡ 16-bit THUMB ISA ¡ Java bytecodes via Jazelle » Clock:Clock: 180180--270270 MhzMhz » :Cache: 88 kBkB icacheicache andand 88 kBkB dcachedcache » Power:Power: 0.20.2 toto 0.90.9 mW/MhzmW/Mhz (P4:(P4: >35>35 mW/MhzmW/Mhz)) » MMU:MMU: forfor SymbianSymbian,, WindowsWindows CE,CE, LinuxLinux » CoreCore macrocellmacrocell,, notnot aa chipchip ¡ Add external units to build complete microcontroller

29 November 2002 Embedded Computer Architecture 21 TrendsTrends

»»MarketMarket ¡3232--bitbit marketmarket isis growinggrowing fastfast ¡DSPsDSPs areare growinggrowing fastfast »»TechnologyTechnology ¡ConfigurableConfigurable processorsprocessors ¡ConfigurableConfigurable logiclogic asas helphelp ¡FusionFusion ofof DSPDSP andand microcontrollersmicrocontrollers ¡MoreMore complexcomplex architecturesarchitectures ¡MoreMore stuffstuff onon aa singlesingle chipchip

29 November 2002 Embedded Computer Architecture 22 InstructionInstruction SetsSets

29 November 2002 Embedded Computer Architecture 23 ISIS ArchiArchitetecturesctures

»»NewNew lifelife forfor oldold architecturesarchitectures ¡Z80,Z80, 6502,6502, 8051,8051, PIC,PIC, ….,…., 6800068000--ColdFireColdFire »»NewNew careercareer forfor failedfailed desktopsdesktops ¡MIPS,MIPS, PowerPCPowerPC »»FreshFresh architecturesarchitectures ¡AVR,AVR, dsPICdsPIC,, V850,V850, SH,SH, ……

29 November 2002 Embedded Computer Architecture 24 InstructionInstruction SetsSets

»»CodeCode SizeSize importantimportant ¡VariableVariable instructioninstruction lengthlength –Several size jumps (short-long-...) –Common instructions short –RISC machines with 16-64 bit instructions –Stunted immediate operand sizes –Two-operand rather than three-operand ¡CompactCompact andand powerfulpowerful instructionsinstructions –Push/pop multiple –

29 November 2002 Embedded Computer Architecture 25 InstructionInstruction SetsSets

»»SpecialSpecial--purposepurpose instructionsinstructions ¡DigitalDigital SignalSignal ProcessingProcessing ¡BitBit--manipulationmanipulation –Set bit in memory, test bit in memory –Several memory accesses per instruction ¡ApplicationApplication--specificspecific –Fuzzy logic support (68HC12) –Table interpolation (68300) ¡OrOr eveneven designeddesigned byby customers!customers! »»DoDo usefuluseful things=powerfulthings=powerful 29 November 2002 Embedded Computer Architecture 26 InstructionInstruction SetsSets

»»CompressedCompressed instructioninstruction setssets ¡ARM/ThumbARM/Thumb && MIPS16MIPS16 ¡1616--bitbit encodingencoding ofof (parts(parts of)of) 3232--bitbit instructioninstruction setssets ¡PerformsPerforms betterbetter onon narrownarrow busesbuses ¡LimitationsLimitations inin Thumb:Thumb: –Only access to 8 registers –No system operations –No multiply-accumulate –No general conditional execution

29 November 2002 Embedded Computer Architecture 27 InstructionInstruction Sets:Sets: CodeCode SizeSize

»»SomeSome datadata onon codecode size:size:

Thumb ARM 386 8088 68020 SPARC eqntott 10608 16768 17640 19106 20542 22256 0.63 1.00 1.05 1.14 1.23 1.33 xlisp 26388 40768 28097 29401 46746 44648 0.65 1.00 0.69 0.72 1.15 1.10 espresso 72596 109923 125686 137194 131854 142752 0.66 1.00 1.14 1.25 1.20 1.30

Source: Report, March 1995

29 November 2002 Embedded Computer Architecture 28 InstructionInstruction Sets:Sets: CodeCode SizeSize

»»CompilerCompiler makesmakes aa differencedifference Program A B D 1 4316 4929 4974 5214 2 16826 18176 26705 15968 3 1632 2594 3450 3244 4 5514 13804 22694 15000+

Source: IAR Internal Benchmarking

29 November 2002 Embedded Computer Architecture 29 InstructionInstruction Sets:Sets: ConfigureConfigure

»»ConfigurableConfigurable instructioninstruction setssets ¡AdaptAdapt toto needsneeds ofof applicationapplication ¡UserUser selectsselects ¡LessLess wastewaste onon generalitygenerality ¡FastFast evolutevolutiionon ofof instructioninstruction setssets »»Traditionally:Traditionally: ¡ChipChip manufacturersmanufacturers determinedetermine instructioninstruction setssets aimedaimed atat somesome nicheniche ¡SlowSlow evolutionevolution ofof instructioninstruction setssets

29 November 2002 Embedded Computer Architecture 30 InstructionInstruction Sets:Sets: ConfigureConfigure

»»SubsetSubset ofof fixedfixed setset ¡ThereThere isis aa limitedlimited andand predefinedpredefined setset ofof instructionsinstructions availableavailable ¡EasyEasy toto compilecompile for:for: restrictrestrict codecode gengen ¡RemoveRemove instructionsinstructions toto simplifysimplify corecore »»AdditionAddition ofof newnew instructionsinstructions ¡CompleteComplete freedomfreedom ¡UseUse assemblyassembly toto accessaccess ¡GenuineGenuine developmentdevelopment ofof ISAsISAs

29 November 2002 Embedded Computer Architecture 31 InstructionInstruction Sets:Sets: ConfigureConfigure

instruction set choices

Gate and memory size counters

29 November 2002 Embedded Computer Architecture 32 MemoryMemory SystemsSystems

29 November 2002 Embedded Computer Architecture 33 Microcontrollers:Microcontrollers: MemoryMemory

»»RAM:RAM: ¡SmallSmall (32(32 bytesbytes andand up)up) ¡Stacks,Stacks, variablesvariables »»ROMROM (or(or FLASH)FLASH):: ¡LargeLarge (2kB(2kB andand up)up) ¡Programs,Programs, constantconstant datadata »»NonNon--volatilevolatile memorymemory ¡Settings,Settings, writablewritable codecode areasareas

29 November 2002 Embedded Computer Architecture 34 MemoryMemory ArchitectureArchitecture

»»NarrowNarrow addressaddress busesbuses ¡SavesSaves siliconsilicon area,area, power,power, complexitycomplexity »»SmallSmall registersregisters == smallsmall pointerspointers ¡1616--bitbit registerregister cancan onlyonly holdhold 1616--bit…bit… ¡BanksBanks (separate(separate bankbank register)register) ¡SegmentsSegments (base(base ++ offset)offset) ¡MemoryMemory remappingremapping (virtual()memory)

29 November 2002 Embedded Computer Architecture 35 MemoryMemory ArchitectureArchitecture

»»ZeroZero--pagepage concept:concept: ¡SmallSmall areaarea ofof RAMRAM ¡QuickQuick accessaccess (single(single--cycle)cycle) ¡OftenOften 88--bitbit indexindex ¡SmallSmall instructionsinstructions ttoo accessaccess ¡CanCan bebe usedused asas pseudopseudo--registersregisters ¡EvenEven onon somesome 3232--bitbit machines!machines!

29 November 2002 Embedded Computer Architecture 36 MemoryMemory ArchitectureArchitecture

»»HierarchyHierarchy ofof FarFar pointerspointers »»VisibleVisible toto NearNear programmerprogrammer »»ExtendExtend CC toto 24 bits handlehandle 16 bits TinyTiny 8 bits == zerozero--pagepage

29 November 2002 Embedded Computer Architecture 37 MemoryMemory ArchitectureArchitecture

»»HarvardHarvard ¡TwoTwo oror moremore addressaddress spacesspaces ¡ProgramProgram ¡DataData ¡…more…more ?data? ¡…special…special memory?memory? ¡…I/O…I/O space?space? »»DeathDeath toto C:C: NULLNULL pointer?pointer?

29 November 2002 Embedded Computer Architecture 38 MemoryMemory ArchitectureArchitecture

»»Example:Example: ATMELATMEL AVRAVR FarFar FarFar »»OneOne forfor codecode andand constantsconstants NearNear NearNear »»OneOne forfor datadata TinyTiny 256 B RAM »»ReadRead constants?constants? Registers ¡ Different instructions! I/O ¡ Very slow ¡ Hard to compile for ¡ Copy to RAM?

29 November 2002 Embedded Computer Architecture 39 BankedBanked MemoryMemory

»»Concept:Concept: ¡SeparateSeparate memoriesmemories ¡MappedMapped ttoo samesame setset ofof addressesaddresses ¡OneOne memorymemory atat aa timetime accessibleaccessible »»SelectingSelecting banks:banks: ¡ValueValue inin bankbank--switchswitch registerregister »»VeryVery commoncommon forfor codecode

29 November 2002 Embedded Computer Architecture 40 MemoryMemory ArchitectureArchitecture

»»Example:Example: MicrochipMicrochip PICPIC familyfamily

Hardware pointer = efficient 8 bits 16 bits 16 bits Bank 0 Bank 1 Bank 2 Bank 3 Code _bank0 _bank1 _bank2 _bank3 memory

__constptr __bank Synthetic pointer to any

29 November 2002 Embedded Computer Architecture data bank 41 ProgrammingProgramming inin CC

»»AccessAccess toto memorymemory areasareas inin C:C: –”__zeropage char CommonVar;” –”__generic char *ptr;” –”__eeprom char *ptr;” »»AccessAccess toto hardwarehardware inin C:C: –”volatile char input @0x0020;” –”__no_init __flash char setting;” ¡Directly,Directly, usingusing CC keywords/functions:keywords/functions: –”__disable_interrupts()” –”__interrupt void Handler(void)”

29 November 2002 Embedded Computer Architecture 42 CustomCustom ProcessingProcessing ChipsChips

29 November 2002 Embedded Computer Architecture 43 TailoredTailored ChipsChips

»»ASICsASICs ¡ApplicationApplication--SpecificSpecific IntegratedIntegrated CircuitsCircuits ¡CPUCPU corecore (maybe(maybe modified)modified) ¡PeripheralsPeripherals ¡JustJust whatwhat isis neededneeded forfor aa specificspecific appapp »»CharacteristicsCharacteristics ¡ExpensiveExpensive toto developdevelop ¡LargeLarge seriesseries necessarynecessary toto paypay offoff ¡MostlyMostly forfor largelarge companiescompanies

29 November 2002 Embedded Computer Architecture 44 ASICASIC ComponentsComponents

»»IPIP BlocksBlocks ¡IntellectualIntellectual PropertyProperty ¡CompaniesCompanies sellsell piecespieces ofof hardwarehardware »»Examples:Examples: ¡CPUCPU CoresCores ¡MemoryMemory ¡BusesBuses ¡NetworkNetwork interfacesinterfaces ¡AcceleratorAccelerator circuitscircuits

29 November 2002 Embedded Computer Architecture 45 CPUCPU CoresCores

»»TheThe biggestbiggest “IP”“IP” businessbusiness »»BiggestBiggest players:players: ¡ARMARM (most(most importantimportant 3232--bitbit ever)ever) ¡MIPSMIPS (and(and itsits imitators)imitators) »»CrowdedCrowded fieldfield ¡NewNew companiescompanies appearappear monthlymonthly ¡““FablessFabless”” semiconductorsemiconductor companiescompanies ¡TunedTuned forfor aa particularparticular applicationapplication

29 November 2002 Embedded Computer Architecture 46 HardHard vsvs SoftSoft IPIP

»»HardHard IP:IP: ¡CustomerCustomer buysbuys aa corecore asas blackblack boxbox ¡AddsAdds otherother IPIP oror customcustom VHDLVHDL aroundaround ¡OnlyOnly usedused ffoorr processingprocessing corescores ¡Examples:Examples: ARMARM && MIPSMIPS »»SoftSoft IP:IP: ¡GetGet HDLHDL codecode forfor thethe componentcomponent ¡IntegrateIntegrate withwith ownown oror otherother codecode ¡Examples:Examples: ARCARC corecore

29 November 2002 Embedded Computer Architecture 47 SystemSystem--onon--aa--chipchip designdesign

»»EntireEntire productproduct On-chip bus onon aa chipchip Data DSP »»TypicalTypical design:design: mem

¡ BuyBuy IPIP Bluetooth ¡ CombineCombine GSM CPU ¡ DependsDepends onon busbus Radio standards:standards: AMBA;AMBA; CoreConnectCoreConnect LCD Code memory »»Future:Future: driver ¡ NetworksNetworks onon chipchip

29 November 2002 Embedded Computer Architecture 48 FPGAFPGA

»»FieldField ProgrammableProgrammable GateGate ArrayArray ¡ReconfigurableReconfigurable hardware:hardware: “soft“soft logic”logic” ¡“Program”“Program” isis circuitcircuit layoutlayout ¡1000s1000s toto 100100 000s000s ofof gatesgates availableavailable »»CompetitorCompetitor toto ASICsASICs ¡MoreMore expensiveexpensive perper unit,unit, butbut nono startstart--upup costcost forfor manufacturingmanufacturing ¡LessLess flexible,flexible, slightlyslightly slowerslower ¡PerfectPerfect forfor lowlow--volumevolume productsproducts

29 November 2002 Embedded Computer Architecture 49 FPGA/CPUFPGA/CPU HybridsHybrids

»»CombineCombine FPGAFPGA andand CPUCPU ¡UseUse FPGAFPGA partpart forfor hardwarehardware accelerationacceleration ofof importantimportant functionsfunctions ¡NotNot allall programsprograms suitablesuitable forfor FPGAFPGA »»SameSame benefitsbenefits asas CPUCPU onon ASICASIC ¡WithWith priceprice andand flexibilityflexibility ofof FPGAFPGA »»Examples:Examples: ¡ATMELATMEL FPSLIC:FPSLIC: AVRAVR plusplus 5000050000 gatesgates ¡XilinxXilinx VirtexVirtex IIII--Pro:Pro: 11--44 PPC405PPC405 corescores 29 November 2002 Embedded Computer Architecture 50 PowerPower AspectsAspects

29 November 2002 Embedded Computer Architecture 51 WhyWhy isis PowerPower Important?Important?

»»BatteryBattery--poweredpowered applicationsapplications ¡LongerLonger batterybattery lifelife isis veryvery desirabledesirable »»AutomotiveAutomotive applicationsapplications ¡ElectronicsElectronics consumesconsumes upup 30%30% ofof fuel!fuel! »»LowLow--maintenancemaintenance applicationsapplications ¡Power=heat=cooling=movingPower=heat=cooling=moving partsparts »»ServerServer farmsfarms ¡CoolingCooling && electricityelectricity areare bigbig costscosts 29 November 2002 Embedded Computer Architecture 52 CMOSCMOS PowerPower

»»PowerPower == area*clock*voltagearea*clock*voltage22 ¡Area:Area: transistorstransistors thatthat areare switchingswitching ¡Clock:Clock: speedspeed ofof switchingswitching ¡:Voltage: toto keepkeep runningrunning »»SaveSave powerpower byby minimizingminimizing ¡ClockClock speedspeed ¡ActiveActive areaarea ¡FeedFeed voltagevoltage

29 November 2002 Embedded Computer Architecture 53 AreaArea ReductionReduction

»»SimplerSimpler chipschips useuse lessless powerpower ¡88--bitbit CPUsCPUs ¡SimpleSimple RISCRISC likelike ARMARM ¡VLIWVLIW insteadinstead ofof superscalarsuperscalar »»TurnTurn offoff inactiveinactive unitsunits ¡PipelinesPipelines thatthat areare notnot usedused ¡OnOn--chipchip memorymemory andand cachescaches ¡Sleep/Nap/IdleSleep/Nap/Idle modesmodes onon CPUCPU »»RemoveRemove unnecessaryunnecessary featuresfeatures 29 November 2002 Embedded Computer Architecture 54 ClockClock SpeedsSpeeds

»»ClockClock andand voltagevoltage relatedrelated ¡HigherHigher operatingoperating frequencyfrequency requiresrequires higherhigher voltagevoltage »»UseUse lowerlower clockclock speedsspeeds ¡ReduceReduce speedspeed untiluntil appapp barelybarely worksworks »»UseUse moremore processorsprocessors ¡1/21/2 speedspeed == 1/41/4 powerpower ¡22 CPUsCPUs @@ 100100 MhzMhz == 11 CPUCPU @@ 200200 MhzMhz,, butbut requiresrequires halfhalf thethe powerpower

29 November 2002 Embedded Computer Architecture 55 DynamicDynamic VoltageVoltage ScalingScaling

»»AdjustAdjust CPUCPU speedspeed toto workloadworkload ¡ReduceReduce operatingoperating voltagevoltage whenwhen clockclock speedspeed isis reducedreduced ¡CubicCubic powerpower savingssavings possible!possible! ¡AnalyzeAnalyze loadload toto determinedetermine speedspeed ¡MoreMore advancedadvanced thanthan sleepsleep modesmodes »»SpecialSpecial hardwarehardware required:required: ¡TransmetaTransmeta CrusoeCrusoe waswas aa pioneerpioneer ¡IntelIntel XscaleXscale,, gettinggetting commoncommon

29 November 2002 Embedded Computer Architecture 56 Power,Power, VoltageVoltage,, FrequencyFrequency

1800 »»SamsungSamsung HallaHalla Voltage (mV) 1600 ¡ ARMARM 1020E1020E corecore Power (mW) 1400 ¡ 66--stagestage pipelinepipeline (!)(!) 1200 ¡ 0.130.13 umum processprocess 1000 ¡ Clock:Clock: 800 400400 MhzMhz toto 1.21.2 GhzGhz 600 400

200 3x clock freq, 0 9x power! 400 600 800

1000 1200 (source: Microprocessor Report, Oct 16, 2002) 29 November 2002 Embedded Computer Architecture 57 OtherOther FactorsFactors

»»ManufacturingManufacturing process:process: ¡SmallerSmaller features=lowerfeatures=lower powerpower –(0.13 micron mobile PIII, for example) ¡TweakTweak processprocess forfor lowerlower powerpower »»DevelopmentDevelopment effort:effort: ¡TweakTweak thethe lowlow--levellevel chipchip layoutlayout –(Classic StrongARM) –“ programming” ¡CannotCannot bebe synthesizedsynthesized efficientlyefficiently –= Not possible for IP blocks 29 November 2002 Embedded Computer Architecture 58 SystemSystem IssueIssue

»»MuchMuch moremore thanthan CPUCPU ¡Displays,Displays, LEDsLEDs,, …… ¡Memory,Memory, Disks,Disks, …… ¡RadioRadio interfaces,interfaces, Networks,Networks, …… »»TurnTurn offoff unusedunused peripheralsperipherals ¡GSMGSM phones:phones: 300300 hourshours standbystandby vs.vs. 6060 minutesminutes talktalk timetime ¡Ericsson:Ericsson: reducereduce frequencyfrequency ofof LEDLED blinkblink

29 November 2002 Embedded Computer Architecture 59 MemoryMemory && PowerPower

»»LargeLarge area=higharea=high power:power: ¡UseUse smallestsmallest possiblepossible memorymemory »»TalkingTalking toto DRAMDRAM isis expensiveexpensive ¡UseUse onon--chipchip SRAM/ROMSRAM/ROM ¡ReduceReduce externalexternal memorymemory activityactivity ¡UseUse cachescaches toto keepkeep activityactivity internalinternal »»UseUse energyenergy--efficientefficient RAMsRAMs ¡LowLow--powerpower DRAMDRAM isis coming!coming! ¡RAMBUSRAMBUS isis horriblehorrible 29 November 2002 Embedded Computer Architecture 60 MemoryMemory && PowerPower

»»PowerPower forfor aa LOADLOAD instructioninstruction onon anan ARM7ARM7 developmentdevelopment boardboard code data energy ratio memory memory (nJ) off-chip off-chip 115.8 100% off-chip on-chip 51.6 44.6% on-chip off-chip 76.5 66.1% on-chip on-chip 16.4 14.2% Source: Compilation Techniques for Energy-, Code-Size-, and Run-Time Efficient Embedded (Marwedel et al 2001)

29 November 2002 Embedded Computer Architecture 61 ClosingClosing RemarksRemarks

29 November 2002 Embedded Computer Architecture 62 ThisThis isis wherewhere thethe actionaction is!is!

»»FragmentedFragmented marketmarket ¡NoNo dominantdominant bigbig playerplayer likelike PCsPCs ¡IncrediblyIncredibly widewide spanspan ofof productsproducts »»TailorTailor--made,made, notnot massmass--producedproduced ¡EverybodyEverybody searchessearches forfor perfectperfect fitfit »»HighHigh innovationinnovation inin compcomp archarch »»LargeLarge numbernumber ofof newnew playersplayers

29 November 2002 Embedded Computer Architecture 63 RoomRoom forfor InnovationInnovation

»»ControlControl plane:plane: ¡StabilityStability isis keykey ¡RTOS,RTOS, legacy,legacy, compatibilitycompatibility »»DataData plane:plane: ¡MoveMove oror processprocess datadata ¡PerformancePerformance isis keykey ¡MoreMore configurable,configurable, moremore customizedcustomized ¡=Lots=Lots ofof spacespace forfor innovativeinnovative designdesign

29 November 2002 Embedded Computer Architecture 64 MoreMore ReadingReading

»»GeneralGeneral newsnews andand JackJack GanssleGanssle atat www.embedded.comwww.embedded.com »»GeneralGeneral news:news: www.eetimes.comwww.eetimes.com »»CompComp arch:arch: www.www.extremetechextremetech.com.com »»MyMy stuffstuff atat useruser.it.it..uuuu..sese/~/~jakobjakob »»IARIAR whitepaperswhitepapers atat www.iar.comwww.iar.com

29 November 2002 Embedded Computer Architecture 65