CN105812258B - A kind of data processing method and device - Google Patents

A kind of data processing method and device Download PDF

Info

Publication number
CN105812258B
CN105812258B CN201410851108.1A CN201410851108A CN105812258B CN 105812258 B CN105812258 B CN 105812258B CN 201410851108 A CN201410851108 A CN 201410851108A CN 105812258 B CN105812258 B CN 105812258B
Authority
CN
China
Prior art keywords
prefix
node
trie
tree
multidigit
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
Application number
CN201410851108.1A
Other languages
Chinese (zh)
Other versions
CN105812258A (en
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.)
Beijing Huawei Digital Technologies Co Ltd
Original Assignee
Beijing Huawei Digital Technologies Co Ltd
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 Beijing Huawei Digital Technologies Co Ltd filed Critical Beijing Huawei Digital Technologies Co Ltd
Priority to CN201410851108.1A priority Critical patent/CN105812258B/en
Publication of CN105812258A publication Critical patent/CN105812258A/en
Application granted granted Critical
Publication of CN105812258B publication Critical patent/CN105812258B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The embodiment of the invention discloses a kind of data processing method and device, applied to multidigit tree, obtain includes at least one Trie node and corresponding Prefix node in the structure of the multidigit tree, the capacity of Prefix node is less than or equal to preset capacity, Prefix node includes PLPM, the route prefix in corresponding Trie node and the next hop information for corresponding to route prefix in Trie node, it is iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to the preset capacity.It can be seen that, multidigit tree after iteration, which is more suitable, to be deposited in caching, and the next hop information of route prefix in PLPM and corresponding Trie node is directly saved in Prefix node, so that corresponding next hop information can be directly obtained when obtaining matching result during route querying, thereby reduce the memory access number of route querying, the number of cache invalidation is decreased, search efficiency is directly enhanced.

Description

A kind of data processing method and device
Technical field
The present invention relates to data processing fields, more particularly to a kind of data processing method and device.
Background technique
Route querying is the purpose IP address according to message, searches the routing table in router, obtains message next-hop letter The process of breath.Every routing in routing table is all a route prefix.What route prefix can be formed with ' 0 ', ' 1 ' and ' * ' Three value bits string representations.As IPv4 prefix 192.168.1.0/24 can use three following value bits string representations: 11000000 10101000 00000001********.' * ' expression is indifferent to, both can be with ' 1 ' matching, can also be with ' 0 ' matching.So Two address IPv4 192.168.1.1 and 192.168.1.2 are matched with prefix 192.168.1.0/24.It is multiple when having below When ' * ', one ' * ' is generally only write.Such as ' 01* ', indicate that the value of front two is " 01 ", subsequent position is all ' * '.Route querying It is a longest prefix match (LPM Longest Prefix Match) problem.When having a plurality of prefix with the IP address of input Timing, the corresponding next hop information of the longest matching prefix of mask are only final lookup result.Assuming that the length of IP address is 9 Position, if there are two prefix " 01* " and " 010* " in routing table, IP address 010100101 is all matched with the two prefixes, but Because prefix " 010* " is longer than " 01* ", " 010* " is only longest matching prefix, its corresponding next hop information is only Final lookup result.
Routing Algorithm commonly used in the prior art mainly uses multidigit tree (Multi-Bit Trie), and multidigit tree can To be interpreted as, a binary tree is established according to the bit string in route prefix, in binary tree, if the value of present bit is ' 0 ' It makes a move, then makes a move to the right if it is ' 1 ' to the left.The digit considered every time is usually fixed multidigit, and the digit can also be with It is interpreted as the step-length of long number.As shown in FIG. 1, FIG. 1 is the structural schematic diagrams of multidigit tree in the prior art.The wherein prefix of p0 For *, the prefix of p1 is 0*, and the prefix of p2 is 10*, and the prefix of p3 is 111*, and the prefix of p4 is 0000*, and the prefix of p5 is The prefix of 1001*, p6 are 11101*, and the prefix of p7 is 11111*, and the prefix of p8 is 000011*, and the prefix of p9 is 0000100*, The prefix of p10 is 1110100*.Assuming that step-length is 3, binary tree is divided into 7 sub- Trie as shown in Figure 1, and respectively T1 is arrived T7.Multidigit tree is considered as that one y-bend Trie is divided into multiple sub- Trie by step-length, and creates one for every sub- Trie Trie node (Trie Node).If there is prefix in certain sub- Trie, also a Prefix node is created for the sub- Trie (Prefix Node).The prefix fallen in inside the sub- Trie is all stored in Prefix node.The corresponding next-hop of every prefix Information is known as RE (REsult).RE Index is only saved generally in multidigit tree, that is, is directed toward the pointer of next hop information.It is right In every intermediate sub- Trie, require to calculate a current longest prefix match (Present Longest Prefix for it Match, PLPM).For example, for sub- T2, the longest-prefix due to covering it is p1, so the corresponding PLPM of T2 is prefix p1. The corresponding RE Index of PLPM is typically maintained in first position of REIndex array, and saves in Trie node or Prefix With 1 bit identification, currently whether sub- Trie has corresponding PLPM in point.It is located at each node pair of Level 2 and Level 3 in Fig. 1 The PLPM answered is marked on the right side of RE Index array.Trie node has two class child nodes, respectively Trie child node With Prefix child node, it is Trie node, that is, T2, T3 and T4 that the Trie node T1 of example as shown in figure 1, which has 3 child nodes,;Have One child node is Prefix node, that is, with the associated Prefix node of T1.Each Trie node has an association KEY, that is, the corresponding route prefix of starting point of subtree.The association KEY of Trie node is considered as the root node from Trie The prefix formed to each segmentation KEY of current Trie node.Such as in Fig. 1, the association KEY of T1 is ' * ', the association of T2 KEY is ' 000* ', and the association KEY of T3 is ' 010* '.The pointer for being directed toward Trie child node is saved in Trie node.One Trie The Trie child node of node is typically all continuous storage (being considered as an array), so only needing to save Trie child node Initial position.Than the child node that 3 Trie nodes T2, T3 and T4 as shown in figure 1 are Trie node T1, they are stored in one In array, the initial address that array is only saved in Trie node T1 can.Also direction is saved in Trie node The pointer of Prefix child node.In existing multidigit tree algorithm, the Prefix child node of a Trie node is only intended to protect Deposit the prefix in the corresponding subtree of Trie node.In addition, also to save the bitmap for indexing child node, position in Trie node The digit of figure is 2Step-length.There are several 1 to mean that several Trie child nodes in bitmap.In the example in fig 1, because step-length is 3, So the bitmap for child node index only needs 8.Three corresponding point of Trie child node T2, T3 and T4 of Trie node T1 Section KEY is respectively 000,100 and 111, so the bitmap for indexing child node saved in T1 is 10001001.
In order to handle the message received with reaching linear speed, route querying is typically all to use hardware realization.Lookup in hardware Structure is usually a multistage assembly line.The at different levels of Trie can be stored in each of hardware pipeline by the algorithm based on Trie In grade.Based on Fig. 1, Fig. 2 is the lookup structural schematic diagram of multidigit tree within hardware in the prior art.It is divided into 5 grades, preceding 3 Grade saves 3 layers of Trie node, and the 4th grade of corresponding Prefix node of 7 Trie nodes of preservation, the 5th grade saves each Prefix section The corresponding RE pointer of prefix in point.When lookup, input KEY gets off along assembly line level-one level-one, finally obtains lookup knot Fruit.Assuming that the length of IP address is 9, the process for searching IP address 111 010 011 is as follows:
Step 1: into the first order of assembly line, Trie node T1 is accessed, and extracts highest 3 in secondary IP address ‘111'.Because T1 has corresponding Prefix node, the pointer of the Prefix node is recorded.
Step 2: the child node T4 of Trie node T1 is accessed according to segmentation KEY ' 111 ', and extracts and connects down in secondary IP address 3 ' 010 ' come.Because T4 also has corresponding Prefix node, it is corresponding for T4 to update the Prefix node pointer searched Prefix node pointer.
Step 3: the child node T7 of Trie node T4 is accessed according to segmentation KEY ' 010 ', and extracts and connects down in secondary IP address 3 ' 011 ' come.Because T7 also has corresponding Prefix node, it is corresponding for T7 to update the Prefix node pointer searched Prefix node pointer.
Step 4: since T7 does not have Trie child node, so being accessed using the last Prefix node pointer saved Prefix node.The corresponding Prefix node of namely T7 in this example.Before being saved in Prefix node in subtree T7 Sew p10.KEY is inputted, that is, IP address 111 010 011 matches (herein, it is only necessary to compare with prefix p10 " 1110100* " 011 with ' 0* ' can), and the subtree has corresponding PLPM, so the corresponding RE index of p10 is stored in RE index Second position (array index 1) of array.
Step5: the corresponding RE of p10 is obtained according to position of the RE index obtained in Step 4 in RE index array Index.Pass through the available next hop information of RE Index of return.
As it can be seen that the series of traditional multidigit tree is relatively more, when routing capacity is larger, tree all can not be placed on caching (cache) it when in, when carrying out route querying, needs repeatedly to access memory, updates the content in cache, cache is caused to fail Number it is more, waste system resource simultaneously directly contribute search speed decline.
Summary of the invention
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of data processing method and device, in iteration The next hop information that route prefix in PLPM and corresponding Trie node is saved in Prefix node afterwards, effectively reduces and is looking into Look for memory access number when routing.
In a first aspect, the embodiment of the invention provides a kind of data processing method, it is applied to multidigit tree, in the multidigit tree Including multiple route prefix, which comprises
It obtains including at least one Trie node and corresponding Prefix node in the structure of the multidigit tree, it is described The capacity of Prefix node is less than or equal to preset capacity, and the Prefix node includes PLPM, the routing in corresponding Trie node The next hop information of route prefix in prefix and corresponding Trie node, the first Trie node are at least one described Trie node Any Trie node, the first Trie node includes corresponding bitmap, the corresponding Prefix section of the first Trie node Point includes direct Prefix node and indirect Prefix node, includes that the first Trie is saved in the direct Prefix node Route prefix in point, in the PLPM and the first Trie node of the direct Prefix node route prefix next-hop letter Breath, the indirect Prefix node includes route prefix in the Trie node connected under the first Trie node, described The next hop information of route prefix in the Trie node connected under the PLPM of indirect Prefix and the first Trie node;
It is iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to the preset capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, according to the structure of the new multidigit tree Obtain Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
In the first possible implementation of the first aspect, further includes:
Obtain routing address to be found;
LPM is carried out since the multidigit tree that last time iteration obtains according to the routing address to be found, according to matching To the Prefix node bitmap that is included and the routing address to be found determine in last iteration in multidigit tree Prefix node;
Carry out circulation matching, until in the multidigit tree that matching result is before being matched to non-iteration Prefix node or appearance Without matching prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described Routing address to be found determines the Prefix node in the multidigit tree obtained in the N-1 times iteration;
If the matching result is the Prefix node in the multidigit tree before being matched to non-iteration, before the non-iteration Multidigit tree in Prefix node in the next hop information of the matched route prefix of routing address to be found as institute State the next hop information of routing address to be found;
If the matching result is to occur without matching prefix, the PLPM institute of the Prefix node without matching prefix will occur Next hop information of the next hop information of corresponding route prefix as the routing address to be found.
In the second possible implementation of the first aspect, further includes:
Using multiple Trie nodes in multidigit tree in same single connection structure as a Trie node processing, the list Connection structure is specifically included in the knot of one Trie node of a Trie node lower connection in the connection structure of the multidigit tree Structure.
In a third possible implementation of the first aspect, further includes:
The Prefix node stores PLPM by least one PCL, corresponds to the route prefix and correspondence in Trie node The next hop information of route prefix in Trie node, the PCL and Trie node correspond.
With reference to first aspect or the first or second or the third possible implementation of first aspect, the 4th In the possible implementation of kind,
The preset capacity is determined according to the cache size of processing system.
Second aspect is applied to multidigit tree the embodiment of the invention provides a kind of data processing equipment, in the multidigit tree Including multiple route prefix, the data processing equipment includes:
Acquiring unit includes at least one Trie node and corresponding Prefix in the structure for obtaining the multidigit tree Node, the capacity of the Prefix node are less than or equal to preset capacity, and the Prefix node includes PLPM, corresponding Trie node In route prefix and corresponding Trie node in route prefix next hop information, the first Trie node be it is described at least one Any Trie node in Trie node, the first Trie node includes corresponding bitmap, and the first Trie node is corresponding Prefix node include direct Prefix node and indirect Prefix node, include described in the direct Prefix node Route prefix in first Trie node, route prefix in the PLPM and the first Trie node of the direct Prefix node Next hop information, the indirect Prefix node includes the routing in the Trie node connected under the first Trie node Prefix, the indirect Prefix PLPM and the first Trie node under in the Trie node that connects route prefix it is next Hop-information;
Iteration unit, for being iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to described Preset capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, according to the structure of the new multidigit tree Obtain Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
In the first possible implementation of the second aspect, further includes:
Receiving unit, for obtaining routing address to be found;
Matching unit, for being carried out since the multidigit tree that last time iteration obtains according to the routing address to be found LPM, the bitmap for being included according to the Prefix node being matched to and the routing address to be found determine in last iteration Prefix node in multidigit tree;
The matching unit is also used to carry out circulation matching, until in the multidigit tree that matching result is before being matched to non-iteration Prefix node or occur without matching prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described Routing address to be found determines the Prefix node in the multidigit tree obtained in the N-1 times iteration;
If the matching result of the matching unit is the Prefix node in the multidigit tree before being matched to non-iteration, really Order member, for by the Prefix node in the multidigit tree before the non-iteration with the matched road of routing address to be found Next hop information by the next hop information of prefix as the routing address to be found;
If the matching result of the matching unit is to occur without matching prefix, the determination unit is also used to occur The next hop information of route prefix corresponding to the PLPM of Prefix node without matching prefix is as the routing address to be found Next hop information.
In a second possible implementation of the second aspect, further includes:
Processing unit, for saving multiple Trie nodes in multidigit tree in same single connection structure as a Trie Point processing, the single connection structure are specifically included in a Trie node lower connection one in the connection structure of the multidigit tree The structure of Trie node.
In the third possible implementation of the second aspect,
The Prefix node stores PLPM by least one PCL, corresponds to the route prefix and correspondence in Trie node The next hop information of route prefix in Trie node, the PCL and Trie node correspond.
In conjunction with the first or second or the third possible implementation of second aspect or second aspect, the 4th In the possible implementation of kind,
The preset capacity is determined according to the cache size of processing system.
By the iterative operation to multidigit tree it can be seen from above-mentioned technical proposal, so that multidigit tree after iteration is total Capacity is less than or equal to preset capacity, is more suitable and deposits in caching, and in the Prefix node of the multidigit tree after iteration directly The next hop information of route prefix in PLPM and corresponding Trie node is saved, so that can obtain during route querying Corresponding next hop information is directly obtained when to matching result, is reduced and is also needed in script when searching under memory access is again to obtain The process of one hop-information thereby reduces the memory access number of route querying, decreases the number of cache failure, directly improves Search efficiency.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of invention without any creative labor, may be used also for those of ordinary skill in the art To obtain other drawings based on these drawings.
Fig. 1 is the structural schematic diagram of multidigit tree in the prior art;
Fig. 2 is the lookup structural schematic diagram of multidigit tree within hardware in the prior art;
Fig. 3 is a kind of method flow diagram of data processing method provided in an embodiment of the present invention;
Fig. 4 a is a kind of structural schematic diagram of multidigit tree provided in an embodiment of the present invention;
Fig. 4 b is a kind of structural schematic diagram of the Trie node creation of multidigit tree provided in an embodiment of the present invention;
Fig. 4 c is the associated prefixes schematic diagram of the Prefix node before a kind of iterative operation provided in an embodiment of the present invention;
Fig. 5 a is the structural schematic diagram of the multidigit tree after a kind of iterative operation provided in an embodiment of the present invention;
Fig. 5 b is the structural schematic diagram of the Trie node creation after a kind of iterative operation provided in an embodiment of the present invention;
Fig. 5 c is a kind of route querying structural schematic diagram provided in an embodiment of the present invention;
Fig. 6 is a kind of method flow diagram of method for searching route provided in an embodiment of the present invention;
Fig. 7 is a kind of structural schematic diagram of Skip node provided in an embodiment of the present invention;
Fig. 8 is a kind of schematic diagram of the coding method of Prefix node provided in an embodiment of the present invention;
Fig. 9 is a kind of node structure schematic diagram of Prefix node provided in an embodiment of the present invention;
Figure 10 is a kind of structure drawing of device of data processing equipment provided in an embodiment of the present invention;
Figure 11 is a kind of structure drawing of device of device for searching route provided in an embodiment of the present invention;
Figure 12 is a kind of structure drawing of device of data processing equipment provided in an embodiment of the present invention.
Specific embodiment
In the prior art, when saving route prefix, multistage, example can be split into according to the multidigit tree that route prefix is formed As shown in Fig. 2, being divided into 5 grades, 3 layers of Trie node of preceding 3 grades of preservations, the corresponding Prefix of 7 Trie nodes of the 4th grade of preservation is saved Point, the 5th grade of corresponding RE pointer of prefix saved in each Prefix node.When lookup, KEY is inputted along assembly line level-one one Grade is got off, and lookup result is finally obtained.Next hop information is independent in other words for the corresponding RE pointer of prefix in Prefix node It is stored in level-one, in this way during routing inquiry, it may be necessary to repeatedly access memory, update the content in cache, make The number to fail at cache is more, wastes system resource and directly contributes search speed decline.
For the problems of the prior art, the embodiment of the invention provides a kind of data processing method and device, by right The iterative operation of multidigit tree so that the total capacity of the multidigit tree after iteration be less than or equal to preset capacity, be more suitable deposit in it is slow Current longest prefix match PLPM and corresponding Trie section are directly saved in the Prefix node of multidigit tree in depositing, and after iteration The next hop information of route prefix in point, so that can be directly obtained when obtaining matching result during route querying pair The next hop information answered reduces and also needs memory access again to obtain the process of next hop information when searching in script, thus subtracts The memory access number for having lacked route querying decreases the number of cache failure, directly enhances search efficiency.
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete Whole description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other Embodiment shall fall within the protection scope of the present invention.
Embodiment one
Fig. 3 is a kind of method flow diagram of data processing method provided in an embodiment of the present invention, is applied to multidigit tree Trie, It include multiple route prefix in the multidigit tree, which comprises
S301: obtaining includes at least one Trie node and corresponding Prefix node, institute in the structure of the multidigit tree The capacity for stating Prefix node is less than or equal to preset capacity, and the Prefix node includes current longest prefix match PLPM, right The next hop information of route prefix in the route prefix and corresponding Trie node in Trie node is answered, the first Trie node is described Any Trie node at least one Trie node, the first Trie node includes corresponding bitmap, the first Trie The corresponding Prefix node of node includes direct Prefix node and indirect Prefix node, in the direct Prefix node In PLPM and the first Trie node including route prefix, the direct Prefix node in the first Trie node The next hop information of route prefix, the indirect Prefix node include the Trie node connected under the first Trie node In route prefix, the indirect Prefix PLPM and the first Trie node under route in the Trie node that connects before The next hop information sewed.
The present invention is described with reference to the drawings and applies direct Prefix node and indirect Prefix node described in example and Trie section Relationship between point, Fig. 4 a are a kind of structural schematic diagram of multidigit tree provided in an embodiment of the present invention, and wherein the prefix of p0 is The prefix of 00*, p1 are 000*, and the prefix of p2 is 0010*, and the prefix of p3 is 00111*, and the prefix of p4 is 000000*, before p5 Sew for 001001*, the prefix of p6 is 0011101*, and the prefix of p7 is 0011111*, and the prefix of p8 is 00000011*, before p9 Sew for 000000100*, the prefix of p10 is 001110100*.In the case where length is 4 linear list (Direct Table), 00 disappears The front two for having consumed p1 to p10 prefix can be divided into 7 Trie nodes as shown in fig. 4 a in the case where step-length is 3, Respectively T1 to T7.At least one Trie node and corresponding prefix are obtained according to the structure of multidigit tree as shown in fig. 4 a Prefix node, specifically can be as shown in Figure 4 b, and Fig. 4 b is a kind of Trie node wound of multidigit tree provided in an embodiment of the present invention The structural schematic diagram built.Wherein, there are two Prefix nodes, respectively P1 and P3 for T1 tool, and wherein P1 belongs to the direct of T1 Prefix node, for saving route prefix p0, p1 and p2 in T1.P3 belongs to the indirect Prefix node of T1, for saving The PLPM of the information of the Trie node connected under T1, corresponding next hop information and P1.In embodiments of the present invention, it is assumed that by Excessive in capacity, the capacity of P3 cannot be greater than the preset capacity, therefore can only save the information in T3, before p5 Sew, the PLPM of corresponding next hop information and P3.Similarly, P4 is the direct Prefix node of T4, and P7 is the indirect of T4 Prefix node, P2 are the direct Prefix node of T2, the indirect Prefix node that P5 and P6 are T2.One Trie node Trie child node is up to 2Step-lengthIt is a;And Prefix child node can have up to 2Step-length+ 1.
It should be noted that each Trie node has an associated prefixes.In the same manner, each Prefix node also has one A associated prefixes.The associated prefixes of the direct Prefix node of one Trie node are identical with the associated prefixes of the Trie node; The associated prefixes of the indirect Prefix node of one Trie node are identical with the associated prefixes of corresponding Trie node.One The associated prefixes of the Trie child node of Trie node and the associated prefixes of its indirect Prefix node are different.For example scheme The corresponding associated prefixes of two Trie child nodes T2 and T4 of T1 are ' 00000* ' and ' 00111* ' in 4b, and two Prefix The corresponding associated prefixes of node P1 and P3 are ' 00* ' and ' 00100* ', that is, the corresponding associated prefixes of Trie node T1 and T3.
S302: being iterated operation, and the total capacity of the multidigit tree obtained after iteration is less than or equal to the preset capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, according to the structure of the new multidigit tree Obtain Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
The iterative operation is illustrated in conjunction with attached drawing, based on Fig. 4 b, Fig. 4 c is provided in an embodiment of the present invention A kind of associated prefixes schematic diagram of Prefix node before iterative operation.It as illustrated in fig. 4 c, altogether include 7 Prefix sections in Fig. 4 b Point, obtains the associated prefixes of this 7 Prefix nodes, respectively 00*, 00100*, 00000*, 00111*, 00111010*, 00000011* and 00000010* is iterated operation using this 7 associated prefixes, constructs new multidigit tree, such as Fig. 5 a institute Showing, Fig. 5 a is the structural schematic diagram of the multidigit tree after a kind of iterative operation provided in an embodiment of the present invention, firstly, the multidigit tree It is to be equivalent to without linear list that the length of linear list, which becomes 1, compared with the existing technology for be equivalent to and reduce multidigit tree Quantity.In the multidigit tree as shown in Figure 5 a of second of iteration creation, Trie section where all prefixes are all just fallen in respectively The bottommost of point.The efficiency of Prefix nodes encoding can be improved in this way.It is obtained according to the structure of multidigit tree as shown in Figure 5 a Trie node and corresponding prefix Prefix node, available Trie node and Prefix node as shown in Figure 5 b, Fig. 5 b For the structural schematic diagram of the Trie node creation after a kind of iterative operation provided in an embodiment of the present invention, by more shown in Fig. 5 a Position tree, obtains a Trie node T21 and three Prefix node P21, P22 and P23, and wherein P21 saves the prefix in T21, It is the direct Prefix node of T21.P22 saves the prefix in T22 and T24;P23 save T23 and T25 in prefix, P22 and P23 is respectively the indirect Prefix node of T21.In structure as shown in Figure 5 b, it is assumed that the multidigit tree of creation has been compared Small, the total capacity of multidigit tree is less than or equal to the preset capacity, stops iterative operation.Final lookup structure is by second generation iteration The prefix node composition of the multidigit tree of creation and the creation of first time iteration.Can be as shown in Figure 5 c, Fig. 5 c is that the present invention is implemented A kind of route querying structural schematic diagram that example provides.As it can be seen that multidigit tree as shown in Figure 1, the prior art needs to search using 5 grades Structure, in the specific example lifted in reality embodiment of the present invention, in the case where prefix is two more, by iterative operation, finally 3 grades of lookup structures are obtained, the number of required memory access during route querying can be reduced in this way, meanwhile, in the embodiment of the present invention Corresponding next hop information is also directly saved in the Prefix node of offer, further reduces memory access number.
It should be noted that Fig. 5 b is a specific example.It is primary that the present invention does not limit an iterative operation.Equally Ground, can be using the identical method with first multidigit tree, using all Prefix nodes as looking into for second multidigit tree The level-one of assembly line is looked for, and is inserted into third multidigit tree using their associated prefixes as new prefix.The rest may be inferred, leads to It crosses and creates more multidigit trees, that is, carry out successive ignition, to the last a multidigit tree is smaller, can be placed in cache Until.Final lookup structure is made of the last one Trie node and multistage Prefix node.
For the preset capacity it should be noted that the preset capacity is determined according to the cache size of processing system. In general, if the cache line of CPU is 512, the maximum of Prefix node can be set as 512, to improve Memory access efficiency.
As can be seen from the above-described embodiment, by the iterative operation to multidigit tree, so that total appearance of the multidigit tree after iteration Amount is less than or equal to preset capacity, is more suitable and deposits in caching, and directly protects in the Prefix node of the multidigit tree after iteration The next hop information for having deposited route prefix in current longest prefix match PLPM and corresponding Trie node, so that in route querying Corresponding next hop information can be directly obtained when obtaining matching result in the process, reduces and is also needed again in script when searching Secondary memory access thereby reduces the memory access number of route querying to obtain the process of next hop information, decreases cache failure Number directly enhances search efficiency.
Next by the route querying structure progress route querying to how to be established using embodiment as shown in Figure 3.? On the basis of embodiment corresponding to Fig. 3, Fig. 6 is a kind of method flow diagram of method for searching route provided in an embodiment of the present invention, The described method includes:
S601: routing address to be found is obtained.
S602: longest-prefix is carried out since the multidigit tree that last time iteration obtains according to the routing address to be found LPM is matched, the bitmap for being included according to the Prefix node being matched to and the routing address to be found determine that the last time changes Prefix node in generation in multidigit tree.
For example, the multidigit tree that last time iterative operation obtains from S302 begins looking for when being searched, with For Fig. 5 c, can directly it be searched since T21.
S603: carrying out circulation matching, the Prefix node in the multidigit tree that matching result is before being matched to non-iteration Or occur without matching prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described Routing address to be found determines the Prefix node in the multidigit tree obtained in the N-1 times iteration.
For example, due to by iterative operation, available multistage route querying structure as shown in Figure 5 c, S603's Circulation matching is it is to be understood that according to classification, since the Trie node of the multistage route querying structure most upper level, from upper The process searched step by step down.By the bitmap and routing address to be found saved in Prefix node, can determine Which Prefix node is searched in next stage.
S604: if the matching result is the Prefix node in multidigit tree before being matched to non-iteration, will it is described not In the Prefix node in multidigit tree before iteration with the next hop information of the matched route prefix of routing address to be found Next hop information as the routing address to be found.
S605: if the matching result is to occur without matching prefix, the Prefix node without matching prefix will occur Next hop information of the next hop information of route prefix corresponding to PLPM as the routing address to be found.
The situation in S604 and S605 is illustrated by taking Fig. 5 c as an example.Assuming that routing address to be found is 00111010011, multidigit tree shown in Fig. 5 c is searched, since first order T21, finding PLPM is 00*, is saved according to T21 Bitmap and the routing address to be found, determine second level P23, and the PLPM found in P23 is 00111010*, according to P23 The bitmap of preservation and the routing address to be found, determine third level P7, and the PLPM found out in P7 is 001110100*, right Prefix p10 is answered, using the p10 next hop information of preservation as the next hop information of the routing address to be found.This lookup feelings Condition is similar to S604.
If the routing address to be found is 00111010111.In search procedure, the identified second level is also P23, The PLPM found in P23 is 00111010*, according to bitmap and the routing address to be found that P23 is saved, determines the third level P7, but the matching result in third level P7 is five matching prefixes, therefore by the PLPM of P7, that is, the prefix of p27 in P23 Next hop information of the next hop information as the routing address to be found.This lookup situation is similar to S605.
Next, the method for further describing a kind of simplified multidigit tree construction provided in an embodiment of the present invention optionally will Multiple Trie nodes in multidigit tree in same single connection structure are as a Trie node processing, the single connection structure tool Body includes the structure for only connecting a Trie node under a Trie node in the connection structure of the multidigit tree.
For example, when Trie structure is relatively simple Trie in same single connection structure can be in by multiple Node is accordingly saved as a node, can be by multistage Trie node pressure when Trie node is list connection It is condensed to a Skip node.One Skip node can have most 2Step-lengthA Trie child node and most 1 Prefix child node. It is described by attached drawing, Fig. 7 is a kind of structural schematic diagram of Skip node provided in an embodiment of the present invention.As shown in fig. 7, triangle Dotted line frame in tool have 4 grades of Trie node lists connections there are four Trie node, and in the subtree in every level-one Trie node There is prefix.In such a case, it is possible to which the Trie node that multistage list connects is placed in a Skip node, and will own Prefix be compressed in 1 Prefix child node.For Skip node, for indexing the structure of Trie child node with general T rie Node is identical;And the structure for being used to index Prefix child node only needs the address of 1 bitmap and child node.
Next, the embodiment of the invention also provides before the routing in a kind of preferred preservation PLPM, corresponding Trie node Sew and correspond to the mode of the next hop information of route prefix in Trie node.Optionally, the Prefix node passes through at least one In a prefix cluster (Prefix CLuster, PCL) storage PLPM, the route prefix in corresponding Trie node and corresponding Trie node The next hop information of route prefix, the PCL and Trie node correspond.
Each PCL is made of 3 parts: (1) number of preposition segmentation;(2) bitmap of prefix is indicated;(3) preposition segmentation.Its In, digit shared by (1) and (2) is fixed, composition PCL Header.Digit shared by preposition segmentation is by a of preposition segmentation Several and each segmentation length, that is, step-length determine.By attached drawing for example, Fig. 8 is provided in an embodiment of the present invention one The schematic diagram of the coding method of kind Prefix node.It wherein, include 4 Trie nodes in Trie node shown in Fig. 8, respectively It include 6 route prefix for T1, T2, T3 and T4, respectively the prefix of p1 is 1*, and the prefix of p2 is 00101*, the prefix of p3 For 10101*, the prefix of p4 is 10111*, and the prefix of p5 is 0010011*, and the prefix of p6 is 00100101*.Each of included Trie node has a corresponding PCL, and the corresponding PCL1 of T1 includes p1, and the corresponding PCL2 of T2 includes p2, the corresponding PCL3 of T3 Including p3 and p4, the corresponding PCL4 of T4 includes p5 and p6.The format of PCL can be as shown in table 1:
PCL1:0000100
PCL2:001,0010000
PCL3:101,1010000
PCL4:001,001,0010100
Table 1
7 bit digitals in table 1 are corresponding bitmap.3 bit digitals are corresponding prefix.
Assuming that Prefix node is 256, each next-hop confidence (RE Index) accounts for 20, then comprising as shown in Figure 8 The structure of the Prefix node of 6 prefixes is as shown in figure 9, Fig. 9 is a kind of Prefix section provided in an embodiment of the present invention in example The node structure schematic diagram of point.Wherein, Seg Num is used to identify the number of preposition segmentation in the PCL;Prefix Bitmap is used Which prefix is existing in the expression PCL;The preposition segmentation of seg0~segn preservation PCL.
Embodiment two
Figure 10 is a kind of structure drawing of device of data processing equipment provided in an embodiment of the present invention, is applied to multidigit tree, institute Stating includes multiple route prefix in multidigit tree, and the data processing equipment 1000 includes:
Acquiring unit 1001 includes at least one tree Trie node in the structure for obtaining the multidigit tree and corresponding Prefix Prefix node, the capacity of the Prefix node are less than or equal to preset capacity, the Prefix node include it is current most The next hop information of route prefix in long prefix matching PLPM, the route prefix in corresponding Trie node and corresponding Trie node, First Trie node is any Trie node at least one described Trie node, and the first Trie node includes corresponding Bitmap, the corresponding Prefix node of the first Trie node includes direct Prefix node and indirect Prefix node, institute State in direct Prefix node include the first Trie node in route prefix, the direct Prefix node PLPM and The next hop information of route prefix in the first Trie node, the indirect Prefix node include the first Trie section It is connected under the PLPM and the first Trie node of the route prefix in Trie node, the indirect Prefix that are connected under point Trie node in route prefix next hop information.
It should be noted that each Trie node has an associated prefixes.In the same manner, each Prefix node also has one A associated prefixes.The associated prefixes of the direct Prefix node of one Trie node are identical with the associated prefixes of the Trie node; The associated prefixes of the indirect Prefix node of one Trie node are identical with the associated prefixes of corresponding Trie node.One The associated prefixes of the Trie child node of Trie node and the associated prefixes of its indirect Prefix node are different.It is described to obtain Take unit 1001 that the method in embodiment one such as S301 can be implemented.Which is not described herein again.
Iteration unit 1002, for being iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to The preset capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, according to the structure of the new multidigit tree Obtain Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
The method in embodiment one such as S302 can be implemented in the iteration unit 1002.Which is not described herein again.
Corresponding next hop information is also directly saved in the Prefix node provided in the embodiment of the present invention, further Reduce memory access number.
Second multidigit tree can be made all Prefix nodes using the identical method with first multidigit tree To search the level-one of assembly line, and it is inserted into third multidigit tree using their associated prefixes as new prefix.Class according to this It pushes away, by creating more multidigit trees, that is, progress successive ignition, to the last a multidigit tree is smaller, can be placed on Until in cache.Final lookup structure is made of the last one Trie node and multistage Prefix node.
For the preset capacity it should be noted that the preset capacity is determined according to the cache size of processing system. In general, if the cache line of CPU is 512, the maximum of Prefix node can be set as 512, to improve Memory access efficiency.
As can be seen from the above-described embodiment, by the iterative operation to multidigit tree, so that total appearance of the multidigit tree after iteration Amount is less than or equal to preset capacity, is more suitable and deposits in caching, and directly protects in the Prefix node of the multidigit tree after iteration The next hop information for having deposited route prefix in current longest prefix match PLPM and corresponding Trie node, so that in route querying Corresponding next hop information can be directly obtained when obtaining matching result in the process, reduces and is also needed again in script when searching Secondary memory access thereby reduces the memory access number of route querying to obtain the process of next hop information, decreases cache failure Number directly enhances search efficiency.
Next by the route querying structure progress route querying to how to be established using embodiment as shown in Figure 10.? On the basis of embodiment corresponding to Figure 10, Figure 11 is a kind of apparatus structure of device for searching route provided in an embodiment of the present invention Figure, the device for searching route 1100 include:
Receiving unit 1101, for obtaining routing address to be found.
Matching unit 1102, for according to the routing address to be found since the multidigit tree that last time iteration obtains Carry out longest prefix match LPM, the bitmap for being included according to the Prefix node being matched to and the routing address to be found Determine the Prefix node in last time iteration in multidigit tree;
The matching unit is also used to carry out circulation matching, until in the multidigit tree that matching result is before being matched to non-iteration Prefix node or occur without matching prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described Routing address to be found determines the Prefix node in the multidigit tree obtained in the N-1 times iteration;
If the matching result of the matching unit 1102 is the Prefix section in the multidigit tree before being matched to non-iteration Point, determination unit 1103, for by the Prefix node in the multidigit tree before the non-iteration with the routing to be found ground Next hop information of the next hop information of the matched route prefix in location as the routing address to be found;
If the matching result of the matching unit 1102 is to occur without matching prefix, the determination unit 1103 is also used The next hop information of the route prefix corresponding to the PLPM that the Prefix node without matching prefix will occur is as described to be found The next hop information of routing address.
The determination unit 1103 is illustrated by taking Fig. 5 c as an example.Assuming that routing address to be found is 00111010011, Search Fig. 5 c shown in multidigit tree, since first order T21, find PLPM be 00*, according to T21 save bitmap and this to Search routing address, determine second level P23, the PLPM found in P23 be 00111010*, according to P23 save bitmap and The routing address to be found, determines third level P7, and the PLPM found out in P7 is 001110100*, corresponding prefix p10, with Next hop information of the p10 next hop information of preservation as the routing address to be found.This lookup situation is similar to work as Described in when the matching result of the matching unit 1102 is the Prefix node in the multidigit tree before being matched to non-iteration Operation with unit 1102.
If the routing address to be found is 00111010111.In search procedure, the identified second level is also P23, The PLPM found in P23 is 00111010*, according to bitmap and the routing address to be found that P23 is saved, determines the third level P7, but the matching result in third level P7 is five matching prefixes, therefore by the PLPM of P7, that is, the prefix of p27 in P23 Next hop information of the next hop information as the routing address to be found.This lookup situation is similar to when the matching is single The matching result of member 1102 is the operation of the matching unit 1102 when occurring without matching prefix.
Next, a kind of device of simplified multidigit tree construction provided in an embodiment of the present invention is further described, optionally, On the basis of embodiment corresponding to Figure 10, Figure 12 is a kind of apparatus structure of data processing equipment provided in an embodiment of the present invention Figure, the data processing equipment 1000 further include:
Processing unit 1003, for using multiple Trie nodes in multidigit tree in same single connection structure as one Trie node processing, the single connection structure is specifically included in the connection structure of the multidigit tree only to be connected under a Trie node Connect the structure of a Trie node.
For example, when Trie structure is relatively simple Trie in same single connection structure can be in by multiple Node is accordingly saved as a node, can be by multistage Trie node pressure when Trie node is list connection It is condensed to a Skip node.One Skip node can have most 2Step-lengthA Trie child node and most 1 Prefix child node. For Skip node, the structure for indexing Trie child node is identical with general T rie node;And it is used to index Prefix section The structure of point only needs the address of 1 bitmap and child node.
Next, the embodiment of the invention also provides before the routing in a kind of preferred preservation PLPM, corresponding Trie node Sew and correspond to the mode of the next hop information of route prefix in Trie node.Optionally, the Prefix node passes through at least one The next hop information of route prefix, institute in a PCL storage PLPM, the route prefix in corresponding Trie node and corresponding Trie node It states PCL and Trie node corresponds.
Those of ordinary skill in the art will appreciate that: realize that all or part of the steps of above method embodiment can pass through The relevant hardware of program instruction is completed, and foregoing routine can be stored in a computer readable storage medium, which exists When execution, step including the steps of the foregoing method embodiments is executed;And storage medium above-mentioned can be at least one in following media Kind: read-only memory (Read-Only Memory, ROM), RAM, magnetic or disk etc. be various to can store program code Medium.
It should be noted that all the embodiments in this specification are described in a progressive manner, each embodiment it Between same and similar part may refer to each other, each embodiment focuses on the differences from other embodiments. For equipment and system embodiment, since it is substantially similar to the method embodiment, so describe fairly simple, The relevent part can refer to the partial explaination of embodiments of method.Equipment and system embodiment described above is only schematic , wherein unit may or may not be physically separated as illustrated by the separation member, it is shown as a unit Component may or may not be physical unit, it can and it is in one place, or may be distributed over multiple networks On unit.Some or all of the modules therein can be selected to achieve the purpose of the solution of this embodiment according to the actual needs. Those of ordinary skill in the art can understand and implement without creative efforts.
The above is only a preferred embodiment of the present invention, it is not intended to limit the scope of the present invention.It should refer to Out, for those skilled in the art, without departing from the principle of the present invention, can also make several Improvements and modifications, these modifications and embellishments should also be considered as the scope of protection of the present invention.

Claims (10)

1. a kind of data processing method, which is characterized in that it is applied to multidigit tree, includes multiple route prefix in the multidigit tree, The described method includes:
Obtaining in the structure of the multidigit tree includes that at least one sets Trie node and corresponding prefix Prefix node, described The capacity of Prefix node is less than or equal to preset capacity, and the Prefix node includes current longest prefix match, corresponding Trie The next hop information of route prefix in route prefix and corresponding Trie node in node, the first Trie node is described at least one Any Trie node in a Trie node, the first Trie node includes corresponding bitmap, the first Trie node pair The Prefix node answered includes direct Prefix node and indirect Prefix node, includes institute in the direct Prefix node State route prefix in the first Trie node, the current longest prefix match of the direct Prefix node and the first Trie The next hop information of route prefix in node, the indirect Prefix node include connecting under the first Trie node Connect under the current longest prefix match of route prefix, the indirect Prefix in Trie node and the first Trie node The next hop information of route prefix in the Trie node connect;
It is iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to the preset capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, is obtained according to the structure of the new multidigit tree Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
2. the method according to claim 1, wherein further include:
Obtain routing address to be found;
Longest prefix match LPM is carried out since the multidigit tree that last time iteration obtains according to the routing address to be found, The bitmap and the routing address to be found for being included according to the Prefix node being matched to determine multidigit in last iteration Prefix node in tree;
Circulation matching is carried out, until the Prefix node in the multidigit tree that matching result is before being matched to non-iteration or nothing occurs With prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described to be checked Routing address is looked for determine the Prefix node in the multidigit tree obtained in the N-1 times iteration;
If the matching result is the Prefix node in the multidigit tree before being matched to non-iteration, will be more before the non-iteration In Prefix node in the tree of position with the next hop information of the matched route prefix of routing address to be found as it is described to Search the next hop information of routing address;
If the matching result is to occur without matching prefix, before the current longest for the Prefix node without matching prefix occur Sew next hop information of the next hop information for matching corresponding route prefix as the routing address to be found.
3. the method according to claim 1, wherein further include:
Using multiple Trie nodes in multidigit tree in same single connection structure as a Trie node processing, the single connection Structure is specifically included in the structure of one Trie node of a Trie node lower connection in the connection structure of the multidigit tree.
4. the method according to claim 1, wherein further include:
The Prefix node stores current longest prefix match by least one prefix cluster PCL, corresponds in Trie node The next hop information of route prefix, the PCL and Trie node correspond in route prefix and corresponding Trie node.
5. method according to any one of claims 1 to 4, which is characterized in that
The preset capacity is determined according to the cache size of processing system.
6. a kind of data processing equipment, which is characterized in that it is applied to multidigit tree, includes multiple route prefix in the multidigit tree, The data processing equipment includes:
Acquiring unit includes at least one tree Trie node and corresponding prefix in the structure for obtaining the multidigit tree Prefix node, the capacity of the Prefix node are less than or equal to preset capacity, before the Prefix node includes current longest Sew matching, the route prefix in corresponding Trie node and the next hop information for corresponding to route prefix in Trie node, the first Trie Node is any Trie node at least one described Trie node, and the first Trie node includes corresponding bitmap, institute Stating the corresponding Prefix node of the first Trie node includes direct Prefix node and indirect Prefix node, it is described directly Current longest-prefix including route prefix, the direct Prefix node in the first Trie node in Prefix node The next hop information of route prefix in matching and the first Trie node, the indirect Prefix node includes described first The current longest prefix match of the route prefix in Trie node, the indirect Prefix that are connected under Trie node and described The next hop information of route prefix in the Trie node connected under first Trie node;
Iteration unit, for being iterated operation, the total capacity of the multidigit tree obtained after iteration is less than or equal to described default Capacity;
The primary iterative operation specifically:
New multidigit tree is established using the associated prefixes of obtained Prefix node, is obtained according to the structure of the new multidigit tree Trie node and corresponding Prefix node, and corresponding corresponding bitmap before saving current iteration.
7. device according to claim 6, which is characterized in that further include:
Receiving unit, for obtaining routing address to be found;
Matching unit, for carrying out longest since the multidigit tree that last time iteration obtains according to the routing address to be found Prefix matching LPM, the bitmap for being included according to the Prefix node being matched to and the routing address to be found determine upper one Prefix node in secondary iteration in multidigit tree;
The matching unit is also used to carry out circulation matching, until in the multidigit tree that matching result is before being matched to non-iteration Prefix node occurs without matching prefix;
The circulation matching specifically:
The bitmap that is included according to the obtained Prefix node of multidigit tree matching obtained in iv-th iteration and described to be checked Routing address is looked for determine the Prefix node in the multidigit tree obtained in the N-1 times iteration;
If the matching result of the matching unit is the Prefix node in the multidigit tree before being matched to non-iteration, determine single Member, for will be in the Prefix node in the multidigit tree before the non-iteration and before the matched routing of routing address to be found Next hop information of the next hop information sewed as the routing address to be found;
If the matching result of the matching unit is to occur without matching prefix, the determination unit is also used to nothing occur The next hop information of route prefix corresponding to the current longest prefix match of Prefix node with prefix is as described to be found The next hop information of routing address.
8. device according to claim 6, which is characterized in that further include:
Processing unit, for using multiple Trie nodes in multidigit tree in same single connection structure as a Trie node at Reason, the single connection structure are specifically included in one Trie of a Trie node lower connection in the connection structure of the multidigit tree The structure of node.
9. device according to claim 6, which is characterized in that
The Prefix node stores current longest prefix match by least one prefix cluster PCL, corresponds in Trie node The next hop information of route prefix, the PCL and Trie node correspond in route prefix and corresponding Trie node.
10. according to the described in any item devices of claim 6 to 9, which is characterized in that
The preset capacity is determined according to the cache size of processing system.
CN201410851108.1A 2014-12-31 2014-12-31 A kind of data processing method and device Expired - Fee Related CN105812258B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410851108.1A CN105812258B (en) 2014-12-31 2014-12-31 A kind of data processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410851108.1A CN105812258B (en) 2014-12-31 2014-12-31 A kind of data processing method and device

Publications (2)

Publication Number Publication Date
CN105812258A CN105812258A (en) 2016-07-27
CN105812258B true CN105812258B (en) 2019-02-12

Family

ID=56421526

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410851108.1A Expired - Fee Related CN105812258B (en) 2014-12-31 2014-12-31 A kind of data processing method and device

Country Status (1)

Country Link
CN (1) CN105812258B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111953606B (en) * 2020-07-14 2022-06-21 锐捷网络股份有限公司 Routing iteration loop detection method and device, electronic equipment and storage medium
CN116389346A (en) * 2023-04-11 2023-07-04 烽火通信科技股份有限公司 Route iteration method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7212531B1 (en) * 2001-11-27 2007-05-01 Marvell Semiconductor Israel Ltd. Apparatus and method for efficient longest prefix match lookup
CN101459569A (en) * 2008-12-12 2009-06-17 华为技术有限公司 Method, apparatus for establishing route index tree and method, apparatus for searching route index tree
CN103051543A (en) * 2012-11-01 2013-04-17 广州微仕科信息技术有限公司 Route prefix processing, lookup, adding and deleting method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7212531B1 (en) * 2001-11-27 2007-05-01 Marvell Semiconductor Israel Ltd. Apparatus and method for efficient longest prefix match lookup
CN101459569A (en) * 2008-12-12 2009-06-17 华为技术有限公司 Method, apparatus for establishing route index tree and method, apparatus for searching route index tree
CN103051543A (en) * 2012-11-01 2013-04-17 广州微仕科信息技术有限公司 Route prefix processing, lookup, adding and deleting method

Also Published As

Publication number Publication date
CN105812258A (en) 2016-07-27

Similar Documents

Publication Publication Date Title
CN102484610B (en) Routing table construction method and device and routing table lookup method and device
CN101577662B (en) Method and device for matching longest prefix based on tree form data structure
US8325721B2 (en) Method for selecting hash function, method for storing and searching routing table and devices thereof
US6594655B2 (en) Wildcards in radix- search tree structures
CN103561133B (en) A kind of IP address attribution information index method and method for quickly querying
US7852852B2 (en) Method for compressing route data in a router
CN102405623B (en) Method and device for storing routing table entry
CN105122745A (en) Efficient longest prefix matching techniques for network devices
CN103051543B (en) A kind of process of route prefix, search, increase and delet method
CN103780491B (en) A kind of method for realizing IPv6 fast routing lookups
US20050083937A1 (en) IP address lookup method using pipeline binary tree, hardware architecture, and recording medium
CN105677683A (en) Batch data query method and device
CN108134739B (en) Route searching method and device based on index trie
CN102045412B (en) Method and equipment for carrying out compressed storage on internet protocol version (IPv)6 address prefix
CN105141525A (en) IPv6 routing lookup method and IPv6 routing lookup device
CN106416152A (en) Lookup device, lookup configuration method and lookup method
WO2014047863A1 (en) Generating a shape graph for a routing table
CN107872388A (en) For realizing the methods, devices and systems of message forwarding
CN100496019C (en) A method to quickly search and update IPv6 routing list
CN105812258B (en) A kind of data processing method and device
CN102930011B (en) The processing method and processing device of stream forwarding list item
CN105227468B (en) A kind of lookup device, lookup method and configuration method
CN118227518B (en) Table entry storage and searching method and device, network equipment and storage medium
CN102984071B (en) Method for organizing routing table of segment address route and method for checking route
CN110119495A (en) Conversion method, system, computer equipment and the medium of digit strings

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20190212

Termination date: 20201231

CF01 Termination of patent right due to non-payment of annual fee