Chungbuk National University Software Engineering Lab.
2 Introduction UML Model-Based Energy Estimation Experiment Conclusion
Importance of Power Analysis In portable embedded system 3 There are limitations of resources such as Memory, CPU, Battery, etc Specially, these systems are operated with limited energy source (a battery) The necessity of the research for low power software is issued
Power analysis efficiency at abstraction levels [T. K. Tan, 2003] Advantages of model-based software power analysis Higher power saving Fast estimation time 4
Power Estimation of Embedded Software Our motivation Seamless process support in energy-efficient embedded software development Low feedback cost Fast estimation 5 Code-Based Power Estimation Model-Based Power EstimationRequirements SW Analysis / Design Implementation System Integration / Testing Target installation HW Configuration
Proposed Estimation Process 6 UML design models Transform UML models to CFG EBU detection Power consumption of the EBU Accumulation of the consumption Energy Library No more EBU in CFG Estimated energy consumption
7 DiagramsEBUs SD Message (send, receive), MessageSort (SynchCall, AsynchCall, Signal), InteractionOperator (alt, opt, loop, par) IOD Fork, Join (wait), Invocation (Create), InterruptableActivityRegion AL Bitwise Operator (+, -, *, /, %, =, etc.), Function Operator (read, write, malloc, etc.)
Building Energy Library (2/4) VI (Virtual Instruction) [Bammie, 2000] A set of generalized instructions Defined to estimate power consumption caused by a program execution 8 TypesInstructions VPI load, store, add, sub, call divide, call module, mult, compare, convertType, branch, bitNOT, bitAND, bitOR, bitXOR, bitShiftLeft, bitShiftRight VSF Process Managerfork(), waitpid(), wait(), signal() IPC msgsnd(), msgrcv(), msgget(), msgctl(), semget(), semctl(), semop(), pipe(), pipe open(), pipe write() File Systemfileopen(), fileclose(), fileread(), filewrite() Memory Managershmget(), shmat(), shmdt(), shmctl()
Building Energy Library (3/4) Some of energy profiling for the VI 9 VPITypeEnergy(nJ)VSFParametersMacro-model (nJ) load char14.1fork() short28.1waitpid() int13.0wait() float13.0signal() double13.7File open() store char13.2File close() short26.4File read()χ bytes5.1χ int12.5File write()χ bytes5.6χ float12.8shmget() double13.2shmat() c.f :
Building Energy Library (4/4) Mapping VIs into EBUs An EBU can be mapped with 1 or more VIs –read mapped with file read() –Sync mapped with store and branch 10 VPITypeEnergy(nJ) store char short int float double branchn/a VSFTypeEnergy(nJ) file readx bytes5.1x ………
Proposed Estimation Process (revisited) 11 UML design models Transform UML models to CFG EBU detection Power consumption of the EBU Accumulation of the consumption Energy Library No more EBU in CFG Estimated energy consumption
Transform UML Model to Control Flow Graph (1/2) The reasons of transformation CFG has strong expressiveness for behavioral sequence of software function Using CFG is easier to identify power consuming factors than UML models directly 12 Transform :P:Q:R m1 m2 m3 sd A n1n2 n3n4 n5n6 CFG al1 n23
Transform UML Model to Control Flow Graph (2/2) A node structure of CFG 13
EBU Detection 14
Power Consumption of EBU If detected an EBU, the simulator calculates energy consumption of the EBU by using the energy values of mapped VIs from energy library Total Energy Consumption Total energy of model TEC is 15
Issues of our experiment How about accuracy How much speed-up How to apply this technique Environments 16 ESUML-EA Power analysis tool we developed with Java Eclipse 3.2 EMF, GEF, and RCP are used plug-ins EMSIM 2.0 Code-based power analysis tool developed by T. K. Tan It aims platform that configured with StrongArm on SA1100 architecture with Embedded Linux
Accuracy of model-based analysis (1/2) UML sequence diagram for Huffman Encoding 17
Accuracy of model-based analysis (2/2) App. 1 : Data retrieval App. 2 : Shortest path selection App. 3 : Image translation App. 4 : Encoding (Huffman code) 18 Target M odule Input Data (Bytes) Estimated Energy Consumption (nJ) Deviation (% ) Code-basedModel-based App App App App
Elapsed time for analysis (1/2) Comparison of the elapsed time for 4 applications 19
Elapsed time for analysis (2/2) Comparison of the elapsed time by data size in App. 4 20
Application of model-based analysis result Results are provided by unit of diagrams or objects Therefore, We could identify which diagram or object consumes a lot of power from the report 21
Proposed model-based power consumption analysis technique Power analysis by CFG generation from UML design models EBU elicitation from UML models Energy Library for those EBUs Benefits Early feedback Fast estimation Seamless process support in energy-efficient embedded software development Future work Power consumption analysis for MPSoC architecture using current proposed technique 22
23