CN101881995B - Hierarchical classification power consumption measurement method for ARM instruction set - Google Patents
Hierarchical classification power consumption measurement method for ARM instruction set Download PDFInfo
- Publication number
- CN101881995B CN101881995B CN2010101917931A CN201010191793A CN101881995B CN 101881995 B CN101881995 B CN 101881995B CN 2010101917931 A CN2010101917931 A CN 2010101917931A CN 201010191793 A CN201010191793 A CN 201010191793A CN 101881995 B CN101881995 B CN 101881995B
- Authority
- CN
- China
- Prior art keywords
- instruction
- power consumption
- class
- addressing
- cycle
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The invention discloses a hierarchical classification power consumption measurement method, in particular a hierarchical classification power consumption measurement method for an ARM instruction set. The method comprises: firstly, dividing the ARM instruction set into four classes according to the type of instruction; secondly, classifying the instructions in addressing modes; and finally, performing classification according to the operands of different addressing modes. By performing an experiment on an ARM7TDMI processor, an instruction set power consumption simulator HMSim, according to a test result, is perfected to make a simulative test environment closer to an actual hardware environment; and thus, a more convenient and accurate test environment is provided for the measurement of the power consumption of embedded software. When the hierarchical classification power consumption measurement method provided by the method is used on the power consumption simulator HMSim, the error between the power consumption of an application running on the HMSim and the power consumption of the application running in an actual hardware environment is kept within 10 percent.
Description
Affiliated technical field
The present invention relates to the embedded software power consumption field of measuring technique, especially relate to a kind of hierarchical classification power consumption measurement method at the ARM instruction set.
Background technology
At present, embedded system has obtained in fields such as information household appliances, Based Intelligent Control, military electronics using widely.By the end of the year 2008, the recoverable amount of whole world embedded device has surpassed 3,000,000,000, and quantity continues to be the impetus of quick growth, and annual power consumption reaches more than 1,000 hundred million kilowatt hours.Advocate under the background of " low-carbon economy " in the whole world, the power consumption of embedded system is a hot issue that causes that day by day people pay close attention to, and becomes the important consideration factor of Embedded System Design.
HMSim can obtain the power consumption number of embedded software flexibly, easily as a kind of high-precision instruction-level embedded software power consumption emulator.In the power consumption statistical model of HMSim, wall scroll assembly instruction and instruct the right measurement of power loss to be the basis that makes up power consumption model, its accurate measurement result has important supporting role to the power consumption analysis of high-level language programs (as C, C++) with optimizing.Because the diversity of ARM instruction set,, therefore, the power consumption of ARM instruction set analyzed with measurement there is certain degree of difficulty as 256 instructions, multiple addressing mode, multiple several immediately, the influence of streamline and the uncertainty of instruction cycles etc.
1994, people such as Tiwari proposed key concept that software power consumption is analyzed, and have set up basic instruction set power consumption model.2002, T K Tan was divided into 32 classes at instruction set measurement of power loss problem with instruction set, recorded the reference current value of each class instruction respectively, with its benchmark as statistics instruction power consumption.But in the power consumption statistical model, the phase recency according to value is divided into four classes with 32 reference current values again, adds up the power consumption of corresponding sort instructions with this four classes reference value.As can be seen, the addressing mode of instruction set, immediately count types, instruction to and streamline there is bigger influence in the power consumption of instruction, the reference current value of instruction set is divided into four classes seems accurate inadequately, error is bigger.
Summary of the invention
This paper is intended to propose a kind of hierarchical classification power consumption measurement method at the ARM instruction set.
The step that the present invention solves technical scheme that its technical barrier adopts is as follows:
1) at first, the nine classes instruction with the ARM instruction set reduces the data processing class, storage loads exchange class, status register visit and jump class, coprocessor instruction class four classes;
2) secondly, according to instruction addressing mode to four classes instructions secondary classification, data processing class instruction main employing immediate addressing and register addressing, plot indexed addressing and multiregister addressing are mainly adopted in storage loading and the instruction of exchange class, status register is visited and the main employing of jump class instruction relative addressing;
3) then, according to counting type immediately to addressing mode three subseries, counting type immediately will influence immediate addressing and register addressing, count type immediately and can be divided into four classes, each class is identical to the influence of instruction power consumption and periodicity, therefore, adopts the equivalence class division methods to measure;
4) behind above-mentioned category measurement, the multi-form current value of each instruction is done weighted mean, be the current reference value of this instruction;
5) obtain to use following formula computations power consumption after the current reference value of instruction:
Wherein, a represents the factor of influence of three class pipeline to instruction cycles, I
InstrThe reference current value of expression individual instructions, i.e. individual instructions required current value in 1 clock period, V represents the voltage of arm processor, f represents the frequency of arm processor, C
CycleThe required clock periodicity of this instruction, D are carried out in expression
IjPresentation directives is to power consumption;
6) C in the step 5) formula
CycleCalculate according to following formula:
C
cycle=k
1+2k
2+k
3+k
4
Wherein, coefficient k
1, k
2, k
3, k
4>=0 is integer, and an instruction required intercycle (I), discrete cycle (N), continuous cycle (S) and the number of four kinds of memory cycles of coprocessor register transmission cycle (C) are carried out in expression respectively;
The present invention compares with background technology, and the beneficial effect that has is:
1) accuracy: the present invention uses the hierarchical classification power consumption measurement method at the ARM instruction set, compares the simple classification measuring method of using with other people, and the power consumption accuracy of predicting has obtained bigger lifting, and predicated error is in 10%.
2) practicality: can be used for estimating more accurately the power consumption number when software algorithm is moved on the specific objective plate, lay solid data basis for carrying out corresponding optimised power consumption research-and-development activity.
Description of drawings
Fig. 1 is ARM instruction set hierarchical classification figure of the present invention.
Embodiment
The present invention is further illustrated below in conjunction with accompanying drawing and example.
This example is an example with Winbond W90P710 ARM7TDMI processor,
1) as shown in Figure 1, at first, with the instruction of nine classes of ARM instruction set reduce the data processing class, storage loads exchange class, status register visit and jump class, coprocessor instruction class four classes;
2) secondly, according to instruction addressing mode to four classes instructions secondary classification, data processing class instruction main employing immediate addressing and register addressing, plot indexed addressing and multiregister addressing are mainly adopted in storage loading and the instruction of exchange class, status register is visited and the main employing of jump class instruction relative addressing;
3) then, according to counting type immediately to addressing mode three subseries, counting type immediately will influence immediate addressing and register addressing, count type immediately and can be divided into four classes, each class is identical to the influence of instruction power consumption and periodicity, therefore, adopts the equivalence class division methods to measure;
4) behind above-mentioned category measurement, the multi-form current value of each instruction is done weighted mean, be the current reference value I of this instruction
Instr
5) according to the instruction current reference value that obtains, the power consumption of individual instructions can be calculated according to following formula:
Wherein, a=0.47 represents the factor of influence of three class pipeline to instruction cycles, I
InstrThe reference current value of expression individual instructions, i.e. individual instructions required current value in 1 clock period, V=1.788V represents the voltage of ARM7TDMI processor, f=80MHz represents the frequency of ARM7TDMI processor, C
CycleThe required clock periodicity of this instruction is carried out in expression.
6) individual instructions is carried out required C
CycleNumber is determined by following formula:
C
cycle=k
1+2k
2+k
3+k
4=1+2×1+1+0=6
Wherein, coefficient k
1, k
2, k
3, k
4>=0 is integer, represents intercycle (I) in the instruction, discrete cycle (N), continuous cycle (S) and the number of four kinds of memory cycles of coprocessor register transmission cycle (C) respectively.
As carry out NOP instruction and only need 1 continuous cycle, i.e. C
Cycle-nop=k
1+ 2k
2+ k
3+ k
4=0+2 * 0+1+0=1, carrying out a SWP instruction needs 1 continuous cycle, 2 discrete cycles, 1 intercycle, i.e. C
Cycle-swp=k
1+ 2k
2+ k
3+ k
4=1+2 * 1+1+0=6.
7) adopt the hierarchical classification power consumption measurement method measure the current reference value of ARM instruction, according to instruction cycles computing formula and as shown in the table according to the result of calculation of instruction power consumption calculation formula.
The reference current value I of chart 1ARM instruction set
Instr, instruction cycles C
CycleWith power consumption number E
Instr
Claims (1)
1. hierarchical classification power consumption measurement method at the ARM instruction set is characterized in that the step of this method is as follows:
1) at first, the nine classes instruction with the ARM instruction set reduces the data processing class, storage loads exchange class, status register visit and jump class, coprocessor instruction class four classes;
2) secondly, according to instruction addressing mode to four classes instructions secondary classification, data processing class instruction main employing immediate addressing and register addressing, storage is loaded the instruction of exchange class mainly adopt plot indexed addressing and multiregister addressing, to status register visit and the main employing of jump class instruction relative addressing;
3) then, according to counting type immediately to addressing mode three subseries, counting type immediately will influence immediate addressing and register addressing, count type immediately and can be divided into four classes, each class is identical to the influence of instruction power consumption and periodicity, therefore, adopts the equivalence class division methods to measure;
4) behind above-mentioned category measurement, the multi-form current value of each instruction is done weighted mean, be the current reference value of this instruction;
5) obtain to use following formula computations power consumption after the current reference value of instruction:
Wherein, a represents the factor of influence of three class pipeline to instruction cycles, I
InstrThe reference current value of expression individual instructions, i.e. individual instructions required current value in 1 clock period, V represents the voltage of arm processor, f represents the frequency of arm processor, C
CycleThe required clock periodicity of this instruction, D are carried out in expression
IjPresentation directives is to power consumption;
6) C in the step 5) formula
CycleCalculate according to following formula:
C
cycle=k
1+2k
2+k
3+k
4
Wherein, coefficient k
1, k
2, k
3, k
4>=0 is integer, and an instruction required intercycle (I), discrete cycle (N), continuous cycle (S) and the number of four kinds of memory cycles of coprocessor register transmission cycle (C) are carried out in expression respectively.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101917931A CN101881995B (en) | 2010-06-04 | 2010-06-04 | Hierarchical classification power consumption measurement method for ARM instruction set |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN2010101917931A CN101881995B (en) | 2010-06-04 | 2010-06-04 | Hierarchical classification power consumption measurement method for ARM instruction set |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101881995A CN101881995A (en) | 2010-11-10 |
CN101881995B true CN101881995B (en) | 2011-11-09 |
Family
ID=43054026
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2010101917931A Expired - Fee Related CN101881995B (en) | 2010-06-04 | 2010-06-04 | Hierarchical classification power consumption measurement method for ARM instruction set |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101881995B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102073763B (en) * | 2010-12-31 | 2012-09-05 | 清华大学 | FPGA development board-based full-system simulating and accelerating method |
CN103106136B (en) * | 2011-11-14 | 2016-06-29 | 成都信息工程学院 | A kind of software dynamic energy consumption statistical method based on x86 instruction set |
CN102750222A (en) * | 2012-06-04 | 2012-10-24 | 四川大学 | Method for estimating energy consumption of embedded software based on C programming language |
CN110688160B (en) * | 2019-09-04 | 2021-11-19 | 苏州浪潮智能科技有限公司 | Instruction pipeline processing method, system, equipment and computer storage medium |
CN112288428A (en) * | 2020-09-24 | 2021-01-29 | 咪咕文化科技有限公司 | Simulator detection method and device, electronic equipment and storage medium |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
AU2008328515B2 (en) * | 2007-11-20 | 2014-07-24 | National Ict Australia Limited | Multi language software code analysis |
CN101609411B (en) * | 2009-07-27 | 2013-01-09 | 四川大学 | Embedded software power consumption BP neural network modeling method based on complexity |
-
2010
- 2010-06-04 CN CN2010101917931A patent/CN101881995B/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
CN101881995A (en) | 2010-11-10 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Gallagher et al. | The suitability of machine learning to minimise uncertainty in the measurement and verification of energy savings | |
Lively et al. | Power-aware predictive models of hybrid (MPI/OpenMP) scientific applications on multicore systems | |
Xiong et al. | Research on an online identification algorithm for a thevenin battery model by an experimental approach | |
CN101881995B (en) | Hierarchical classification power consumption measurement method for ARM instruction set | |
Laopoulos et al. | Measurement of current variations for the estimation of software-related power consumption [embedded processing circuits] | |
CN105243068A (en) | Database system query method, server and energy consumption test system | |
Zhang et al. | Deadline-aware task scheduling for solar-powered nonvolatile sensor nodes with global energy migration | |
Khan et al. | Software optimization for performance, energy, and thermal distribution: Initial case studies | |
CN104541173A (en) | Method and apparatus for modelling power consumption of integrated circuit | |
Rai et al. | Power agnostic technique for efficient temperature estimation of multicore embedded systems | |
CN103293424A (en) | Data center power usage efficiency (PUE) determination method | |
Kim et al. | System-level online power estimation using an on-chip bus performance monitoring unit | |
Zhang et al. | PANDA: Architecture-level power evaluation by unifying analytical and machine learning solutions | |
Varma et al. | Instruction-level power dissipation in the Intel XScale embedded microprocessor | |
CN100356341C (en) | Method for estimating power consumption when embedded software running based on simulator | |
Cho et al. | System-level power estimation using an on-chip bus performance monitoring unit | |
CN102880785A (en) | Method for estimating transmission energy consumption of source code grade data directed towards GPU program | |
CN101894067B (en) | ARM processor-based embedded software power consumption statistical method | |
Pruitt et al. | Preliminary investigation of mobile system features potentially relevant to HPC | |
Darwish et al. | Transaction level power modeling (TLPM) methodology | |
Kulkarni et al. | Instruction Level Power Consumption Estimation–Issues and Review | |
Huowen et al. | Study on evaluation method of energy consumption in computer system | |
Thrane et al. | Quantitative simulations of weighted transition systems | |
Almeida et al. | Analytical energy models for mpi communications on a sandy-bridge architecture | |
Nikolaidis et al. | Developing an environment for embedded software energy estimation |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
C17 | Cessation of patent right | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20111109 Termination date: 20130604 |