CN116484165A - Method and device for calculating single running average energy consumption of logic gate - Google Patents

Method and device for calculating single running average energy consumption of logic gate Download PDF

Info

Publication number
CN116484165A
CN116484165A CN202310484411.1A CN202310484411A CN116484165A CN 116484165 A CN116484165 A CN 116484165A CN 202310484411 A CN202310484411 A CN 202310484411A CN 116484165 A CN116484165 A CN 116484165A
Authority
CN
China
Prior art keywords
logic gate
input
input state
energy consumption
state set
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.)
Pending
Application number
CN202310484411.1A
Other languages
Chinese (zh)
Inventor
邝家月
王宇庭
毛江
张宸
刘畅
任家朋
沈阳武
何立夫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Three Gorges Corp
Original Assignee
China Three Gorges Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by China Three Gorges Corp filed Critical China Three Gorges Corp
Priority to CN202310484411.1A priority Critical patent/CN116484165A/en
Publication of CN116484165A publication Critical patent/CN116484165A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • G06F17/18Complex mathematical operations for evaluating statistical data, e.g. average values, frequency distributions, probability functions, regression analysis
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Operations Research (AREA)
  • Probability & Statistics with Applications (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Algebra (AREA)
  • Evolutionary Biology (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Complex Calculations (AREA)

Abstract

The invention discloses a method and a device for calculating single-operation average energy consumption of a logic gate, which are combined with the distribution characteristics of an input data sequence and the relations between different input states of the logic gate and energy consumption, can obtain the calculation method for calculating the single-operation average energy consumption of the logic gate, are not influenced by the change of the input data sequence, can update the single-operation average energy consumption of the logic gate in real time only by counting the distribution characteristics of the data sequence in real time, are closer to the physical principle behind the logic operation than the method for directly measuring the energy consumption, do not relate to the physical factors such as the process, the material and the like of the logic gate, and greatly simplify the flow and the step for analyzing the single-operation average energy consumption of the logic gate. Therefore, by implementing the invention, the result can be accurately calculated no matter what the static energy consumption ratio is.

Description

Method and device for calculating single running average energy consumption of logic gate
Technical Field
The invention relates to the technical field of energy consumption calculation, in particular to a method and a device for calculating single running average energy consumption of a logic gate.
Background
In the prior art, the average energy consumption of a single operation of a logic gate is often obtained by adopting an actual measurement averaging method. The method is insensitive to probability distribution of the input data sequence, and when the statistical characteristics of the data sequence input by the logic gate change, the energy consumption of the logic gate during operation also changes. Meanwhile, as the size of the transistor is continuously reduced, the static energy consumption caused by leakage current in the logic gate is gradually higher than the dynamic energy consumption caused by circuit inversion and internal short circuit, and the method for calculating the energy consumption of the logic gate according to the number of times of transistor inversion cannot accurately calculate the whole energy consumption of the logic gate.
Disclosure of Invention
In view of the above, the embodiments of the present invention provide a method and an apparatus for calculating single running average energy consumption of a logic gate, so as to solve the technical problem in the prior art that the method for calculating the energy consumption of the logic gate according to the number of times of transistor turning cannot accurately calculate the overall energy consumption of the logic gate.
The technical scheme provided by the invention is as follows:
in a first aspect, an embodiment of the present invention provides a method for calculating a single-run average energy consumption of a logic gate, where the method for calculating the single-run average energy consumption of the logic gate includes: acquiring an input data sequence of a logic gate to be calculated, and acquiring a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment based on the input data sequence, wherein the second moment is the next moment adjacent to the first moment; determining a first relation based on the first input state set and the second input state set, wherein the first relation reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption; determining a second relational expression based on the input data sequence, the first input state set and the second input state set, the second relational expression reflecting a transition probability of an input state of the input data sequence; and obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation.
With reference to the first aspect, in a possible implementation manner of the first aspect, determining a first relational expression based on the first set of input states and the second set of input states includes: determining at least one energy consumption generated by the logic gate to be calculated in a single operation time based on the first input state set and the second input state set; the first relation is determined based on each of the energy consumptions.
With reference to the first aspect, in another possible implementation manner of the first aspect, before determining the second relation based on the input data sequence, the first input state set and the second input state set, the method further includes: and acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the input high level of each input data in the input state of the first moment and the second moment respectively.
With reference to the first aspect, in a further possible implementation manner of the first aspect, determining a second relational expression based on the input data sequence, the first input state set and the second input state set includes: obtaining at least one input state transition probability of the logic gate to be calculated through a preset second calculation method based on the first input state set, the second input state set, each preset probability value and each numerical value; the second relation is determined based on each of the input state transition probabilities.
In a second aspect, an embodiment of the present invention provides an apparatus for calculating a single-run average energy consumption of a logic gate, where the apparatus for calculating a single-run average energy consumption of a logic gate includes: the logic gate control module is used for obtaining an input data sequence of a logic gate to be calculated, and obtaining a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment based on the input data sequence, wherein the second moment is the next moment adjacent to the first moment; the first determining module is used for determining a first relational expression based on the first input state set and the second input state set, wherein the first relational expression reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption; a second determining module configured to determine a second relational expression based on the input data sequence, the first input state set, and the second input state set, the second relational expression reflecting a transition probability of an input state of the input data sequence; and the calculation module is used for obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation.
With reference to the second aspect, in a possible implementation manner of the second aspect, the first determining module includes: a first determining submodule, configured to determine at least one energy consumption generated by the logic gate to be calculated at a single operation time based on the first input state set and the second input state set; and a second determining sub-module for determining the first relation based on each of the energy consumptions.
With reference to the second aspect, in another possible implementation manner of the second aspect, the apparatus further includes: the first acquisition module is used for acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the high level input by each input data in the input state at the first moment and the second moment respectively.
With reference to the second aspect, in a further possible implementation manner of the second aspect, the second determining module includes: the computing sub-module is used for obtaining at least one input state transition probability of the logic gate to be computed through a preset second computing method based on the first input state set, the second input state set, each preset probability value and each numerical value; and a third determining sub-module for determining the second relation based on each of the input state transition probabilities.
In a third aspect, embodiments of the present invention provide a computer readable storage medium storing a computer program, where the computer program is configured to cause the computer to perform a method for calculating a single running average energy consumption of a logic gate according to any one of the first aspect and the first aspect of the embodiments of the present invention.
In a fourth aspect, an embodiment of the present invention provides an electronic device, including: the memory is in communication connection with the processor, the memory stores a computer program, and the processor executes the computer program to execute the method for calculating the single-run average energy consumption of the logic gate according to the first aspect of the embodiment of the present invention.
The technical scheme provided by the invention has the following effects:
according to the method for calculating the single running average energy consumption of the logic gate, provided by the embodiment of the invention, an input data sequence of the logic gate to be calculated is obtained, and a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment are obtained based on the input data sequence, wherein the second moment is the next moment adjacent to the first moment; determining a first relation based on the first input state set and the second input state set, wherein the first relation reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption; determining a second relational expression based on the input data sequence, the first input state set and the second input state set, the second relational expression reflecting a transition probability of an input state of the input data sequence; and obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation. The invention combines the distribution characteristics of the input data sequence with the relations between the conversion of different input states of the logic gate and the energy consumption, can obtain the calculation method of the single operation average energy consumption of the logic gate, is not influenced by the change of the input data sequence, can update the single operation average energy consumption of the logic gate in real time by only counting the distribution characteristics of the data sequence in real time, is closer to the physical principle behind the logic operation compared with the method of directly measuring the energy consumption, does not relate to the physical factors such as the process, the material and the like of the logic gate, and greatly simplifies the process and the step of analyzing the single operation average energy consumption of the logic gate. Therefore, by implementing the invention, the result can be accurately calculated no matter what the static energy consumption ratio is.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are needed in the description of the embodiments or the prior art will be briefly described, and it is obvious that the drawings in the description below are some embodiments of the present invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method of calculating a single running average energy consumption of a logic gate according to an embodiment of the present invention;
FIG. 2 is a block diagram of an apparatus for calculating a single running average energy consumption of a logic gate according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a computer-readable storage medium provided according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present invention and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the invention described herein may be implemented in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
The power consumption of the logic gate consists of dynamic power consumption and static power consumption, wherein the dynamic power consumption is generated by the turnover of a transistor in the logic gate, and the power of the dynamic power consumption can be expressed as the following relation (1):
wherein: alpha represents an activity factor, which is the probability that the logic gate output jumps from 0 to 1, or from 1 to 0; c represents the load capacitance of the logic gate; v represents the operating voltage of the logic gate; f represents the clock frequency.
The transistor toggles when the output of the logic gate at the previous input is opposite to the output at the current input. For example, for a NAND gate, the previous input is 00, and when the current input is 11, the NAND gate output transitions from 1 to 0. Thus, it is known that the dynamic energy consumption of a logic gate is not only related to the current input but also to the previous input.
Further, the static power consumption of the logic gate is generated by the transistor leakage current, and the leakage current is only related to the current input of the logic gate. The static energy consumption ratio of the logic gate with the gate size of 7nm of the transistor is over 40%. Considering that the gate size of the transistor is continuously reduced in the future, the static energy consumption ratio of the logic gate is gradually increased, and the traditional method for calculating the dynamic energy consumption according to the turnover rate cannot accurately calculate the whole energy consumption of the logic gate under the condition that the dynamic energy consumption is dominant.
Accordingly, an embodiment of the present invention provides a method for calculating a single running average energy consumption of a logic gate, as shown in fig. 1, including the following steps:
step 101: and acquiring a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment based on the input data sequence.
Wherein, for any N-input logic gate, the number of the input data sequence is 1,2, N;
the second time is the next time adjacent to the first time, namely the first input state set is the previous input state set of the logic gate to be calculated, and the second input state set is the current input state set of the logic gate to be calculated
Specifically, the number of all possible input states of the logic gate to be calculated, i.e. the input state k in the first set of input states i I=1, 2,..the number of m, or the second set of input states inputs state k j J=1, 2, the number of m is as follows: m=2 n
Step 102: a first relationship is determined based on the first set of input states and the second set of input states.
The first relation reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption.
In particular, the power consumption of the logic gate is not only related to the current input but also to the previous input. Therefore, by combining the first input state set and the second input state set, the corresponding relation between the input state of the logic gate to be calculated and the energy consumption can be obtained.
Step 103: a second relationship is determined based on the input data sequence, the first set of input states, and the second set of input states.
Wherein the second relation reflects a transition probability of an input state of the input data sequence.
Specifically, in combination with the input data sequence, the first input state set and the second input state set, a transition probability corresponding to an input state of the logic gate to be calculated may be obtained, and further, the transition probability of the input state may reflect a distribution characteristic of the input data sequence.
Step 104: and obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation.
Specifically, a calculation relation of the average energy consumption of the logic gate in a single operation time can be obtained according to the first relation and the second relation, and further, the average energy consumption of the logic gate to be calculated in the single operation time can be obtained according to the calculation relation.
The method for calculating the single-operation average energy consumption of the logic gate, provided by the embodiment of the invention, combines the distribution characteristics of the input data sequences with the relations between the different input states of the logic gate and the energy consumption, can obtain the calculation method of the single-operation average energy consumption of the logic gate, is not influenced by the change of the input data sequences, can update the single-operation average energy consumption of the logic gate in real time only by counting the distribution characteristics of the data sequences in real time, is closer to the physical principle behind the logic operation compared with the method for directly measuring the energy consumption, does not relate to the physical factors such as the process, the material and the like of the logic gate, and greatly simplifies the flow and the step for analyzing the single-operation average energy consumption of the logic gate. Therefore, by implementing the invention, the result can be accurately calculated no matter what the static energy consumption ratio is.
As an alternative implementation of the embodiment of the present invention, step 102 includes: determining at least one energy consumption generated by the logic gate to be calculated in a single operation time based on the first input state set and the second input state set; the first relation is determined based on each of the energy consumptions.
Specifically, according to the description of step 102, the first relation reflects the relation between the input state of the logic gate to be calculated and the energy consumption, that is, the first relation is shown in the following relation (2):
wherein the elements in the matrixRepresenting the previous input of the logic gate to be calculated as k i Current input k j If so, the logic gate consumes energy generated in a single operation time.
As an optional implementation manner of the embodiment of the present invention, before step 103, the method further includes:
and acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the input high level of each input data in the input state of the first moment and the second moment respectively.
Specifically, for N-input logic gates, the input data sequence is numbered 1,2, according to the description of step 101, N, further, in the embodiment of the present invention, probability values of high levels (logical value is "1") in the input data sequence are set to be respectivelyAnd the data sequences are independent of each other in both time and space.
Further, the input data sequence 1,2 is acquired, N is at k i And k j High level number n in two inputs 1 ,n 2 ,...,n N
As an alternative implementation of the embodiment of the present invention, step 103 includes: obtaining at least one input state transition probability of the logic gate to be calculated through a preset second calculation method based on the first input state set, the second input state set, each preset probability value and each numerical value; the second relation is determined based on each of the input state transition probabilities.
Specifically, the preset second calculation method is shown in the following relation (3):
wherein:representing the previous input as k i Current input k j If yes, the input state transition probability of the logic gate is to be calculated.
Further, based on each input state transition probability determined by the above-described relation (3), a second relation is determined, as shown in the following relation (4):
further, according to the above-mentioned relational expressions (2) and (4), a calculation relational expression of average energy consumption of the logic gate in a single operation time is obtained, as shown in the following relational expression (5):
wherein: w represents the average power consumption of the logic gate during a single operation time.
The conventional application of the input probability of the circuit aims at calculating the output probability of the circuit, namely, calculating the output probability distribution of the circuit through the input probability vector of the circuit, the circuit topology structure and the corresponding probability transition matrix. Unlike the conventional method, which applies to input probability, the present invention focuses on a single logic gate, analyzes the transition probability of the previous input and the current input of the logic gate, instead of a single current input, and aims to analyze the average energy consumption of a single operation of the logic gate according to the relationship between the input transition probability and the energy consumption, unlike the method, which calculates the output probability of the logic gate according to the input probability of the logic gate only (without considering the transition between the inputs), and the present invention is applicable to any n-input logic gate.
In one example, taking a two-input NAND gate as an example, the average energy consumption of the NAND gate in a single operation time is calculated.
First, according to the above-mentioned relation (2), the relation between the conversion of the input states of the two-input nand gate and the energy consumption is obtained, as shown in the following relation (6):
wherein: e (E) NAND Representing the previous input as 00/01/10/11 and 00/01/10/11, the two-input nand gate consumes energy during a single operation.
Next, according to the above-mentioned relation (4), the transition probability of the input state of the two-input nand gate is obtained as shown in the following relation (7):
wherein: t (T) NAND Representing the transition probability of the input state of the two-input nand gate when the previous input is 00/01/10/11 and the current input is 00/01/10/11.
Finally, based on the above relation (5), by combining the above relations (6) and (7), the average energy consumption of the two-input nand gate in a single operation time can be obtained, as shown in the following relation (8):
wherein: w (W) NAND The average energy consumption of the two-input NAND gate in a single operation time is shown.
The embodiment of the invention also provides a device for calculating the single running average energy consumption of the logic gate, as shown in fig. 2, the device comprises:
an obtaining module 201, configured to obtain an input data sequence of a logic gate to be calculated, and obtain a first input state set of the logic gate to be calculated in a first time and a second input state set of the logic gate to be calculated in a second time based on the input data sequence, where the second time is a next time adjacent to the first time; for details, see the description of step 101 in the above method embodiment.
A first determining module 202, configured to determine a first relational expression based on the first input state set and the second input state set, where the first relational expression reflects a relationship between a transition of an input state of the logic gate to be calculated and energy consumption; for details, see the description of step 102 in the method embodiment described above.
A second determining module 203, configured to determine a second relational expression based on the input data sequence, the first input state set and the second input state set, where the second relational expression reflects a transition probability of an input state of the input data sequence; for details, see the description of step 103 in the method embodiment described above.
The calculating module 204 is configured to obtain, based on the first relation and the second relation, an average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculating method; for details, see the description of step 104 in the method embodiment described above.
The device for calculating the single-operation average energy consumption of the logic gate provided by the embodiment of the invention combines the distribution characteristics of the input data sequence with the relations between the different input states of the logic gate and the energy consumption, can obtain the calculation method of the single-operation average energy consumption of the logic gate, is not influenced by the change of the input data sequence, can update the single-operation average energy consumption of the logic gate in real time only by counting the distribution characteristics of the data sequence in real time, is closer to the physical principle behind the logic operation compared with the method for directly measuring the energy consumption, does not relate to the physical factors such as the process, the material and the like of the logic gate, and greatly simplifies the flow and the step for analyzing the single-operation average energy consumption of the logic gate. Therefore, by implementing the invention, the result can be accurately calculated no matter what the static energy consumption ratio is.
As an optional implementation manner of the embodiment of the present invention, the first determining module includes: a first determining submodule, configured to determine at least one energy consumption generated by the logic gate to be calculated at a single operation time based on the first input state set and the second input state set; and a second determining sub-module for determining the first relation based on each of the energy consumptions.
As an alternative implementation manner of the embodiment of the present invention, the apparatus further includes: the first acquisition module is used for acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the high level input by each input data in the input state at the first moment and the second moment respectively.
As an optional implementation manner of the embodiment of the present invention, the second determining module includes: the computing sub-module is used for obtaining at least one input state transition probability of the logic gate to be computed through a preset second computing method based on the first input state set, the second input state set, each preset probability value and each numerical value; and a third determining sub-module for determining the second relation based on each of the input state transition probabilities.
The function description of the device for calculating the single-run average energy consumption of the logic gate provided by the embodiment of the invention is detailed in the description of the method for calculating the single-run average energy consumption of the logic gate in the embodiment.
The embodiment of the present invention also provides a storage medium, as shown in fig. 3, on which a computer program 301 is stored, which when executed by a processor implements the steps of the method for calculating a single running average energy consumption of a logic gate in the above embodiment. The storage medium may be a magnetic Disk, an optical disc, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a Flash Memory (Flash Memory), a Hard Disk (HDD), a Solid State Drive (SSD), or the like; the storage medium may also comprise a combination of memories of the kind described above.
It will be appreciated by those skilled in the art that implementing all or part of the above-described embodiment method may be implemented by a computer program to instruct related hardware, where the program may be stored in a computer readable storage medium, and the program may include the above-described embodiment method when executed. The storage medium may be a magnetic Disk, an optical disc, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a Flash Memory (Flash Memory), a Hard Disk (HDD), a Solid State Drive (SSD), or the like; the storage medium may also comprise a combination of memories of the kind described above.
The embodiment of the present invention further provides an electronic device, as shown in fig. 4, which may include a processor 41 and a memory 42, where the processor 41 and the memory 42 may be connected by a bus or other means, and in fig. 4, the connection is exemplified by a bus.
The processor 41 may be a central processing unit (Central Processing Unit, CPU). The processor 41 may also be other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or a combination of the above.
Memory 42 acts as a non-transitory computer readable storage medium that may be used to store non-transitory software programs, non-transitory computer executable programs, and modules, such as corresponding program instructions/modules in embodiments of the present invention. The processor 41 executes various functional applications of the processor and data processing, i.e. implements the method of calculating the single running average energy consumption of the logic gates in the method embodiments described above, by running non-transitory software programs, instructions and modules stored in the memory 42.
The memory 42 may include a memory program area that may store an operating device, an application program required for at least one function, and a memory data area; the storage data area may store data created by the processor 41, etc. In addition, memory 42 may include high-speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device. In some embodiments, memory 42 may optionally include memory located remotely from processor 41, which may be connected to processor 41 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 42 and when executed by the processor 41 perform the method of calculating a single running average energy consumption of a logic gate as in the embodiment shown in fig. 1.
The specific details of the electronic device may be understood correspondingly with respect to the corresponding related descriptions and effects in the embodiment shown in fig. 1, which are not repeated herein.
Although embodiments of the present invention have been described in connection with the accompanying drawings, various modifications and variations may be made by those skilled in the art without departing from the spirit and scope of the invention, and such modifications and variations fall within the scope of the invention as defined by the appended claims.

Claims (10)

1. A method of calculating a single run average energy consumption of a logic gate, the method comprising:
acquiring an input data sequence of a logic gate to be calculated, and acquiring a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment based on the input data sequence, wherein the second moment is the next moment adjacent to the first moment;
determining a first relation based on the first input state set and the second input state set, wherein the first relation reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption;
determining a second relational expression based on the input data sequence, the first input state set and the second input state set, the second relational expression reflecting a transition probability of an input state of the input data sequence;
and obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation.
2. The method of claim 1, wherein determining a first relationship based on the first set of input states and the second set of input states comprises:
determining at least one energy consumption generated by the logic gate to be calculated in a single operation time based on the first input state set and the second input state set;
the first relation is determined based on each of the energy consumptions.
3. The method of claim 1, wherein prior to determining a second relationship based on the input data sequence, the first set of input states, and the second set of input states, the method further comprises:
and acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the input high level of each input data in the input state of the first moment and the second moment respectively.
4. The method of claim 3, wherein determining a second relationship based on the input data sequence, the first set of input states, and the second set of input states comprises:
obtaining at least one input state transition probability of the logic gate to be calculated through a preset second calculation method based on the first input state set, the second input state set, each preset probability value and each numerical value;
the second relation is determined based on each of the input state transition probabilities.
5. An apparatus for calculating a single run average energy consumption of a logic gate, the apparatus comprising:
the logic gate control module is used for obtaining an input data sequence of a logic gate to be calculated, and obtaining a first input state set of the logic gate to be calculated in a first moment and a second input state set of the logic gate to be calculated in a second moment based on the input data sequence, wherein the second moment is the next moment adjacent to the first moment;
the first determining module is used for determining a first relational expression based on the first input state set and the second input state set, wherein the first relational expression reflects the relation between the conversion of the input state of the logic gate to be calculated and the energy consumption;
a second determining module configured to determine a second relational expression based on the input data sequence, the first input state set, and the second input state set, the second relational expression reflecting a transition probability of an input state of the input data sequence;
and the calculation module is used for obtaining the average energy consumption of the logic gate to be calculated in the single operation time through a preset first calculation method based on the first relation and the second relation.
6. The apparatus of claim 5, wherein the first determining module comprises:
a first determining submodule, configured to determine at least one energy consumption generated by the logic gate to be calculated at a single operation time based on the first input state set and the second input state set;
and a second determining sub-module for determining the first relation based on each of the energy consumptions.
7. The apparatus of claim 5, wherein the apparatus further comprises:
the first acquisition module is used for acquiring a preset probability value of a high level in each input data in the input data sequence and a number value of the high level input by each input data in the input state at the first moment and the second moment respectively.
8. The apparatus of claim 7, wherein the second determining module comprises:
the computing sub-module is used for obtaining at least one input state transition probability of the logic gate to be computed through a preset second computing method based on the first input state set, the second input state set, each preset probability value and each numerical value;
and a third determining sub-module for determining the second relation based on each of the input state transition probabilities.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium stores a computer program for causing the computer to execute the method of calculating a single-run average energy consumption of a logic gate according to any one of claims 1 to 4.
10. An electronic device, comprising: a memory and a processor in communication with each other, the memory storing a computer program, the processor executing the computer program to perform the method of calculating a single running average energy consumption of a logic gate as claimed in any one of claims 1 to 4.
CN202310484411.1A 2023-04-28 2023-04-28 Method and device for calculating single running average energy consumption of logic gate Pending CN116484165A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310484411.1A CN116484165A (en) 2023-04-28 2023-04-28 Method and device for calculating single running average energy consumption of logic gate

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310484411.1A CN116484165A (en) 2023-04-28 2023-04-28 Method and device for calculating single running average energy consumption of logic gate

Publications (1)

Publication Number Publication Date
CN116484165A true CN116484165A (en) 2023-07-25

Family

ID=87219242

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310484411.1A Pending CN116484165A (en) 2023-04-28 2023-04-28 Method and device for calculating single running average energy consumption of logic gate

Country Status (1)

Country Link
CN (1) CN116484165A (en)

Similar Documents

Publication Publication Date Title
US20170017882A1 (en) Copula-theory based feature selection
JPH0660139A (en) Power consumption calculation device for logical function block for mos transistor
CN111931925A (en) FPGA-based binary neural network acceleration system
CN114418062A (en) Method, system, device and storage medium for deep convolutional neural network quantization
US20200293854A1 (en) Memory chip capable of performing artificial intelligence operation and operation method thereof
US10169527B2 (en) Accurate statistical timing for boundary gates of hierarchical timing models
CN107463486B (en) System performance analysis method and device and server
CN116484165A (en) Method and device for calculating single running average energy consumption of logic gate
US20220318572A1 (en) Inference Processing Apparatus and Inference Processing Method
US10169509B2 (en) Efficient deployment of table lookup (TLU) in an enterprise-level scalable circuit simulation architecture
CN116227599A (en) Inference model optimization method and device, electronic equipment and storage medium
CN106302794A (en) The dynamic setting method of Connecting quantity and device
US11831159B2 (en) Systems, devices and methods for power management and power estimation
US20220206554A1 (en) Processor and power supply ripple reduction method
US11562248B2 (en) Data sparsity monitoring during neural network training
JP2803119B2 (en) CMOS gate array power consumption calculation method
CN112531629B (en) Method and device for automatically setting protection setting value of power distribution network and terminal equipment
Jothin et al. High performance static segment on-Chip memory for image processing applications
CN110895597B (en) Transcoding logical function calculation method and device, storage medium and electronic equipment
CN116845289A (en) Temperature observation method, device, equipment and storage medium of SOFC (solid oxide Fuel cell) stack
Edwards Mixed Signals for Machine Learning
Yoshioka et al. LUTNet-RC: Look-Up Tables Networks for Reservoir Computing on an FPGA
KR20160038532A (en) Integrated circuit device and method for calculating power consumption of integrated circuit device
CN117554815A (en) Method, device, equipment and medium for improving calculation precision of battery state of charge
CN117290744A (en) Electrical node aggregation method and device based on graph theory

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination