Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Proof-of-work algorithm optimization method and device, computer equipment and storage medium

An optimization method and an optimization device technology, which are applied in complex mathematical operations, special data processing applications, and other database retrievals, and can solve problems such as system performance degradation, memory read bandwidth performance bottlenecks, and unpredictable data extraction operation cycles

Active Publication Date: 2021-08-20
ZHEJIANG NANOMICRO TECH CO LTD +1
View PDF5 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] Due to the essential characteristics of the Memory-hard algorithm, memory read bandwidth becomes a performance bottleneck
In addition, because the traditional architecture is based on centralized memory storage, the distributed computing core requests data from the central memory to generate delays. Unlike the hash calculation with a fixed computing cycle in the algorithm, the running cycle required to extract data is unpredictable, resulting in System performance degradation

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Proof-of-work algorithm optimization method and device, computer equipment and storage medium
  • Proof-of-work algorithm optimization method and device, computer equipment and storage medium
  • Proof-of-work algorithm optimization method and device, computer equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0053] In this example, if figure 1 As shown, a workload proof algorithm optimization method is provided, which includes:

[0054] Step 110, obtain the secondary seed value of the current round.

[0055] Specifically, this step is one of the steps in the ethash algorithm, specifically the step of calculating and obtaining the secondary seed value. The secondary seed value can be obtained by encrypting the initial seed value in the initial round, or can be obtained by calculating the FNV hash algorithm in any round after the initial round.

[0056]In this embodiment, in the step of calculating the secondary seed value of the ethash algorithm, the secondary seed value of the current round is acquired. Specifically, in any round of the second seed value calculation step of the ethash algorithm, the second seed value of the current round is obtained.

[0057] Step 120 , calculating and obtaining a plurality of first index values ​​in the DAG and primary random numbers correspon...

Embodiment 2

[0092] For ease of understanding, in this embodiment, the traditional proof-of-work algorithm is first described, such as Figure 4A As shown, in the traditional proof-of-work algorithm, the following steps are included:

[0093] 1. Calculate the seed

[0094] Header_hash is the seed used to generate verification cache and mining data set, with a length of 32 bytes.

[0095] Fill the nonce value into the last (40-32=8) bytes of the seed, (the nonce itself is 64 bits, corresponding to 8 bytes), and just fill the 40-byte seed completely with the hash and nonce.

[0096] The seed is encrypted with sha3-512 (Keccak512).

[0097] 2.Mix (mixing)

[0098] Convert the 64Bytes seed to 16 4Bytes types, copy 2 copies as Seed_mix

[0099] Calculate a DAG index according to the formula, obtain data from the DAG according to the index, and fnv hash the obtained data and seed as a new seed; this step is repeated 64 times;

[0100] in

[0101]

[0102] 0x01000193 is a hash prime numb...

Embodiment 3

[0150] In this example, if figure 2 As shown, a proof-of-work algorithm optimization device is provided, including:

[0151] The secondary seed value acquisition module 210 is used to obtain the secondary seed value of the current round;

[0152] The correspondence calculation and acquisition module 220 is configured to calculate and obtain a plurality of first index values ​​in the directed acyclic graph and a primary random number corresponding to each of the first index values ​​according to the secondary seed value of the current round;

[0153] The second index value determining module 230 is configured to detect the number of primary random numbers corresponding to each of the first index values, obtain the first index value corresponding to the largest number of primary random numbers, and determine it as the second index value;

[0154] A directed acyclic data extraction module 240, configured to extract directed acyclic data corresponding to the second index value f...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention provides a proof-of-work algorithm optimization method and device, computer equipment and a storage medium. The method comprises the steps that multiple first index values and primary random numbers corresponding to the first index values are obtained through calculation according to secondary seed values of the current round; obtaining a first index value corresponding to the maximum number of the primary random numbers, and determining the first index value as a second index value; extracting directed acyclic data from a directed acyclic graph; and according to the secondary seed value and the directed acyclic data, calculating to obtain a secondary seed value of the next round. After the corresponding relation between the first index values and the primary random numbers is obtained through calculation, data are extracted from the directed acyclic graph by taking the first index value corresponding to the most primary random number as a second index value, and calculation of secondary seed values of the next round is carried out according to the data until 64 rounds are finished. The calculation efficiency of the mixing step in the ethash algorithm can be effectively improved, the delay is reduced, and the memory bandwidth bottleneck is relieved, so that the workload proving algorithm is optimized.

Description

technical field [0001] The invention relates to the technical field of proof-of-work, in particular to a proof-of-work algorithm optimization method, device, computer equipment and storage medium. Background technique [0002] The essence of POW (Proof of Work) is to solve a mathematically difficult problem based on computing power. The key point of solving the problem is that there is no way to find the nonce value we need except for violent enumeration, but for the verification output The result is very simple and easy. [0003] The ethash algorithm is a memory-hard function algorithm. During the operation process, the algorithm needs to repeatedly extract a large amount of data randomly from the memory for operation, and find a nonce (Number once, a random number) value to input into the algorithm. , resulting in results below a threshold based on a certain difficulty value. It can be seen from the above description that the performance bottleneck of the Ethash algorith...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F16/901G06F17/18
CPCG06F16/9024G06F16/9014G06F17/18
Inventor 孔剑平胡楠王琪李炳博
Owner ZHEJIANG NANOMICRO TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products