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

Method and equipment for creating hash table

A technology of hash tables and hash sub-tables, applied in the field of creating hash tables, which can solve the problems of increasing the cost of implementation, redundancy of table entry space, space waste, etc.

Active Publication Date: 2015-11-25
上海在赢端智能科技有限公司
View PDF4 Cites 7 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] Use a large hash table to realize the space that is not a positive integer power of 2. Taking 32 mega-entries to realize the space of 24 million as an example, about 8 million space is wasted, that is, about 25% of the table entry space is redundant , causing a waste of space and increasing the cost of implementation

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
  • Method and equipment for creating hash table
  • Method and equipment for creating hash table
  • Method and equipment for creating hash table

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0029] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present invention.

[0030] figure 1 is a schematic flowchart of a method for creating a hash table according to an embodiment of the present invention.

[0031] Before describing the method of the embodiment of the present invention, the structure of the hash table in the embodiment of the present invention will be described first. The hash table in the embodiment of the present invention includes: N hash sub-tables and an original key-value table. The N hash subtables are ...

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 method and equipment for creating a hash table. The method comprises following steps: determining subspace of at least two hash sub-tables according to space of the nth hash sub-table in N hash sub-tables of the hash table, wherein the size of the nth hash sub-table is non-positive integral power of 2 and sizes of subspace of at least two hash sub-tables are positive integral power of 2; mapping the current key value to one of sub-space of at least two hash sub-tables based on the nth pre-processed hash function used for mapping multiple key values to at least two sub-space of at least two hash sub-tables; generating an address of a hash bucket for the nth hash sub-table according to a hash function corresponding to one of subspace of the at least two hash sub-tables and the current key value; and storing the current key value into a hash sub-table of N hash sub-tables according to the number of free wafers corresponding to addresses of hash buckets for the N hash sub-tables generated by the N hash sub-tables. The method and equipment for creating the hash table have the capacities of reducing waste of space and decreasing cost of realization.

Description

technical field [0001] The invention relates to the communication field, in particular to a method and device for creating a hash table. Background technique [0002] The hash (hash) table has high search performance and is widely used in the field of communication technology. The 2-left hash algorithm divides a hash function into two independent hash functions hash1 and hash2. The two hash functions correspond to equal-sized hash subtables, and the hash functions hash1 and hash2 correspond to the two hash subtables. The maximum output is usually a positive integer power of 2, and the generated hash subtable space is also a positive integer power of 2, such as 2 megabytes (2097152), 4 megabytes (4194304), 8 megabytes (8388608), 16 megabytes (16777216), 32 megabytes (33554432), etc., so the 2-left hash table space is the sum of the two hash sub-table spaces, which is also a positive integer power of 2. However, the number of entries actually required is usually not a positi...

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
Patent Type & Authority Applications(China)
IPC IPC(8): G06F17/30
Inventor 孟玉刘振肖
Owner 上海在赢端智能科技有限公司
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