Unlock instant, AI-driven research and patent intelligence for your innovation.
A method and device for optimizing multi-stage hash
What is Al technical title?
Al technical title is built by PatSnap Al team. It summarizes the technical point description of the patent document.
An order and high-order technology, applied in the field of optimizing multi-order hash, can solve the problem of low filling rate of multi-order hash, and achieve the effect of improving the filling rate
Active Publication Date: 2018-01-19
TENCENT TECH (SHENZHEN) CO LTD
View PDF2 Cites 0 Cited by
Summary
Abstract
Description
Claims
Application Information
AI Technical Summary
This helps you quickly interpret patents by identifying the three key elements:
Problems solved by technology
Method used
Benefits of technology
Problems solved by technology
[0008] It can be seen from the above process that when the existing hash algorithm addresses the new data that needs to be inserted, if the addressing position of each level is not available, it will directly determine that the insertion of the new data fails; however, at this time, there may be many There are still unused positions in the multi-level hash, which leads to a low filling rate of the existing multi-level hash
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
Click on the blue label to locate the original text in one second.
Reading with bidirectional positioning of images and text.
Smart Image
Examples
Experimental program
Comparison scheme
Effect test
Embodiment 1
[0043] In this embodiment, new data A needs to be inserted into a 6th order hash. Such as Figure 3-Figure 6 The insertion process of data A in this embodiment is shown.
[0044] exist image 3 In , according to the key value KeyA of data A, the addressing position at each level is calculated, and it is found that conflicting data has been stored in all addressing positions, namely B, C, D, E, F and G.
[0045] Since all addressed locations are unavailable, the colliding data at all addressed locations is probed to a higher order. Such as Figure 4 and Figure 5 shown.
[0046] exist Figure 4 , detect data B to a higher level, that is, calculate the addressing position on a higher level according to the key value KeyB of data B, and find that the addressing position on the fifth level is free, then the detection of data B is considered successful , and record the order 5 of the successful detection position.
[0047] exist Figure 5, continue to detect data C to a hi...
Embodiment 2
[0061] In this embodiment, new data A needs to be inserted into a 6th order hash. Such as Figure 7-Figure 9 The insertion process of data A in this embodiment is shown. In this embodiment, the threshold value of the number of replacement layers is 2 layers as an example for illustration.
[0062] exist Figure 7 In , according to the key value KeyA of data A, the addressing position at each level is calculated, and it is found that conflicting data has been stored in all addressing positions, namely B, C, D, E, F and G. Moreover, the detection of the conflicting data B, C, D, E, F, and G is all unsuccessful, that is, the higher-order addressing positions of these conflicting data have been occupied ( Figure 7 Only the probing process for Data B is shown).
[0063] After that, use A to replace all conflicting data B, C, D, E, F, and G on its addressing path in turn, and insert the replaced conflicting data into Cuckoo Hash.
[0064] Such as Figure 8 As shown, replace d...
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
Login to View More
Abstract
The invention provides a method and a device for optimizing a multi-order hash. The method comprises the steps that when new data is inserted into the multi-order hash, if conflict data is stored in all addressing locations of the data to be inserted, the conflict data in all the addressing locations is detected for higher order; if conflict data resulting from successful detection exists, the conflict data with the lowest order in the successfully detected position is transferred to the successfully detected position to be stored, and the data to be inserted is stored at the initial position of the conflict data with the lowest order in the successfully detected position. With the method and the device for optimizing multi-order hash, the filling rate of the multi-order hash is improved.
Description
technical field [0001] The present invention relates to the technical field of multi-stage hashing, in particular to a method and device for optimizing multi-stage hashing. Background technique [0002] Multi-level hash is an excellent data structure, which has the advantages of high performance, reentrant, stable, robust, multi-execution flow security, and self-elimination. The implementation process of multi-level hash is as follows: [0003] N large prime numbers are preset, and each large prime number is used as the length of each level of hash bucket; [0004] When new data needs to be stored, the key value of the new data is used to take the remainder of the length of the hash bucket at the current stage to obtain the addressing location. If conflicting data is already stored at the addressing location, hashing is carried out to the next stage Calculate; otherwise, save the new data in the addressed location; [0005] When storing data in a multi-stage hash, the max...
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
Application Date:The date an application was filed.
Publication Date:The date a patent or application was officially published.
First Publication Date:The earliest publication date of a patent with the same application number.
Issue Date:Publication date of the patent grant document.
PCT Entry Date:The Entry date of PCT National Phase.
Estimated Expiry Date:The statutory expiry date of a patent right according to the Patent Law, and it is the longest term of protection that the patent right can achieve without the termination of the patent right due to other reasons(Term extension factor has been taken into account ).
Invalid Date:Actual expiry date is based on effective date or publication date of legal transaction data of invalid patent.