JP2002208947A - Route retrieval system and its method and route recording medium with route retrieval program recorded - Google Patents

Route retrieval system and its method and route recording medium with route retrieval program recorded

Info

Publication number
JP2002208947A
JP2002208947A JP2001004643A JP2001004643A JP2002208947A JP 2002208947 A JP2002208947 A JP 2002208947A JP 2001004643 A JP2001004643 A JP 2001004643A JP 2001004643 A JP2001004643 A JP 2001004643A JP 2002208947 A JP2002208947 A JP 2002208947A
Authority
JP
Japan
Prior art keywords
node
search
block
entry
bit information
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.)
Granted
Application number
JP2001004643A
Other languages
Japanese (ja)
Other versions
JP3589349B2 (en
Inventor
Fumikazu Kanehara
史和 金原
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.)
NEC Corp
Original Assignee
NEC 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 NEC Corp filed Critical NEC Corp
Priority to JP2001004643A priority Critical patent/JP3589349B2/en
Publication of JP2002208947A publication Critical patent/JP2002208947A/en
Application granted granted Critical
Publication of JP3589349B2 publication Critical patent/JP3589349B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Abstract

PROBLEM TO BE SOLVED: To provide a route retrieval system capable of simultaneously reducing the number of times of access to a memory and the required memory capacity. SOLUTION: In a route retrieval system for deciding a transfer destination address based on the target address of an IP packet, a target address is divided into a plurality of blocks with equal length from the leading, and each block is branched from the leading successively from the upper rank hierarchy to the lower rank hierarchy and linked so that a tree structural table can be prepared. This table is allowed to store the data of the blocks indicating each lower rank node entry linked from the pertinent node and bit position designation bit information in the blocks to be collated at the time of extracting each lower rank node entry, and the node entry pertinent to each block obtained by dividing the target address to be retrieved is successively retrieved so that the entry pertinent to the target address to be retrieved in the retrieval table can be retrieved.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、IPパケットの経
路選択に関し、特にIPv6等において目的アドレスか
ら転送先アドレスを効率よく検索する経路検索システム
とその検索方法、及び経路検索プログラムを記録した記
録媒体に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a route selection for an IP packet, and more particularly to a route search system and a search method for efficiently searching for a destination address from a target address in IPv6 or the like, and a recording medium storing a route search program. About.

【0002】[0002]

【従来の技術】インターネットにおいて、IP(Intern
et Protocol)パケットをルータなどの中継装置で転送
する場合に、中継装置は、IPヘッダに含まれる目的ア
ドレスに基づいて、次の転送先のIPアドレス(以下、
転送先アドレスと呼ぶ)を決定する。この処理を、経路
検索という。
2. Description of the Related Art In the Internet, IP (Intern)
et Protocol), when a packet is transferred by a relay device such as a router, the relay device determines the next transfer destination IP address (hereinafter, referred to as the destination address) based on the destination address included in the IP header.
(Referred to as a transfer destination address). This process is called a route search.

【0003】中継装置は、目的アドレスと転送先アドレ
スを関連付ける検索テーブルを備え、入力されるIPパ
ケットである各目的アドレス毎にその対応する転送先ア
ドレスを検索テーブル内から検索することにより、転送
先を決定することができる。
The relay apparatus has a search table for associating a destination address with a transfer destination address. For each destination address, which is an input IP packet, the corresponding transfer destination address is searched from the search table to obtain a transfer destination address. Can be determined.

【0004】表1では、IPv4(Internet Protocol
Version 4)の検索テーブルの一例を示している。
In Table 1, IPv4 (Internet Protocol)
An example of the search table of Version 4) is shown.

【0005】[0005]

【表1】 [Table 1]

【0006】表1における「ネットワークアドレス」及
び「マスク長」は、目的アドレスがどのネットワークに
属するかを示すものであり、このエントリ番号が1〜3
の3種類の目的アドレスのそれぞれに、対応する転送先
アドレスが示されている。
[0006] "Network address" and "mask length" in Table 1 indicate which network the target address belongs to.
The corresponding destination address is shown for each of the three types of destination addresses.

【0007】マスク長は、例えばその値が“N”の場合
には、32ビット中の上位Nビットが“1”であること
を示す。つまり、マスク長が“24”の場合には、ヘキ
サ表記(16進表記)で“0xFFFFFF00”に相
当するのであり、これをネットマスクと呼ぶ。
[0007] The mask length, for example, when its value is "N", indicates that the upper N bits of 32 bits are "1". That is, when the mask length is “24”, it corresponds to “0xFFFFFF00” in hexadecimal notation (hexadecimal notation), and this is called a net mask.

【0008】これは、目的アドレスと、マスク長で示さ
れるネットマスクとの論理積が、同エントリのネットワ
ークアドレスと一致するかどうかで判断するのである。
例えば、目的アドレスが“11.1.1.5”の場合に
は、この目的アドレスとマスク長が“24”のネットマ
スクとの論理積を取ると、3番目のエントリに示される
“11.1.1.0”に等しいため、これにより3番目
のエントリに属すると判定する。
[0008] This is determined based on whether or not the logical product of the target address and the net mask indicated by the mask length matches the network address of the same entry.
For example, when the target address is “11. 1.1.5”, the logical product of the target address and the netmask having the mask length of “24” is “11. 1.1.0 ", so that it is determined that it belongs to the third entry.

【0009】図13は、従来の経路検索の処理を説明す
るためのフローチャートである。ここで、表1の検索テ
ーブルを装備する中継装置に、“10.1.0.1”の
目的アドレスを持つIPパケットが入力された場合を考
える。この場合、入力されたパケットの目的アドレスに
該当するエントリとして、1番目と2番目との2つのエ
ントリが該当することになる。
FIG. 13 is a flowchart for explaining a conventional route search process. Here, a case is considered where an IP packet having a target address of “10.1.1.0” is input to the relay device equipped with the search table of Table 1. In this case, the first and second entries correspond to the entry corresponding to the destination address of the input packet.

【0010】このような場合、中継装置は、目的アドレ
スが属するネットワークアドレスを備えるエントリの内
で、マスク長が最長のものを検索結果とする。これは、
最長一致検索(LPM)と呼ばれる方法である。
[0010] In such a case, the relay device determines the entry having the longest mask length among the entries including the network address to which the destination address belongs as the search result. this is,
This is a method called longest match search (LPM).

【0011】この最長一致検索により、中継装置は、目
的アドレスに該当する1番目と2番目のエントリの内
で、マスク長の長い2番目のエントリを選択し、そのエ
ントリの転送先アドレスである“21.1.1.1”の
IPアドレスに、このIPパケットを転送するのであ
る。
By the longest match search, the relay device selects the second entry having the longer mask length from the first and second entries corresponding to the destination address, and determines the transfer destination address of the entry. This IP packet is transferred to the IP address 21.1.1.1 ".

【0012】このように、IPパケットの経路検索で
は、1つの検索において検索基準を満たす候補が複数存
在する可能性があり、最長一致検索等により正しい検索
結果を導出しなければならない。これは入力IPパケッ
トの目的アドレスのみからでは、その目的アドレスが属
するネットワークアドレスがわからないことに起因す
る。
As described above, in the route search of the IP packet, there is a possibility that a plurality of candidates satisfying the search criteria exist in one search, and a correct search result must be derived by a longest match search or the like. This is because the network address to which the destination address belongs cannot be known from only the destination address of the input IP packet.

【0013】この課題を踏まえて、検索テーブル及び検
索処理の実装方法として、いくつかの方法が提案されて
おりその1つに2分木を用いた方法がある。
In view of this problem, several methods have been proposed as mounting methods for a search table and a search process, one of which is a method using a binary tree.

【0014】2分木を用いる方法は、ソフトウェア実装
では一般的であり、また特開平11−191781号公
報においてはハードウェアへの実装方法も提案されてい
る。
A method using a binary tree is generally used for software implementation, and Japanese Patent Application Laid-Open No. H11-191781 proposes a method for implementation on hardware.

【0015】図11に、2分木の例を示す。図11中の
各矩形を2分木のノードと呼ぶ。
FIG. 11 shows an example of a binary tree. Each rectangle in FIG. 11 is called a binary tree node.

【0016】2分木は、ビット“0”/“1”に従って
分岐する構成をとり、各分岐が目的アドレスのビットに
相当する。つまり図11の例では、根ノードを開始点と
して、目的アドレスの最上位ビットが“0”の場合は左
のノードに進み、“1”の場合は右のノードに進む。各
ノードは、実際には回路上のメモリ空間に相当し、そこ
には最長一致検索に関する情報が含まれているので、そ
の情報を参照して検索処理を進めることができる。
The binary tree has a configuration of branching according to bits "0" / "1", and each branch corresponds to a bit of a target address. That is, in the example of FIG. 11, when the most significant bit of the destination address is “0”, the process proceeds to the left node, and when the most significant bit of the destination address is “1”, the process proceeds to the right node. Each node actually corresponds to a memory space on the circuit, and contains information on the longest match search, so that the search process can be performed with reference to the information.

【0017】この2分木の方法は、最長一致検索に効率
よく対応できるので、ソフトウェアやFPGAによる実
装に適している。また収容できる経路エントリ数に関し
ても有利である。ただし、登録されるエントリによって
は最悪32ビット全てを検査する必要があり、それだけ
メモリへのアクセス回数が増加する傾向がある。特に1
28ビットのアドレス空間を持つIPv6では、効率が
悪い。
The binary tree method can efficiently cope with the longest match search, and is suitable for implementation by software or FPGA. It is also advantageous in terms of the number of route entries that can be accommodated. However, depending on the entry to be registered, it is necessary to check all 32 bits at the worst, and the number of accesses to the memory tends to increase accordingly. Especially 1
IPv6 with a 28-bit address space is inefficient.

【0018】一方、IPv6(Internet Protocol Vers
ion 6)は、主に8ビット単位の階層構造を念頭に設計
されているので、マスク長は8ビット単位と想定してよ
い。たとえ、8ビット単位でないマスク長を設定する必
要が生じても、それを8ビット長に展開して設定すれば
よい。
On the other hand, IPv6 (Internet Protocol Vers.
Since the ion 6) is designed mainly with an 8-bit hierarchical structure in mind, the mask length may be assumed to be an 8-bit unit. Even if it is necessary to set a mask length other than the 8-bit unit, the mask length may be expanded to an 8-bit length and set.

【0019】例えば、ネットワークアドレスが“10.
10.64.0”でマスク長が20ビットのエントリを
設定する場合、“10.10.64.0”、“10.1
0.65.0”、“10.10.66.0”、・・・、
“10.10.79.0”の16エントリを、マスク長
24ビットで設定すればよいことになる。
For example, if the network address is "10.
In the case of setting an entry having a mask length of 20 bits at 10.64.0, "10.10.64.0", "10.1
0.65.0 "," 10.10.66.0 ", ...,
This means that 16 entries of “10.10.79.0” may be set with a mask length of 24 bits.

【0020】ここではIPv4のアドレス例を用いた
が、IPv4ではアドレス空間が狭いため、8ビット長
単位以外のマスク長でエントリを設定する場合は多く、
このような展開処理が頻発してしまう可能性がある。し
かしIPv6ではアドレス空間が広く、8ビット単位の
アドレス階層が推奨されているので、このような展開処
理の必要性は低くなる。よって、この展開処理を想定し
た上で、マスク長が8ビット単位であることを前提とし
た経路検索が可能となる。
Here, the address example of IPv4 is used, but since the address space is small in IPv4, entries are often set with a mask length other than the 8-bit length unit.
Such expansion processing may occur frequently. However, in IPv6, since the address space is wide and an address hierarchy in units of 8 bits is recommended, the necessity of such expansion processing is reduced. Therefore, it is possible to perform a route search on the assumption that the mask length is in units of 8 bits, assuming this expansion processing.

【0021】そこで、2分木を用いないで、図12に示
すような256分木で対応することが考えられる。つま
りノードの分岐は、IPアドレスの8ビット毎に行われ
る。このため、2分木で最悪8回ノードを辿らなければ
ならないところが、1回に減る。これはメモリアクセス
の回数が減ることに相当し、検索の速度が速くなること
を意味する。
Therefore, it is conceivable to use a 256-ary tree as shown in FIG. 12 instead of using a binary tree. That is, branching of the node is performed for every 8 bits of the IP address. For this reason, the number of times the node must be traced eight times in the binary tree is reduced to one. This corresponds to a reduction in the number of memory accesses, which means that the search speed is increased.

【0022】ただし、256分木の欠点は多くのメモリ
空間を必要とすることである。2分木の場合は左右分岐
のための情報を1つのノードに含めておけばよいが、2
56分木の場合はその256分岐のための情報を格納し
ておく必要がある。実際には2分岐しかしない場合にお
いても、256分岐のための空間を用意する必要があ
る。そのため、メモリ不足のためにエントリ数の上限が
抑えられるという欠点がある。
However, a disadvantage of the 256-ary tree is that it requires a lot of memory space. In the case of a binary tree, information for left and right branches may be included in one node.
In the case of a 56-ary tree, it is necessary to store information for the 256 branches. Even when there are actually only two branches, it is necessary to provide a space for 256 branches. Therefore, there is a disadvantage that the upper limit of the number of entries can be suppressed due to a shortage of memory.

【0023】[0023]

【発明が解決しようとする課題】上述したように従来の
IPパケットの経路検索では、以下に述べるような問題
点があった。
As described above, the conventional route search of an IP packet has the following problems.

【0024】従来のIPパケットの経路検索方法である
2分木の方法では、登録されるエントリによっては32
ビットの全てのビットを検査する必要があり、メモリへ
のアクセス回数を多く必要とするという問題点がある。
In the binary tree method, which is a conventional IP packet route search method, depending on the entry to be registered, 32
There is a problem in that all bits of the bits need to be checked, and the number of times of access to the memory is required.

【0025】従来のIPパケットの経路検索方法である
256分木の方法では、256種類の分岐のための多く
のメモリ空間を用意する必要があり、エントリ数の上限
が抑えられるという問題点がある。
[0025] In the 256-tree method, which is a conventional IP packet path search method, it is necessary to prepare a large amount of memory space for 256 kinds of branches, and there is a problem that the upper limit of the number of entries can be suppressed. .

【0026】本発明の目的は、上記従来技術の欠点を解
決し、複数の検索方法を適切に組み合わせることによ
り、メモリへのアクセス回数と必要とするメモリ容量と
の双方を同時に少なく抑えることを実現する経路検索シ
ステムとその検索方法、及び経路検索プログラムを記録
した記録媒体を提供することである。
An object of the present invention is to solve the above-mentioned drawbacks of the prior art and realize that both the number of accesses to the memory and the required memory capacity are simultaneously reduced by appropriately combining a plurality of search methods. It is an object to provide a route search system, a search method thereof, and a recording medium storing a route search program.

【0027】[0027]

【課題を解決するための手段】上記目的を達成するため
本発明の経路検索システムは、IPパケットの目的アド
レスを基に転送先アドレスを決定する経路検索システム
において、前記目的アドレスによる木構造の探索を行な
うための、個々の目的アドレスのそれぞれに対応する転
送先アドレスを示す検索テーブルを備え、前記検索テー
ブルの各ノードにおける下位のノードエントリの探索
を、各前記ノードのそれぞれの前記ノードエントリの数
に対応して指定された種類の多分木の探索方法を用いて
探索することを特徴とする。
In order to achieve the above object, a route search system according to the present invention is a route search system for determining a transfer destination address based on a destination address of an IP packet. A search table indicating a transfer destination address corresponding to each of the individual destination addresses, and searching for a lower node entry in each node of the search table by the number of the node entries of each of the nodes. The search is performed using a search method for a multi-tree of the type specified in correspondence with.

【0028】請求項2の本発明の経路検索システムは、
前記検索テーブルは、前記目的アドレスをその先頭から
複数個の等長のブロックに分割し、各前記ブロックを先
頭から順次、上位の階層から下位の階層に枝分かれさせ
て結ぶ階層構造による木構造を有し、各ノードにおい
て、当該ノードからリンクする下位の各ノードエントリ
を示すブロックのデータの記録と、前記下位の各ノード
エントリの抽出時において照合する前記ブロック内のビ
ット位置の指定を示す指定ビット情報の記録を備えるこ
とを特徴とする。
The route search system according to the second aspect of the present invention
The search table has a tree structure based on a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and the blocks are sequentially branched from an upper hierarchy to a lower hierarchy from the beginning. At each node, data of a block indicating each lower node entry linked from the node is recorded, and designation bit information indicating designation of a bit position in the block to be collated at the time of extracting each lower node entry Characterized by having a record of:

【0029】請求項3の本発明の経路検索システムは、
各ノードにおいて、前記検索対象の目的アドレスを分割
した各ブロックと、当該ノードからリンクする下位の各
ノードエントリの前記ブロックとを、前記指定ビット情
報に示される位置の各ビットのデータを参照して照合
し、該当する前記ノードエントリを抽出するノード読み
出し部と、前記指定ビット情報に指定されていない位置
のビットのデータの照合を行なうことにより、前記ノー
ド読み出し部により読み出された前記ノードエントリ
が、正しく前記検索対象の目的アドレスを分割したブロ
ックに該当するか否かを判定するノード判定部を備え、
各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索すること
を特徴とする。
A route search system according to a third aspect of the present invention
In each node, each block obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are referred to by referring to the data of each bit at the position indicated by the designated bit information. The node entry read out by the node reading unit is checked by comparing the data of a bit at a position not specified in the specified bit information with the node reading unit that checks and extracts the corresponding node entry. A node determination unit that determines whether the target address of the search target correctly corresponds to a divided block,
In each node, by sequentially searching for the node entry corresponding to each of the blocks obtained by dividing the target address of the search target, an entry corresponding to the target address of the search target in the search table is searched. And

【0030】請求項4の本発明の経路検索システムは、
前記検索テーブルの各前記ノードにおける前記指定ビッ
ト情報を、当該指定ビット情報において指定されたビッ
ト位置において示されるデータのみにより、各前記ノー
ドからリンクする下位のノードエントリが一意に識別さ
れるように予め設定し備えることを特徴とする。
According to a fourth aspect of the present invention, there is provided a route search system comprising:
The designated bit information in each of the nodes of the search table is previously set so that a lower node entry linked from each of the nodes is uniquely identified only by data indicated at a bit position designated in the designated bit information. It is characterized by setting and preparing.

【0031】請求項5の本発明の経路検索システムは、
前記ノード判定部は、検索対象の前記ブロックに該当す
る前記ノードエントリを、定められた個数である複数
個、まとめて一度に抽出する手段を備え、前記ノード判
定部は、前記抽出された各ノードエントリのそれぞれ
を、当該検索対象の前記ブロックに該当するか否かを判
定し、正しく該当する前記ノードエントリを検出するこ
とを特徴とする。
A route search system according to a fifth aspect of the present invention
The node determining unit includes a unit that extracts the node entries corresponding to the block to be searched for a predetermined number of pieces at once, and the node determining unit includes: It is characterized in that it is determined whether or not each of the entries corresponds to the block to be searched, and the node entry that correctly corresponds is detected.

【0032】請求項6の本発明の経路検索システムは、
前記検索テーブルの各前記ノードにおける前記指定ビッ
ト情報を、当該指定ビット情報において指定されたビッ
ト位置において示されるデータのみにより探索した場合
において、各前記ノードからリンクする下位のノードエ
ントリの当該探索時に重複して該当する個数を、高々、
前記ノード判定部が前記ノードエントリを一度にまとめ
て取り出すことのできる前記定められた個数以下になる
ように予め設定し備え、前記検索テーブルは、各前記ノ
ードにおける前記ノードエントリを、各前記指定ビット
情報毎に、当該指定ビット情報を用いた探索時に重複し
て該当する前記ノードエントリをまとめて記録し備える
ことを特徴とする。
A route search system according to a sixth aspect of the present invention comprises:
When the specified bit information in each of the nodes in the search table is searched for only by the data indicated at the bit position specified in the specified bit information, the lower node entry linked from each of the nodes is duplicated during the search. And the applicable number at most,
The node determination unit is set in advance so as to be equal to or less than the predetermined number at which the node entries can be collectively taken out at one time, and the search table stores the node entry in each of the nodes by each of the designated bits. The method is characterized in that, for each piece of information, the corresponding node entries are collectively recorded and provided so as to be duplicated during a search using the designated bit information.

【0033】請求項7の本発明の経路検索システムは、
IPv6のIPパケットの経路検索を行なうことを特徴
とする。
The route search system of the present invention according to claim 7 is
It is characterized in that a route search of an IPv6 IP packet is performed.

【0034】請求項8の本発明の経路検索システムは、
前記目的アドレスのサイズを128ビットとし、前記ブ
ロックのサイズを8ビットとし、前記検索テーブルは、
各前記目的アドレスを16個の前記ブロックに分割する
ことによる16階層の木構造とする、ことを特徴とす
る。
The route search system of the present invention according to claim 8 is
The size of the destination address is 128 bits, the size of the block is 8 bits, and the search table is:
Each destination address is divided into 16 blocks to form a 16-layer tree structure.

【0035】請求項9の本発明の経路検索システムは、
前記指定ビット情報は、前記ノード読み出し部が前記ノ
ードエントリの抽出時に照合する前記ブロック中のビッ
ト位置の指定を、当該ブロックの全8ビットを照合する
方式と、当該ブロックの前半4ビットを照合する方式と
の、いずれか一方により指定することを特徴とする。
The route search system according to the ninth aspect of the present invention
The designation bit information is used to designate a bit position in the block to be collated by the node readout unit when extracting the node entry, by collating all 8 bits of the block with the first four bits of the block. It is characterized in that it is designated by either one of the methods.

【0036】請求項10の本発明の経路検索システム
は、前記指定ビット情報は、前記ノード読み出し部が前
記ノードエントリの抽出時に照合する前記ブロック中の
ビット位置の指定を、当該ブロックの全8ビットを照合
する方式と、各ノード毎のそれぞれにおいて予め定めら
れた位置である当該ブロック内の4個所のビットを照合
する方式との、いずれか一方の方式により指定すること
を特徴とする。
In the route search system according to the present invention, preferably, the designated bit information includes a designation of a bit position in the block to be collated by the node reading unit at the time of extracting the node entry. And a method of collating four bits in the block, which is a predetermined position in each node, for each node.

【0037】請求項11の本発明の経路検索装置は、I
Pパケットの目的アドレスを基に転送先アドレスを決定
する経路検索装置において、前記目的アドレスによる木
構造の探索を行なうための、個々の目的アドレスのそれ
ぞれに対応する転送先アドレスを示す検索テーブルを備
え、前記検索テーブルの各ノードにおける下位のノード
エントリの探索を、各前記ノードのそれぞれの前記ノー
ドエントリの数に対応して指定された種類の多分木の探
索方法を用いて探索することを特徴とする。
The route search device of the present invention according to claim 11 is
In a path search device that determines a transfer destination address based on a target address of a P packet, a search table indicating a transfer destination address corresponding to each of the individual target addresses is provided for performing a tree structure search using the target address. Searching for a lower-level node entry in each node of the search table using a multitree search method of a specified type corresponding to the number of the node entries of each of the nodes. I do.

【0038】請求項19の本発明の交換機は、IPパケ
ットの目的アドレスを基に転送先アドレスを決定しIP
パケットを転送する交換機において、前記目的アドレス
による木構造の探索を行なうための、個々の目的アドレ
スのそれぞれに対応する転送先アドレスを示す検索テー
ブルを備え、前記検索テーブルの各ノードにおける下位
のノードエントリの探索を、各前記ノードのそれぞれの
前記ノードエントリの数に対応して指定された種類の多
分木の探索方法を用いて探索することを特徴とする。
According to a nineteenth aspect of the present invention, the exchange determines the transfer destination address based on the destination address of the IP packet, and
An exchange for transferring packets, comprising: a search table indicating a transfer destination address corresponding to each of the target addresses for performing a search of the tree structure by the target address; a lower node entry in each node of the search table; Is searched using a multitree search method of a type specified according to the number of the node entries of each of the nodes.

【0039】請求項24の本発明の経路検索方法は、I
Pパケットの目的アドレスを基に転送先アドレスを決定
する経路検索方法において、前記目的アドレスによる木
構造の探索を行なうための、個々の目的アドレスのそれ
ぞれに対応する転送先アドレスを示す検索テーブルを参
照するステップと、前記検索テーブルの各ノードにおけ
る下位のノードエントリの探索を、各前記ノードのそれ
ぞれの前記ノードエントリの数に対応して指定された種
類の多分木の探索方法を用いて探索するステップを備え
ることを特徴とする。
According to a twenty-fourth aspect of the present invention, the route search method
In a route search method for determining a transfer destination address based on a target address of a P packet, refer to a search table indicating a transfer destination address corresponding to each of the individual target addresses for searching a tree structure using the target address. Searching for a lower-level node entry in each node of the search table using a multitree search method of a type designated in correspondence with the number of the node entries of each of the nodes. It is characterized by having.

【0040】請求項25の本発明の経路検索方法は、前
記検索テーブルは、前記目的アドレスをその先頭から複
数個の等長のブロックに分割し、各前記ブロックを先頭
から順次、上位の階層から下位の階層に枝分かれさせて
結ぶ階層構造による木構造を有し、各ノードにおいて、
当該ノードからリンクする下位の各ノードエントリを示
すブロックのデータの記録と、前記下位の各ノードエン
トリの抽出時において照合する前記ブロック内のビット
位置の指定を示す指定ビット情報の記録を備えることを
特徴とする。
The route search method of the present invention according to claim 25, wherein the search table divides the destination address into a plurality of equal-length blocks from the top, and divides each of the blocks sequentially from the top, starting from a higher hierarchy. It has a tree structure with a hierarchical structure that branches and connects to lower layers.
It is provided with a record of data of a block indicating each lower node entry linked from the node, and a record of designated bit information indicating designation of a bit position in the block to be collated at the time of extracting each lower node entry. Features.

【0041】請求項26の本発明の経路検索方法は、各
ノードにおいて、前記検索対象の目的アドレスを分割し
た各ブロックと、当該ノードからリンクする下位の各ノ
ードエントリの前記ブロックとを、前記指定ビット情報
に示される位置の各ビットのデータを参照して照合し、
該当する前記ノードエントリを抽出するステップと、前
記指定ビット情報に指定されていない位置のビットのデ
ータの照合を行なうことにより、前記ノード読み出し部
により読み出された前記ノードエントリが、正しく前記
検索対象の目的アドレスを分割したブロックに該当する
か否かを判定するステップと、各ノードにおいて、前記
検索対象の目的アドレスを分割した各前記ブロックに該
当する前記ノードエントリを順次探索することにより、
前記検索テーブル内の当該検索対象の目的アドレスに該
当するエントリを検索するステップを備えることを特徴
とする。
According to a twenty-sixth aspect of the present invention, in each node, each of the blocks obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are specified. Check by referring to the data of each bit at the position indicated by the bit information,
The step of extracting the relevant node entry and the collation of the data of the bit at a position not specified in the specified bit information ensure that the node entry read by the node reading unit is correctly searched for by the search target. Determining whether the target address corresponds to the divided block, and in each node, by sequentially searching for the node entry corresponding to each of the blocks obtained by dividing the target address of the search target,
A step of searching for an entry in the search table corresponding to the target address of the search target.

【0042】請求項27の本発明の経路検索方法は、前
記検索テーブルの各前記ノードにおける前記指定ビット
情報を、当該指定ビット情報において指定されたビット
位置において示されるデータのみにより、各前記ノード
からリンクする下位のノードエントリが一意に識別され
るように予め設定するステップを備えることを特徴とす
る。
A route search method according to a twenty-seventh aspect of the present invention provides the route search method, wherein the designated bit information at each of the nodes in the search table is transmitted from each of the nodes only by data indicated at a bit position designated in the designated bit information. The method further comprises a step of presetting a lower node entry to be linked so as to be uniquely identified.

【0043】請求項28の本発明の経路検索方法は、検
索対象の前記ブロックに該当する前記ノードエントリ
を、定められた個数である複数個、まとめて一度に抽出
するステップと、前記抽出された各ノードエントリのそ
れぞれを、当該検索対象の前記ブロックに該当するか否
かを判定し、正しく該当する前記ノードエントリを検出
するステップを備えることを特徴とする。
A route search method according to a twenty-eighth aspect of the present invention is a step of extracting a plurality of node entries corresponding to the block to be searched, a predetermined number, all at once, and The method further comprises determining whether each of the node entries corresponds to the block to be searched, and detecting the node entry that is correctly matched.

【0044】請求項29の本発明の経路検索方法は、前
記検索テーブルの各前記ノードにおける前記指定ビット
情報を、当該指定ビット情報において指定されたビット
位置において示されるデータのみにより探索した場合に
おいて、各前記ノードからリンクする下位のノードエン
トリの当該探索時に重複して該当する個数を、高々、前
記ノード判定部が前記ノードエントリを一度にまとめて
取り出すことのできる前記定められた個数以下となるよ
うに予め設定するステップと、各前記ノードにおける前
記ノードエントリを、各前記指定ビット情報毎に、当該
指定ビット情報を用いた探索時に重複して該当する前記
ノードエントリをまとめて記録するステップを備えるこ
とを特徴とする。
A route search method according to a twenty-ninth aspect of the present invention provides the route search method according to the first aspect, wherein the specified bit information at each of the nodes in the search table is searched only by data indicated at a bit position specified in the specified bit information. The number of lower-level node entries linked from each of the nodes, which is duplicated during the search, is at most equal to or less than the predetermined number at which the node determination unit can collectively extract the node entries. And the step of recording the node entries in each of the nodes collectively for each of the designated bit information, which are duplicated during a search using the designated bit information. It is characterized by.

【0045】請求項30の本発明の経路検索方法は、I
Pv6のIPパケットの経路検索を行なうことを特徴と
する。
The route search method of the present invention according to claim 30 is characterized in that
It is characterized in that a route search for Pv6 IP packets is performed.

【0046】請求項31の本発明のコンピュータにより
読み取り可能な経路検索プログラムを記録した記録媒体
は、コンピュータを制御することにより、IPパケット
の目的アドレスを基に転送先アドレスを決定する経路検
索プログラムを記録した記録媒体において、前記目的ア
ドレスによる木構造の探索を行なうための、個々の目的
アドレスのそれぞれに対応する転送先アドレスを示す検
索テーブルを参照するステップと、前記検索テーブルの
各ノードにおける下位のノードエントリの探索を、各前
記ノードのそれぞれの前記ノードエントリの数に対応し
て指定された種類の多分木の探索方法を用いて探索する
ステップを備えることを特徴とする。
According to a thirty-first aspect of the present invention, there is provided a recording medium storing a computer-readable path search program according to the present invention, wherein the computer-controlled path search program determines a transfer destination address based on a destination address of an IP packet. Referencing a search table indicating a transfer destination address corresponding to each of the individual target addresses for performing a search of the tree structure by the target address in the recorded recording medium; The method further comprises a step of searching for a node entry by using a search method of a multi-tree of a type designated according to the number of the node entries of each of the nodes.

【0047】[0047]

【発明の実施の形態】以下、本発明の実施の形態につい
て図面を参照して詳細に説明する。
Embodiments of the present invention will be described below in detail with reference to the drawings.

【0048】本発明は、IPパケットの転送時におい
て、当該パケットの送信先のアドレスである目的アドレ
スを基に次の転送先のアドレスを検索するための、多分
木構造の効率的な経路検索を提供する。
According to the present invention, when an IP packet is transferred, an efficient path search of a multi-tree structure for searching for a next transfer destination address based on a destination address which is a destination address of the packet is performed. provide.

【0049】以下の実施の形態においては、特に、IP
v6(Internet Protocol Version6)における経路検索
を例に本発明の経路検索を説明する。ここでは、IPv
6における128ビットのアドレスを、先頭から8ビッ
ト毎に16個のブロックに分けて、順次この分割された
各ブロック毎に多分木の検索を行なう方式を例に説明す
る。
In the following embodiment, in particular,
The route search of the present invention will be described by taking a route search in v6 (Internet Protocol Version 6) as an example. Here, IPv4
An example will be described in which the 128-bit address in No. 6 is divided into 16 blocks for each 8 bits from the beginning, and a multi-tree search is sequentially performed for each of the divided blocks.

【0050】この木構造においては、各ブロックのノー
ドは下位のノードを、8ビットのデータにより示される
256種類を備えることができる。このため従来では、
図12に示されるように各ノードにおいて256分木の
検索を行なうのであったが、しかし、実際に各ノードか
らリンクする下位のノードの数は256よりもはるかに
少ない場合も多く、かつこれは256種類の分岐のため
の多くのメモリ空間を用意する必要がある。そこで本発
明では、このような場合のノードを、より少ない数の分
木により検索することにより必要とするメモリの削減を
実現する。
In this tree structure, the nodes of each block can have lower-order nodes and 256 types represented by 8-bit data. For this reason, conventionally,
Although a 256-tree search is performed at each node as shown in FIG. 12, the number of lower nodes actually linked from each node is often much smaller than 256, and It is necessary to prepare a lot of memory space for 256 kinds of branches. Therefore, in the present invention, the required memory can be reduced by searching for a node in such a case using a smaller number of branch trees.

【0051】更に、この方式においては、従来の256
分木の検索と同様に、目的アドレスを分割した16個の
ブロックによる各ノード毎に検索を行なうため、検索す
るノード数は256分木の方式と同じであり、256分
木の従来の方式と同様のメモリの少ないアクセス回数に
より検索できる。このようにして、効率の良い経路検索
を実現するのである。
Further, in this method, the conventional 256
As in the case of the branch tree search, since the search is performed for each node using the 16 blocks obtained by dividing the target address, the number of nodes to be searched is the same as the 256-tree method. A similar memory can be searched with a small number of accesses. In this way, an efficient route search is realized.

【0052】つまり、128ビットのIPv6アドレス
に対して、8ビット毎に区切る256分木を採用すると
16階層の木となる。一方で、4ビット毎に区切る16
分木を、従来の方法でそのまま採用したのであれば、倍
の32階層が必要となる。しかし、本発明では256分
木ノードと16分木ノードを併用するが、256分木に
おける分岐の少ないノードを16分木ノードとすること
により、階層を16階層のままに保つのである。
In other words, if a 256-ary tree that divides every 128 bits into a 128-bit IPv6 address is adopted, a 16-layer tree is obtained. On the other hand, 16
If the branch tree is used as it is in the conventional method, double 32 layers are required. However, in the present invention, the 256-tree node and the 16-tree node are used in combination. However, the hierarchy is maintained at 16 levels by using the node having less branches in the 256-tree as the 16-tree node.

【0053】本発明の第1の実施の形態の経路検索シス
テムでは、図3の例に示されるように256分木と16
分木の検索方法を併用する。つまり、256分木の各ノ
ードにおいて、分岐の数が(ここでは16個よりも)少
ないノードにおいては16分木の木構造を採用するので
ある。ここで、各ノードの検索方法が256分木である
のか16分木であるのかの判定は、検索時に参照する検
索テーブルの作成段階において、各ノードがリンクする
下位のノード数を基に決定し記録しておき、検索時にお
いては、その検索テーブルに指定された方法により検索
を実行する。
In the route search system according to the first embodiment of the present invention, as shown in the example of FIG.
Use the search method of the branch tree. In other words, at each node of the 256-ary tree, a node having a smaller number of branches (less than 16 in this case) adopts a 16-tree tree structure. Here, whether the search method of each node is a 256-ary tree or a 16-ary tree is determined based on the number of lower nodes linked by each node at the stage of creating a search table to be referred to at the time of search. The information is recorded, and at the time of the search, the search is executed by the method specified in the search table.

【0054】ここで、検索テーブルは、パケットの送信
先のアドレスである目的アドレスと、次の転送先のアド
レスを示す転送先アドレスとの対応を記録したテーブル
であり、これをシステム内の検索処理部(経路検索装
置)が参照することにより、転送先アドレスを検索す
る。
Here, the search table is a table in which the correspondence between the destination address which is the destination address of the packet and the transfer destination address indicating the next transfer destination address is recorded. The transfer destination address is searched for by referring to the transfer unit (route search device).

【0055】またこのようにして、本実施の形態の検索
テーブルは、従来の検索テーブルと異なり各ノードにお
いて検索方式の指定を備えるものの、これは各ノードの
リンクするノード数等を基に容易に決定することができ
るため、従来の単純な256分木の検索テーブルを元に
容易に生成することが可能である。また、この検索方式
の指定は、各ノードのエントリ数の増減に応じて適宜更
新し、256分木であるか16分木であるかを指定す
る。例えば、16分木ノードのエントリ数が増加して収
容しきれなくなった場合には、256分木ノードに置換
して検索テーブルの木の一部を再構築するのである。こ
のようにして、各ノードのエントリ数に応じて木構造を
構成し、効率的な検索を実現するのである。
As described above, the search table of the present embodiment differs from the conventional search table in that the search method is specified for each node, but this is easily performed based on the number of nodes linked to each node. Since it can be determined, it can be easily generated based on a conventional simple 256-tree search table. The search method is appropriately updated according to the increase or decrease in the number of entries of each node, and specifies whether it is a 256-ary tree or a 16-ary tree. For example, when the number of entries in the 16-tree node increases and cannot be accommodated, the tree is replaced with a 256-tree node and a part of the tree of the search table is reconstructed. In this way, a tree structure is formed according to the number of entries of each node, and an efficient search is realized.

【0056】図4は、本実施の形態の木構造を概念的に
示した図である。
FIG. 4 is a diagram conceptually showing the tree structure of the present embodiment.

【0057】木は、128ビットのアドレスを8ビット
毎のブロックに分割したことによる、“L0”から“L
15”までの16階層に分けられる。図4では、“L
3”までを記載しており、以下同様にして“L15”の
階層まで伸びている。
The tree is changed from “L0” to “L” by dividing a 128-bit address into blocks of 8 bits.
It is divided into 16 layers up to “15.” In FIG.
3 ", and similarly extends to the level of" L15 ".

【0058】木は、ノードと経路データから構成されて
いる。
The tree is composed of nodes and route data.

【0059】各ノードは、それぞれのノードを一意に識
別する識別子であるノードIDを備える。また各ノード
は、リンクする下位のノードを示す256個又は16個
のノードエントリを備える。
Each node has a node ID which is an identifier for uniquely identifying each node. Each node has 256 or 16 node entries indicating lower nodes to be linked.

【0060】ノードの種類には、根ノード、葉ノード、
分岐ノードがある。根ノードは、“L0”階層にある固
定ノードである。分岐ノードは、“L1”以下の階層に
位置し、そのノードエントリのいずれかに下位層のノー
ドへの分岐を有するノードである。葉ノードは、そのノ
ードエントリのいずれかに経路データ有するノードであ
る。また、分岐ノードが葉ノードであってもよい。実装
上においては、各ノード及び経路データはメモリ上の1
つの領域を占める。
The node types include a root node, a leaf node,
There is a branch node. The root node is a fixed node in the “L0” hierarchy. A branch node is a node that is located in the hierarchy below “L1” and has a branch to a lower layer node in any of its node entries. A leaf node is a node having route data in any of its node entries. Further, the branch node may be a leaf node. In implementation, each node and route data is
Occupy one area.

【0061】図5は、本実施の形態における、IPv6
アドレスを分割したブロックを256分木のノードとす
る場合の、ノード内のノードエントリの構成を説明する
ための図である。
FIG. 5 is a diagram showing an example of IPv6 in this embodiment.
FIG. 11 is a diagram for explaining a configuration of a node entry in a node when a block obtained by dividing an address is used as a node of a 256-tree.

【0062】ここでは、128ビットのIPv6アドレ
スを、8ビット毎のブロックに区切り、それぞれのブロ
ックを順次“B0”から“B15”と示す。この“B
0”から“B15”の各ブロックは、それぞれ“L0”
から“L15”までの各階層に対応する。
Here, the 128-bit IPv6 address is divided into 8-bit blocks, and the respective blocks are sequentially indicated as “B0” to “B15”. This "B
The blocks from “0” to “B15” are respectively “L0”
To “L15”.

【0063】例えば、図4におけるノードA(L1)と
ノードB(L2)との関係は、図5の例に示すように、
ノードAのノードIDに対して、ノードBの階層に相当
するブロックのビット列“B2”を付加し、必要に応じ
て数ビットの“0”を付加したものが、ノードBを構成
するノードエントリのアドレスになる。
For example, the relationship between node A (L1) and node B (L2) in FIG. 4 is as shown in the example of FIG.
The bit ID “B2” of the block corresponding to the hierarchy of the node B is added to the node ID of the node A, and “0” of several bits is added as necessary. Address.

【0064】図6は、本実施の形態における、IPv6
アドレスを分割したブロックを16分木のノードとする
場合の、ノード内のノードエントリの構成を説明するた
めの図であり、図5の場合と同様に、図4のノードA
(L1)とノードB(L2)との関係を示している。
FIG. 6 is a diagram showing IPv6 in the present embodiment.
FIG. 6 is a diagram for explaining a configuration of a node entry in a node in a case where a block into which an address is divided is used as a node of a 16-ary tree, as in the case of FIG.
(L1) and the relationship between node B (L2).

【0065】先の図5の256分木の場合と異なるの
は、“B2”の全8ビットを参照するのではなく、上位
4ビットのみを参照する点である。
The difference from the 256-ary tree in FIG. 5 is that only the upper 4 bits are referenced instead of referring to all 8 bits of “B2”.

【0066】先の256分木の場合のように全8ビット
を参照するならば、256エントリ分のメモリ空間を必
要とするが、そのノードのエントリ数が16個よりも少
ない場合において、図6のように4ビットのみに制限す
ることにより16エントリ分のメモリ空間で済み、必要
とするメモリが削減されるのである。
When referring to all 8 bits as in the case of the previous 256-ary tree, a memory space of 256 entries is required. In the case where the number of entries of the node is smaller than 16, FIG. By limiting to only 4 bits as in the above, the memory space for 16 entries is sufficient, and the required memory is reduced.

【0067】また、このように16分木の場合は、IP
v6アドレスを分割したブロックの、一部のビットのみ
を用いて当該エントリの抽出を行ない、その他のビット
は欠落することになる。ただし、本実施の形態では、エ
ントリ抽出後に、この抽出時に使用しなかった各ビット
を参照し、正しいアドレスのエントリであるかどうかを
確認する。
In the case of the 16-ary tree, the IP
The entry is extracted using only some of the bits of the block obtained by dividing the v6 address, and the other bits are lost. However, in the present embodiment, after the entry is extracted, it is checked whether or not the entry has a correct address by referring to each bit not used at the time of the extraction.

【0068】図7は、本実施の形態のノードエントリ及
び経路データエントリのデータ構成の一例を示す図であ
る。図7の例においては、ノードエントリのデータを3
2ビット、経路データのデータを128ビットとしてい
る。
FIG. 7 is a diagram showing an example of the data structure of the node entry and the route data entry according to the present embodiment. In the example of FIG. 7, the data of the node entry is 3
It is assumed that 2 bits and the path data are 128 bits.

【0069】図7の例においては、ノードエントリの情
報を示すために、“V”、“C”、“M”、“N”、
“H”、“ノードID”の各フラグを備えている。この
内の“V”、“C”、“M”、“N”の各フラグは、
“0”又は“1”を示すフラグであり、表2において
は、これらのフラグの“0”又“1”の各状態における
意味を示している。
In the example shown in FIG. 7, "V", "C", "M", "N",
"H" and "node ID" flags are provided. The “V”, “C”, “M”, and “N” flags are
This flag indicates "0" or "1". In Table 2, the meaning of these flags in each state of "0" or "1" is shown.

【0070】[0070]

【表2】 [Table 2]

【0071】“V”は、ノードエントリが有効であるか
無効であるかを示すフラグである。“V”が、“1”で
ある場合には有効、“0”である場合には無効とする。
ノードエントリが無効(V=0)の場合には、他のフィ
ールドの情報は意味を持たない。
"V" is a flag indicating whether the node entry is valid or invalid. If “V” is “1”, it is valid, and if “V”, it is invalid.
If the node entry is invalid (V = 0), the information in the other fields has no meaning.

【0072】“C”は、下位層のノードへのリンクを持
つか持たないかを示すフラグである。“C”が“1”の
場合には、そのノードエントリは下位層のノードへのリ
ンクを持ち、“0”の場合には持たない。
“C” is a flag indicating whether or not a link to a node in a lower layer is provided. When “C” is “1”, the node entry has a link to a node in a lower layer, and when “C” is “0”, the node entry does not.

【0073】“M”は、リンクする下位層のノードが、
256分木ノードであるか16分木ノードであるかを示
すフラグである。“M”が、“1”の場合には16分木
ノードとし、“0”の場合には256分木ノードとす
る。このため、この“M”のフラグは、そのノードエン
トリが下位層へのリンクを備える(C=1)場合にのみ
有効である。
“M” indicates that the lower layer node to be linked is
This is a flag indicating whether the node is a 256-tree node or a 16-tree node. If "M" is "1", it is a 16-tree node, and if "M" is "0", it is a 256-tree node. Therefore, the "M" flag is valid only when the node entry has a link to a lower layer (C = 1).

【0074】“N”は、そのノードエントリ自身が、2
56分木ノードであるか16分木ノードであるかを示す
フラグである。“N”が、“1”の場合には16分木ノ
ードとし、“0”の場合には256分木ノードとする。
"N" indicates that the node entry itself is 2
A flag indicating whether the node is a 56-tree node or a 16-tree node. If “N” is “1”, the node is a 16-tree node. If “N” is “0”, the node is a 256-tree node.

【0075】“H”は、IPv6アドレス中の当該ノー
ドにおいて処理中のブロックにおける、欠落したブロッ
クビットを示すフラグであり、つまりここでは当該ブロ
ックの下位4ビットの値を示す4ビット領域のフラグで
ある。例えば、現在処理中のブロック(そのノードエン
トリのブロック)が、“01001000”である場合
には、下位4ビットの“1000”をHフィールドに格
納する。
"H" is a flag indicating a missing block bit in the block being processed at the node in the IPv6 address, that is, a flag in a 4-bit area indicating the value of the lower 4 bits of the block. is there. For example, when the block currently being processed (the block of the node entry) is “01001000”, the lower four bits “1000” are stored in the H field.

【0076】このHフィールドは、次のように用いる。The H field is used as follows.

【0077】例えば、目的アドレスAと目的アドレスB
の2つの目的アドレスがあり、その上位2つのブロック
が同一であって、3番目のブロック(つまりB2)がそ
れぞれに“01001000”、“01001111”
であるとする。そして、検索対象のIPアドレスが、上
位2つのブロックが目的アドレスA及び目的アドレスB
と同一であり、ここで3番目のブロック(つまりB2)
“01001000”のエントリを登録する場合を考え
る。
For example, target address A and target address B
And the upper two blocks are the same, and the third block (that is, B2) has “01001000” and “01001111”, respectively.
And If the IP addresses to be searched are the upper two blocks, the target address A and the target address B
Where the third block (ie B2)
Consider a case where an entry of “01001000” is registered.

【0078】この場合、当該ブロックの上位4ビットの
“0100”を参照して、そのノードエントリを特定す
るため、目的アドレスAと目的アドレスBの双方がこの
検索対象のIPアドレスに対して指されることになる。
よって、ノードエントリの16分木検索時に参照されな
かったビットである“H”フィールドを参照することに
より、各ブロックの下位4ビットを比較して、正しく検
索を行なうのである。
In this case, both the target address A and the target address B are pointed to the search target IP address in order to specify the node entry by referring to “0100” of the upper 4 bits of the block. Will be.
Therefore, by referring to the "H" field, which is a bit that has not been referred to at the time of the 16-tree search of the node entry, the lower 4 bits of each block are compared and a correct search is performed.

【0079】この例では、目的アドレスBの3番目のブ
ロック“B2”の下位4ビットが、検索対象のIPアド
レスと異なるため、目的アドレスBとは一致しないと判
定される。
In this example, since the lower 4 bits of the third block “B2” of the target address B are different from the IP address to be searched, it is determined that they do not match the target address B.

【0080】“ノードID”のフィールドにおいては、
当該ノードエントリが示すリンク先である下位層のノー
ドの、ノードIDを示す。当該ノードが、下位層へのリ
ンクを備える場合に(“C”が“1”の場合に)有効で
ある。
In the “node ID” field,
Indicates the node ID of the lower layer node that is the link destination indicated by the node entry. This is effective when the node has a link to a lower layer (when “C” is “1”).

【0081】また、図7に示される“経路ID”のフィ
ールドは、経路データの識別子である。この“経路I
D”により、経路データが格納されているメモリアドレ
スを一意に特定する。また、経路データがない場合に
は、“経路ID”を“0”とすることにより経路データ
がない旨を示す。経路データには、128ビットの転送
先アドレス情報のみ含まれる。
The field of “route ID” shown in FIG. 7 is an identifier of route data. This "path I
The memory address at which the path data is stored is uniquely specified by “D.” If there is no path data, “path ID” is set to “0” to indicate that there is no path data. The data includes only 128-bit transfer destination address information.

【0082】図1は、本実施の形態の経路検索システム
における険路検索を実行する検索処理部100(経路検
索装置)の構成を示すブロック図であり、図2は、本実
施の形態の検索処理部100の処理を説明するためのフ
ローチャートである。
FIG. 1 is a block diagram showing a configuration of a search processing unit 100 (route search device) for executing a steep road search in the route search system according to the present embodiment, and FIG. 2 is a block diagram showing a search according to the present embodiment. 5 is a flowchart for explaining processing of a processing unit 100.

【0083】まず検索処理部100には最初、128ビ
ットの目的アドレスと、初期階層、根ノードIDが入力
される。初期階層の値は“0”(つまり“L0”)であ
り、根ノードIDは固定値である。
First, the search processing unit 100 receives a target address of 128 bits, an initial hierarchy, and a root node ID. The value of the initial layer is “0” (that is, “L0”), and the root node ID is a fixed value.

【0084】目的アドレス保持部10は、入力された目
的アドレスを記憶する。
The destination address holding unit 10 stores the input destination address.

【0085】アドレス生成部20は、検索時において現
在のターンにおける階層値、ノードID、そして下位層
のノードの分木の種類を示すM値を保持する。検索開始
時は、階層値=初期階層値、ノードID=根ノードI
D、M=“0”(下位層のノードは256分木)とす
る。
At the time of retrieval, the address generation unit 20 holds the hierarchical value, the node ID, and the M value indicating the type of the branch tree of the node of the lower layer at the current turn. At the start of search, hierarchy value = initial hierarchy value, node ID = root node I
It is assumed that D and M = "0" (the lower layer node is a 256-ary tree).

【0086】アドレス生成部20は、目的アドレス保持
部10から、現在の階層値に対応する8ビットのブロッ
クを読み出し、M=“0”の場合は8ビットのまま、M
=1の場合は上位4ビットを抽出し、アドレス生成に用
いる。
The address generation unit 20 reads an 8-bit block corresponding to the current hierarchical value from the destination address holding unit 10. If M = “0”, the address generation unit 20 keeps the 8-bit block.
If = 1, the upper 4 bits are extracted and used for address generation.

【0087】アドレス生成においては、アドレス生成部
20は、そのブロックのビット列と保持するノードID
とを用いて、M=“0”(下位層のノードが256分
木)の場合には図5で述べたアドレス生成を行ないノー
ド読み出し部30に出力し、下位層が16分木ノード
(M=“1”)の場合には図6で述べたアドレス生成を
行ない、同様にノード読み出し部30に出力する。
In the address generation, the address generator 20 stores the bit string of the block and the node ID to be held.
When M = “0” (the lower layer node is a 256-tree node), the address generation described in FIG. 5 is performed and the address is output to the node reading unit 30, and the lower layer is a 16-tree node (M = "1"), the address generation described with reference to FIG.

【0088】また、アドレス生成部20は、ノード判定
部50に対して、目的アドレス保持部10から読み出し
たブロックの全8ビットを、Mの値にかかわらずノード
判定部50に出力する。以降は、アドレス生成部20
は、子ノード判定部51からノードID及びM値の最新
の値の入力を受け付けて、また階層値はアドレス生成の
度にインクリメントし、同様にこれらの最新の値を用い
て上記の処理を実行する。
The address generator 20 outputs all eight bits of the block read from the destination address holder 10 to the node determiner 50 regardless of the value of M. Thereafter, the address generation unit 20
Receives the input of the latest values of the node ID and the M value from the child node determination unit 51, increments the hierarchical value each time an address is generated, and similarly executes the above processing using these latest values. I do.

【0089】また、アドレス生成部20は、制御部60
からリセット信号を受信した場合には、内部状態をリセ
ットして次の目的アドレスの入力を待機する。
The address generation unit 20 includes a control unit 60
, The internal state is reset and the system waits for the input of the next destination address.

【0090】ノード読み出し部30は、制御部60から
のノード読み出し要求を受けて、アドレス生成部20か
ら出力されたアドレスのノードエントリをメモリコント
ローラ40を介して外部メモリ41から読み出し、これ
をノード判定部50に出力する。
In response to the node read request from the control unit 60, the node read unit 30 reads the node entry of the address output from the address generation unit 20 from the external memory 41 via the memory controller 40, and determines this from the node memory. Output to the unit 50.

【0091】ノード判定部50では、ノード読み出し部
30から出力されたノードエントリ情報の“N”ビット
を検査して、そのノードエントリが256分木ノードで
あるのか16分木ノードであるのかを調べる。
The node determining section 50 checks the "N" bit of the node entry information output from the node reading section 30 to determine whether the node entry is a 256-tree node or a 16-tree node. .

【0092】もし、16分木ノードである場合(N=1
の場合)には、先のノード読み出し部30による抽出の
時点においてチェックされなかったビットがあるため、
これをチェックし正しいノードエントリが読み出された
のかどうかをチェックする。つまり、アドレス生成部2
0より出力されたブロックの内の、チェックされなかっ
たビットである下位4ビットと、Hフィールドの4ビッ
トとを比較するのである。
If the node is a 16-tree node (N = 1
), There are bits that were not checked at the time of extraction by the previous node readout unit 30,
Check this to see if the correct node entry was read. That is, the address generation unit 2
The lower 4 bits, which are unchecked bits in the block output from 0, are compared with the 4 bits of the H field.

【0093】比較の結果、同じであれば、正しいノード
エントリが読み出されたのであるから、これを子ノード
判定部51、有効判定処理部52、経路IDフィルタ部
53に出力して、制御部60に読み出しの成功を通知す
る(“1”を出力する)。比較結果が異なる場合は、制
御部60に読み出しの失敗を通知する(“0”を出力す
る)。
As a result of the comparison, if they are the same, then a correct node entry has been read out, and this is output to the child node determination section 51, the validity determination processing section 52, and the path ID filter section 53, and is output to the control section. 60 is notified of the success of reading ("1" is output). If the comparison results are different, the control unit 60 is notified of read failure (outputs "0").

【0094】もし、256分木ノードである場合(N=
0の場合)には、先のノード読み出し部30による抽出
の時点において既にブロックの全8ビットがチェックさ
れているため、正しいノードエントリが読み出されてい
るのであり、そのノードエントリをそのまま子ノード判
定部51、有効判定処理部52、経路IDフィルタ部5
3に出力して、制御部60に読み出しの成功を通知する
(“1”を出力する)。
If the node is a 256-tree node (N =
In the case of "0"), since all 8 bits of the block have already been checked at the time of extraction by the previous node reading unit 30, the correct node entry has been read, and the node entry is directly Determination unit 51, validity determination processing unit 52, route ID filter unit 5
3 to notify the control unit 60 of the success of reading (output "1").

【0095】子ノード判定処理部51は、ノードエント
リの“C”ビットを検査して子ノードの有無を判定し、
もし下位層のノードへのリンクを持つ場合(C=1の場
合)には、そのノードエントリにおけるM値及びノード
IDのフィールドの値をアドレス生成部20に出力す
る。アドレス生成部20では、このM値とノードID値
を用いて、次のアドレス生成を行なう。またこの場合、
子ノード判定処理部51は、同時に“C”ビットの値を
制御部60に出力する。
The child node determination processing unit 51 checks the “C” bit of the node entry to determine whether there is a child node.
If there is a link to a node in a lower layer (C = 1), the M value and the value of the node ID field in the node entry are output to the address generator 20. The address generation unit 20 generates the next address using the M value and the node ID value. Also in this case,
The child node determination processing unit 51 outputs the value of the “C” bit to the control unit 60 at the same time.

【0096】有効判定処理部52は、ノードエントリの
“V”ビットを抽出して制御部60に出力する。
The validity determination processing section 52 extracts the “V” bit of the node entry and outputs it to the control section 60.

【0097】経路IDフィルタ部53は、ノードエント
リから経路IDフィールドの値を抽出して制御部60と
結果出力部70に出力する。
The route ID filter unit 53 extracts the value of the route ID field from the node entry and outputs it to the control unit 60 and the result output unit 70.

【0098】制御部60の処理を表3に示す。Table 3 shows the processing of the control unit 60.

【0099】[0099]

【表3】 [Table 3]

【0100】表3においては、最初の4列はそれぞれノ
ード判定部50、子ノード判定部51、有効判定処理部
52、経路IDフィルタ部53から制御部60に出力さ
れる値を示し、“*”はどのような値でもよいことを示
す。
In Table 3, the first four columns indicate values output from the node determination unit 50, the child node determination unit 51, the validity determination processing unit 52, and the route ID filter unit 53 to the control unit 60, respectively. "Indicates that any value may be used.

【0101】制御部60は、これらの入力値の値に基づ
いて、ノード読み出し部30に対しノード読み出し要求
信号、結果出力部70に対し結果出力要求信号又は経路
ID更新要求信号、アドレス生成部20に対しへリセッ
ト信号を出力する。
Based on these input values, the control unit 60 sends a node read request signal to the node read unit 30, a result output request signal or a route ID update request signal to the result output unit 70, and an address generation unit 20. Outputs a reset signal to

【0102】つまり、制御部60は、当該ノードエント
リが無効(V=0)又は検索に該当するノードエントリ
を備えない場合(ノード判定部が判定)、又は子ノード
を備えない場合(C=0)には、結果出力要求及びリセ
ットを行なう。また、これらの条件に全て該当しない場
合にはノード読み出し要求を行なう。
That is, the control unit 60 determines whether the node entry is invalid (V = 0) or does not have a node entry corresponding to the search (determined by the node determination unit), or has no child node (C = 0). In (), a result output request and reset are performed. If all of these conditions are not met, a node read request is made.

【0103】また、制御部60は、経路IDフィールド
に経路データの識別子が記録されている場合(経路ID
が“0”でない場合)には、経路ID更新要求を行な
う。
Further, when the identifier of the route data is recorded in the route ID field (the route ID
Is not "0"), a route ID update request is made.

【0104】結果出力部70は、制御部60から経路I
D更新要求を受け付けた場合のみ、経路IDフィルタ部
53から出力された経路IDを保持する。既に保持して
いる経路IDがある場合は、それを更新する。
The result output unit 70 sends the route I
Only when a D update request is received, the route ID output from the route ID filter unit 53 is held. If there is a route ID already held, it is updated.

【0105】また、結果出力部70は、制御部60から
結果出力要求を受けた場合、メモリコントローラ40を
介して外部メモリ41から経路IDが指す経路データを
読み出して、その転送先アドレス値を出力する。保持す
る経路IDがない場合には、検索失敗を示す信号を出力
する。
When receiving a result output request from the control unit 60, the result output unit 70 reads the path data indicated by the path ID from the external memory 41 via the memory controller 40, and outputs the transfer destination address value. I do. If there is no path ID to hold, a signal indicating search failure is output.

【0106】以上の処理を、目的アドレスを分割した各
ブロックに対して順次実行することにより、メモリ領域
として実装されている木のノードを順次辿っていき、求
める経路情報を見つけることができる。
By sequentially performing the above processing on each block obtained by dividing the target address, it is possible to sequentially follow nodes of a tree implemented as a memory area and find path information to be obtained.

【0107】以上説明したように、本実施の形態の経路
検索システムによれば、256分木と16分木との検索
方法を適切に組み合わせて、メモリへのアクセス回数と
必要とするメモリ容量との双方を同時に少なく抑えるこ
とができる。
As described above, according to the route search system of the present embodiment, the search method for the 256-ary tree and the 16-ary tree is appropriately combined to obtain the number of accesses to the memory and the required memory capacity. Can be simultaneously reduced.

【0108】次に、本発明の第2の実施の形態を説明す
る。
Next, a second embodiment of the present invention will be described.

【0109】先の第1の実施の形態では、検索テーブル
の作成において、上位4ビットによる検索において1つ
でも衝突が発生するノードは、必ず256分木ノードと
する必要があった。
In the first embodiment, when a search table is created, a node in which even one collision occurs in a search using the upper 4 bits must be a 256-tree node.

【0110】例えば、図6において、2つの経路エント
リ“R1”、“R2”を、上位16ビット(上位2ブロ
ック)が等しく、3番目のブロックである“B2”がそ
れぞれ“01001000”と“01001111”で
あるものとする。ここで、“R1”が既に検索テーブル
の中に登録済みの場合に、新たに“R2”を登録しよう
とすると、“R1”と“R2”は3番目のブロックであ
る“B2”のノードにおいて衝突することになる。
For example, in FIG. 6, the two route entries “R1” and “R2” have the same upper 16 bits (upper 2 blocks), and the third block “B2” has “01001000” and “01001111”, respectively. ". Here, if “R1” has already been registered in the search table, and “R2” is to be newly registered, “R1” and “R2” are stored in the node of “B2” which is the third block. You will collide.

【0111】先の第1の実施の形態では、このような場
合には、衝突の発生するエントリを新規に登録する時点
で、そのノードを直ちに256分木ノード(図5)に置
換して更新する必要がある。最悪の場合には、2番目の
エントリを登録した時点で256分木への置換が必要と
なる場合もあり非効率である。
In the first embodiment, in such a case, when a new entry in which a collision occurs is registered, the node is immediately replaced with a 256-tree node (FIG. 5) and updated. There is a need to. In the worst case, when a second entry is registered, replacement with a 256-tree may be required, which is inefficient.

【0112】そこで、本実施の形態では図8に示すよう
に、16分木ノードが保有するノードエントリを“1
6”から“64”に拡張し、“B2”等の各ブロックに
よって参照するノードエントリを4つとする。上記の例
の場合では、“R1”と“R2”は同じ上位4ビット
“0100”に該当するノードエントリであり、それぞ
れノードエントリA、ノードエントリBに格納される。
Therefore, in the present embodiment, as shown in FIG. 8, the node entry held by the 16-tree node is "1".
From "6" to "64", the number of node entries referred to by each block such as "B2" is 4. In the above example, "R1" and "R2" are set to the same upper 4 bits "0100". The corresponding node entry is stored in node entry A and node entry B, respectively.

【0113】次に、本実施の形態の動作を説明する。Next, the operation of this embodiment will be described.

【0114】ノード読み出し部30は、ノードを読み出
す際にはバースト読み出しを行ない、一度に4エントリ
まで同時に読み出す。メモリアクセス回数の増加がある
ものの、連続したメモリ領域を読み出すため大きな遅延
にはならない。また、ノード読み出し部30は、読み出
した各エントリを順次ノード判定部50に出力する。
The node readout unit 30 performs burst readout when reading out a node, and simultaneously reads up to four entries at a time. Although there is an increase in the number of memory accesses, there is no significant delay because continuous memory areas are read. The node reading unit 30 sequentially outputs the read entries to the node determination unit 50.

【0115】ノード判定部50は、一度に最大4エント
リのノードエントリの入力を順次受け付け、先の第1の
実施の形態と同様の方法により、ノード判定処理をこの
4エントリのそれぞれに行なう。もし、一致するエント
リがある場合には、そのエントリを子ノード判定部5
1、有効判定処理部52、経路IDフィルタ部53に出
力し、制御部60には一致するエントリが検索された旨
を通知する(“1”を出力する)。
The node determination unit 50 sequentially receives input of up to four node entries at a time, and performs a node determination process on each of the four entries in the same manner as in the first embodiment. If there is a matching entry, the entry is determined by the child node determination unit 5
1. Output to the validity determination processing unit 52 and the route ID filter unit 53, and notify the control unit 60 that a matching entry has been searched (output "1").

【0116】ここでもし、一致するエントリがない場合
は、制御部60には一致するエントリが検索されなかっ
た旨を通知する(“0”を出力する)。
If there is no matching entry, control unit 60 is notified that a matching entry was not found (outputs "0").

【0117】なお、256分木ノードである場合(N=
0の場合)には、ノード読み出し部30においてブロッ
クの全8ビットがチェックされて抽出されるため、抽出
されるノードは1つのみであり、この入力されたエント
リをそのまま子ノード判定部51、有効判定処理部5
2、経路IDフィルタ部53に出力して、制御部60に
一致するエントリが検索された旨を通知する(“1”を
出力する)。
If the node is a 256-tree node (N =
In the case of 0), all eight bits of the block are checked and extracted in the node readout unit 30, so that only one node is extracted, and this input entry is directly used as the child node determination unit 51, Validity judgment processing unit 5
2. Output to the path ID filter unit 53 to notify the control unit 60 that a matching entry has been searched (output "1").

【0118】この他の動作は、第1の実施の形態の動作
と同様である。
The other operations are the same as those of the first embodiment.

【0119】以上説明したように本実施の形態では、第
1の実施の形態の効果に加えて、更に衝突を緩和するこ
とができる。
As described above, in this embodiment, in addition to the effects of the first embodiment, the collision can be further reduced.

【0120】次に、本実施の形態の第3の実施の形態を
説明する。
Next, a third embodiment of the present embodiment will be described.

【0121】本実施の形態においては、先の第2の実施
の形態の構成において、更にノードエントリのデータ構
成を図9のように修正する。第1、第2の実施の形態の
異なるのはHフィールドを8ビットに拡張して、マスク
フィールド8ビットを追加したことである。
In the present embodiment, the data configuration of the node entry is further modified as shown in FIG. 9 in the configuration of the second embodiment. The difference between the first and second embodiments is that the H field is extended to 8 bits and a mask field of 8 bits is added.

【0122】本実施の形態のHフィールドは、各ブロッ
クの全8ビットをそのまま登録する。つまり、第1、第
2の実施の形態では、下位4ビットのみであったが、こ
こでは全ビット格納するのである。
In the H field of this embodiment, all 8 bits of each block are registered as they are. That is, in the first and second embodiments, only the lower 4 bits are used, but all bits are stored here.

【0123】マスクフィールドは、次のノードを検索す
る際に用いるマスクビットである。これは、図10に示
すように、各ブロックのマスクビットに指定される位置
の4ビットを抽出してアドレス生成を行なうのである。
The mask field is a mask bit used when searching for the next node. In this case, as shown in FIG. 10, address generation is performed by extracting 4 bits at the position designated by the mask bit of each block.

【0124】例えば、マスク値が“00001111”
であれば、図8で上位4ビットとしていた部分が、下位
4ビットになる。またマスク値が“01010101”
であれば、そのブロックの上位2、4、6、8ビットを
抽出して4ビットを構成する。なおマスクフィールド
は、リンク先が16分木ノード(M=1)の時のみ意味
を持つ。
For example, if the mask value is “000011111”
In this case, the upper 4 bits in FIG. 8 become the lower 4 bits. Also, the mask value is “01010101”
If so, the upper 2, 4, 6, and 8 bits of the block are extracted to form 4 bits. Note that the mask field is meaningful only when the link destination is a 16-tree node (M = 1).

【0125】次に、本実施の形態の動作を説明する。Next, the operation of this embodiment will be described.

【0126】本実施の形態においては、子ノード判定処
理部51は、アドレス生成部20に対しマスク値も出力
するようにする。アドレス生成部20は、リンク先が1
6分木ノード(M=1)の場合、マスク値を用いてIP
アドレスのブロックを縮退して、アドレスを生成する。
この他の処理は既述した通りである。
In the present embodiment, the child node determination processing section 51 outputs a mask value to the address generation section 20. The address generation unit 20 determines that the link destination is 1
In the case of a hexadecimal tree node (M = 1), IP
An address is generated by degenerating a block of addresses.
Other processes are as described above.

【0127】なお、マスクの決定方法であるが、検索テ
ーブルの作成時において、単純に全てのビットパターン
について検証して、最もエントリが散布するマスクを選
択する等の方法が可能である。
As a method of determining a mask, it is possible to simply verify all bit patterns and select a mask to which entries are most scattered when creating a search table.

【0128】8ビット中から4ビットを選択するパター
ンは、70通りある。それらについて、各エントリ間に
おいて衝突が発生しないマスクを探索し選択するのであ
る。この最適のマスクの選択処理は、容易にコンピュー
タプログラムのソフトウェアで実施することができ、こ
のソフトウェアから図1の装置に対して設定することが
できる。この探索は、1ノードにつき高々70パターン
の探索であり、また、経路エントリを新規に登録する際
に(検索テーブルの編集時に)発生するものなので、大
きな遅延にはならない。
There are 70 patterns for selecting 4 bits from 8 bits. For them, a mask that does not cause a collision between entries is searched for and selected. The process of selecting the optimum mask can be easily performed by software of a computer program, and can be set for the apparatus of FIG. 1 from the software. This search is a search of at most 70 patterns per node, and occurs at the time of newly registering a route entry (at the time of editing the search table), so that there is no large delay.

【0129】以上説明したように、本実施の形態では、
第2の実施の形態の効果に加えて、より効率的な木の構
築が可能となり、効率的な経路検索を実現する。
As described above, in the present embodiment,
In addition to the effects of the second embodiment, a more efficient tree can be constructed, and an efficient route search is realized.

【0130】なお、上記各実施の形態の検索処理部10
0は、目的アドレス保持部10、アドレス生成部20、
ノード読み出し部30、メモリコントローラ40、ノー
ド判定部50、子ノード判定部51、有効判定処理部5
2、経路IDフィルタ部53、制御部60、結果出力部
70等の機能や、その他の機能をハードウェア的に実現
することは勿論として、各機能を備えるコンピュータプ
ログラムを、コンピュータ処理装置のメモリにロードさ
れることで実現することができる。このコンピュータプ
ログラムは、磁気ディスク、半導体メモリその他の記録
媒体90に格納される。そして、その記録媒体からコン
ピュータ処理装置にロードされ、コンピュータ処理装置
の動作を制御することにより、上述した各機能を実現す
る。
The search processing unit 10 of each of the above embodiments
0 is the destination address holding unit 10, the address generation unit 20,
Node readout unit 30, memory controller 40, node determination unit 50, child node determination unit 51, validity determination processing unit 5
2. In addition to realizing the functions of the path ID filter unit 53, the control unit 60, the result output unit 70 and the like, and other functions in hardware, a computer program having each function is stored in the memory of the computer processing device. It can be realized by being loaded. This computer program is stored on a magnetic disk, semiconductor memory, or other recording medium 90. Then, the functions described above are realized by being loaded from the recording medium into the computer processing device and controlling the operation of the computer processing device.

【0131】以上好ましい実施の形態及び実施例をあげ
て本発明を説明したが、本発明は必ずしも上記実施の形
態及び実施例に限定されるものではなく、その技術的思
想の範囲内において様々に変形して実施することができ
る。
Although the present invention has been described with reference to the preferred embodiments and examples, the present invention is not necessarily limited to the above-described embodiments and examples, and various modifications may be made within the scope of the technical idea. Modifications can be made.

【0132】[0132]

【発明の効果】以上説明したように本発明のIPパケッ
トの経路検索システムによれば、複数の検索方法を併用
して適切な検索方法を自動選択して検索することができ
るため、メモリのアクセス回数とメモリ容量との双方を
抑える効率的な検索を実現することができる。
As described above, according to the IP packet route search system of the present invention, an appropriate search method can be automatically selected and searched by using a plurality of search methods in combination. An efficient search that suppresses both the number of times and the memory capacity can be realized.

【0133】また、本発明では、128ビットのIPv
6アドレスを、16ブロックに分割して8ビット毎にま
とめて検索を行なう場合に、256分木と16分木との
検索方法のそれぞれを適切に選択して検索することがで
きる。これにより、検索テーブルへのアクセス回数を2
分木検索や16分木検索よりも低減でき、かつ同時に2
56分木検索における多量のメモリ浪費を抑えることが
でき、効率的な検索を実現する。
In the present invention, a 128-bit IPv4
When six addresses are divided into 16 blocks and a search is performed collectively for each 8 bits, the search method can be appropriately selected for each of the 256-tree and 16-tree search methods. As a result, the number of accesses to the search table is reduced to 2
It can be reduced compared to the binary tree search and the 16-tree tree search, and at the same time, 2
A large amount of memory waste in a 56-tree search can be suppressed, and efficient search can be realized.

【図面の簡単な説明】[Brief description of the drawings]

【図1】 本発明の第1の実施の形態による経路検索部
の構成を示すブロック図である。
FIG. 1 is a block diagram illustrating a configuration of a route search unit according to a first embodiment of the present invention.

【図2】 本発明の第1の実施の形態による経路検索部
の処理を説明するためのフローチャートである。
FIG. 2 is a flowchart illustrating a process of a route search unit according to the first embodiment of the present invention.

【図3】 本発明の第1の実施の形態の256分木/1
6分木ノード併用の構成を示す図である。
FIG. 3 shows a 256-ary tree / 1 according to the first embodiment of the present invention.
FIG. 9 is a diagram illustrating a configuration in which a 6-ary tree node is used together.

【図4】 本発明の第1の実施の形態の経路テーブルの
木構造を説明するための図である。
FIG. 4 is a diagram illustrating a tree structure of a route table according to the first embodiment of this invention.

【図5】 IPアドレスと256分木ノードのノードエ
ントリとの関係を説明するための図である。
FIG. 5 is a diagram for explaining a relationship between an IP address and a node entry of a 256-tree node.

【図6】 本発明の第1の実施の形態の256分木/1
6分木ノード併用の場合のノードエントリとIPアドレ
スとの関係を説明するための図である。
FIG. 6 shows a 256-ary tree / 1 according to the first embodiment of the present invention.
It is a figure for explaining the relation between a node entry and an IP address in the case of using a 6-tree tree node together.

【図7】 本発明の第1の実施の形態のノードエントリ
及び経路データエントリの構成の一例を示す図である。
FIG. 7 is a diagram illustrating an example of a configuration of a node entry and a route data entry according to the first embodiment of this invention.

【図8】 本発明の第2の実施の形態のIPアドレスと
ノードエントリとのノードエントリの構成を示す図であ
る。
FIG. 8 is a diagram illustrating a configuration of a node entry between an IP address and a node entry according to the second embodiment of this invention.

【図9】 本発明の第3の実施の形態のノードエントリ
の構成を示す図である。
FIG. 9 is a diagram illustrating a configuration of a node entry according to the third embodiment of this invention.

【図10】 本発明の第3の実施の形態のIPアドレス
とノードエントリとのノードエントリの構成を示す図で
ある。
FIG. 10 is a diagram illustrating a configuration of a node entry of an IP address and a node entry according to the third embodiment of this invention.

【図11】 2分木ノードの構成を示す図である。FIG. 11 is a diagram illustrating a configuration of a binary tree node.

【図12】 256分木ノードの構成を示す図である。FIG. 12 is a diagram illustrating a configuration of a 256-tree node.

【図13】 従来の経路検索の処理を説明するためのフ
ローチャートである。
FIG. 13 is a flowchart illustrating a conventional route search process.

【符号の説明】[Explanation of symbols]

100 検索処理部 10 目的アドレス保持部 20 アドレス生成部 30 ノード読み出し部 40 メモリコントローラ 41 外部メモリ 50 ノード判定部 51 子ノード判定部 52 有効判定処理部 53 経路IDフィルタ部 60 制御部 70 結果出力部 90 記録媒体 REFERENCE SIGNS LIST 100 search processing unit 10 destination address holding unit 20 address generation unit 30 node reading unit 40 memory controller 41 external memory 50 node determination unit 51 child node determination unit 52 validity determination processing unit 53 route ID filter unit 60 control unit 70 result output unit 90 recoding media

Claims (37)

【特許請求の範囲】[Claims] 【請求項1】 IPパケットの目的アドレスを基に転送
先アドレスを決定する経路検索システムにおいて、 前記目的アドレスによる木構造の探索を行なうための、
個々の目的アドレスのそれぞれに対応する転送先アドレ
スを示す検索テーブルを備え、 前記検索テーブルの各ノードにおける下位のノードエン
トリの探索を、各前記ノードのそれぞれの前記ノードエ
ントリの数に対応して指定された種類の多分木の探索方
法を用いて探索することを特徴とする経路検索システ
ム。
1. A route search system for determining a transfer destination address based on a destination address of an IP packet, comprising:
A search table indicating a transfer destination address corresponding to each of the target addresses; and specifying a search for a lower node entry in each node of the search table in accordance with the number of the node entries of each of the nodes. A route search system characterized in that a search is performed using a search method of a given type of multitree.
【請求項2】 前記検索テーブルは、 前記目的アドレスをその先頭から複数個の等長のブロッ
クに分割し、各前記ブロックを先頭から順次、上位の階
層から下位の階層に枝分かれさせて結ぶ階層構造による
木構造を有し、 各ノードにおいて、当該ノードからリンクする下位の各
ノードエントリを示すブロックのデータの記録と、前記
下位の各ノードエントリの抽出時において照合する前記
ブロック内のビット位置の指定を示す指定ビット情報の
記録を備えることを特徴とする請求項1に記載の経路検
索システム。
2. The search table has a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and the blocks are sequentially connected from the beginning by branching from an upper hierarchy to a lower hierarchy. In each node, at each node, record data of a block indicating each lower node entry linked from the node, and designate a bit position in the block to be collated when extracting each lower node entry The route search system according to claim 1, further comprising recording of designated bit information indicating the following.
【請求項3】 各ノードにおいて、前記検索対象の目的
アドレスを分割した各ブロックと、当該ノードからリン
クする下位の各ノードエントリの前記ブロックとを、前
記指定ビット情報に示される位置の各ビットのデータを
参照して照合し、該当する前記ノードエントリを抽出す
るノード読み出し部と、 前記指定ビット情報に指定されていない位置のビットの
データの照合を行なうことにより、前記ノード読み出し
部により読み出された前記ノードエントリが、正しく前
記検索対象の目的アドレスを分割したブロックに該当す
るか否かを判定するノード判定部を備え、 各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索すること
を特徴とする請求項2に記載の経路検索システム。
3. In each node, each block obtained by dividing the target address to be searched and the block of each lower-level node entry linked from the node are assigned to each bit at the position indicated by the designated bit information. A node reading unit that performs collation by referring to data and extracts a corresponding node entry, and performs collation of data of a bit at a position not designated in the designated bit information, thereby reading the node entry. A node determining unit that determines whether the node entry correctly corresponds to a block obtained by dividing the target address of the search target, wherein each node corresponds to each of the blocks obtained by dividing the target address of the search target. By sequentially searching for the node entry to be searched, Route search system according to claim 2, characterized in that searches for an entry corresponding to the specific address.
【請求項4】 前記検索テーブルの各前記ノードにおけ
る前記指定ビット情報を、当該指定ビット情報において
指定されたビット位置において示されるデータのみによ
り、各前記ノードからリンクする下位のノードエントリ
が一意に識別されるように予め設定し備えることを特徴
とする請求項3に記載の経路検索システム。
4. A lower-level node entry linked from each of the specified bit information in each of the nodes of the search table is uniquely identified only by data indicated at a bit position specified in the specified bit information. 4. The route search system according to claim 3, wherein the route search system is set in advance so as to be executed.
【請求項5】 前記ノード判定部は、 検索対象の前記ブロックに該当する前記ノードエントリ
を、定められた個数である複数個、まとめて一度に抽出
する手段を備え、 前記ノード判定部は、 前記抽出された各ノードエントリのそれぞれを、当該検
索対象の前記ブロックに該当するか否かを判定し、正し
く該当する前記ノードエントリを検出することを特徴と
する請求項3に記載の経路検索システム。
5. The node determination unit further comprises: a unit that extracts a predetermined number of the node entries corresponding to the block to be searched in a batch at a time, wherein the node determination unit includes: 4. The route search system according to claim 3, wherein it is determined whether each of the extracted node entries corresponds to the block to be searched, and the corresponding node entry is detected correctly. 5.
【請求項6】 前記検索テーブルの各前記ノードにおけ
る前記指定ビット情報を、当該指定ビット情報において
指定されたビット位置において示されるデータのみによ
り探索した場合において、各前記ノードからリンクする
下位のノードエントリの当該探索時に重複して該当する
個数を、高々、前記ノード判定部が前記ノードエントリ
を一度にまとめて取り出すことのできる前記定められた
個数以下になるように予め設定し備え、 前記検索テーブルは、 各前記ノードにおける前記ノードエントリを、各前記指
定ビット情報毎に、当該指定ビット情報を用いた探索時
に重複して該当する前記ノードエントリをまとめて記録
し備えることを特徴とする請求項5に記載の経路検索シ
ステム。
6. A lower node entry linked from each of said nodes when said designated bit information at each of said nodes in said search table is searched for only by data indicated at a bit position designated in said designated bit information. Is set in advance so as to be at most equal to or less than the predetermined number at which the node determination unit can collectively extract the node entries at a time. 6. The method according to claim 5, wherein the node entries in each of the nodes are collectively recorded for each of the designated bit information, and the corresponding node entries are collectively recorded at the time of searching using the designated bit information. Route search system described.
【請求項7】 IPv6のIPパケットの経路検索を行
なうことを特徴とする請求項3から請求項6のいずれか
一つに記載の経路検索システム。
7. The route search system according to claim 3, wherein a route search for an IPv6 IP packet is performed.
【請求項8】 前記目的アドレスのサイズを128ビッ
トとし、 前記ブロックのサイズを8ビットとし、 前記検索テーブルは、各前記目的アドレスを16個の前
記ブロックに分割することによる16階層の木構造とす
る、ことを特徴とする請求項7に記載の経路検索システ
ム。
8. The target address has a size of 128 bits, the block has a size of 8 bits, and the search table has a tree structure of 16 layers by dividing each of the target addresses into 16 blocks. The route search system according to claim 7, wherein:
【請求項9】 前記指定ビット情報は、 前記ノード読み出し部が前記ノードエントリの抽出時に
照合する前記ブロック中のビット位置の指定を、当該ブ
ロックの全8ビットを照合する方式と、当該ブロックの
前半4ビットを照合する方式との、いずれか一方により
指定することを特徴とする請求項8に記載の経路検索シ
ステム。
9. The method according to claim 9, wherein the designation bit information includes a method of collating all eight bits of the block by specifying a bit position in the block to be collated by the node readout unit when extracting the node entry; 9. The route search system according to claim 8, wherein the designation is performed by using one of a method of collating four bits.
【請求項10】 前記指定ビット情報は、 前記ノード読み出し部が前記ノードエントリの抽出時に
照合する前記ブロック中のビット位置の指定を、当該ブ
ロックの全8ビットを照合する方式と、各ノード毎のそ
れぞれにおいて予め定められた位置である当該ブロック
内の4個所のビットを照合する方式との、いずれか一方
の方式により指定することを特徴とする請求項8に記載
の経路検索システム。
10. The method according to claim 10, wherein the designation bit information includes: a designation of a bit position in the block to be collated by the node readout unit when extracting the node entry; a method of collating all 8 bits of the block; 9. The route search system according to claim 8, wherein the designation is made by using one of a method of collating four bits in the block, which are predetermined positions in each case.
【請求項11】 IPパケットの目的アドレスを基に転
送先アドレスを決定する経路検索装置において、 前記目的アドレスによる木構造の探索を行なうための、
個々の目的アドレスのそれぞれに対応する転送先アドレ
スを示す検索テーブルを備え、 前記検索テーブルの各ノードにおける下位のノードエン
トリの探索を、各前記ノードのそれぞれの前記ノードエ
ントリの数に対応して指定された種類の多分木の探索方
法を用いて探索することを特徴とする経路検索装置。
11. A route search device that determines a transfer destination address based on a destination address of an IP packet, wherein the route search device searches for a tree structure using the destination address.
A search table indicating a transfer destination address corresponding to each of the target addresses; and specifying a search for a lower node entry in each node of the search table in accordance with the number of the node entries of each of the nodes. A path search device characterized in that a search is performed using a search method of a given type of multitree.
【請求項12】 前記検索テーブルは、 前記目的アドレスをその先頭から複数個の等長のブロッ
クに分割し、各前記ブロックを先頭から順次、上位の階
層から下位の階層に枝分かれさせて結ぶ階層構造による
木構造を有し、 各ノードにおいて、当該ノードからリンクする下位の各
ノードエントリを示すブロックのデータの記録と、前記
下位の各ノードエントリの抽出時において照合する前記
ブロック内のビット位置の指定を示す指定ビット情報の
記録を備えることを特徴とする請求項11に記載の経路
検索装置。
12. The search table has a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and the blocks are sequentially linked from the beginning to the lower hierarchy from the upper hierarchy. In each node, at each node, record data of a block indicating each lower node entry linked from the node, and designate a bit position in the block to be collated when extracting each lower node entry 12. The route search device according to claim 11, further comprising recording of designated bit information indicating the following.
【請求項13】 各ノードにおいて、前記検索対象の目
的アドレスを分割した各ブロックと、当該ノードからリ
ンクする下位の各ノードエントリの前記ブロックとを、
前記指定ビット情報に示される位置の各ビットのデータ
を参照して照合し、該当する前記ノードエントリを抽出
するノード読み出し部と、 前記指定ビット情報に指定されていない位置のビットの
データの照合を行なうことにより、前記ノード読み出し
部により読み出された前記ノードエントリが、正しく前
記検索対象の目的アドレスを分割したブロックに該当す
るか否かを判定するノード判定部を備え、 各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索すること
を特徴とする請求項12に記載の経路検索装置。
13. In each node, each block obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are defined by:
The node read unit that performs collation by referring to the data of each bit at the position indicated in the designated bit information and extracts the corresponding node entry, and performs collation of the data of the bit at a position not designated in the designated bit information. A node determining unit that determines whether the node entry read by the node reading unit correctly corresponds to a block obtained by dividing the target address of the search target. 13. The method according to claim 12, wherein an entry corresponding to the target address of the search target in the search table is searched by sequentially searching the node entry corresponding to each of the blocks obtained by dividing the target address of the target. The route search device according to the above.
【請求項14】 前記ノード判定部は、 検索対象の前記ブロックに該当する前記ノードエントリ
を、定められた個数である複数個、まとめて一度に抽出
する手段を備え、 前記ノード判定部は、 前記抽出された各ノードエントリのそれぞれを、当該検
索対象の前記ブロックに該当するか否かを判定し、正し
く該当する前記ノードエントリを検出することを特徴と
する請求項13に記載の経路検索装置。
14. The node determination unit, comprising: means for extracting a predetermined number of the node entries corresponding to the block to be searched, a plurality of them at once, the node determination unit comprising: 14. The route search device according to claim 13, wherein it is determined whether each of the extracted node entries corresponds to the block to be searched, and the node entry that is correctly detected is detected.
【請求項15】 IPv6のIPパケットの経路検索を
行なうことを特徴とする請求項13又は請求項14に記
載の経路検索装置。
15. The route search device according to claim 13, wherein a route search for an IPv6 IP packet is performed.
【請求項16】 前記目的アドレスのサイズを128ビ
ットとし、 前記ブロックのサイズを8ビットとし、 前記検索テーブルは、各前記目的アドレスを16個の前
記ブロックに分割することによる16階層の木構造とす
る、ことを特徴とする請求項15に記載の経路検索装
置。
16. The target address has a size of 128 bits, the block has a size of 8 bits, and the search table has a 16-layer tree structure by dividing each of the target addresses into 16 blocks. The route search device according to claim 15, wherein:
【請求項17】 前記指定ビット情報は、 前記ノード読み出し部が前記ノードエントリの抽出時に
照合する前記ブロック中のビット位置の指定を、当該ブ
ロックの全8ビットを照合する方式と、当該ブロックの
前半4ビットを照合する方式との、いずれか一方により
指定することを特徴とする請求項16に記載の経路検索
装置。
17. The method according to claim 17, wherein the designation bit information comprises: a method of collating all eight bits of the block with a designation of a bit position in the block to be collated by the node readout unit when extracting the node entry; 17. The route search device according to claim 16, wherein the designation is made by using one of a method of collating four bits.
【請求項18】 前記指定ビット情報は、 前記ノード読み出し部が前記ノードエントリの抽出時に
照合する前記ブロック中のビット位置の指定を、当該ブ
ロックの全8ビットを照合する方式と、各ノード毎のそ
れぞれにおいて予め定められた位置である当該ブロック
内の4個所のビットを照合する方式との、いずれか一方
の方式により指定することを特徴とする請求項16に記
載の経路検索装置。
18. The method according to claim 18, wherein the designated bit information includes a method of designating a bit position in the block to be collated by the node reading unit at the time of extracting the node entry, by collating all 8 bits of the block; 17. The route search device according to claim 16, wherein the designation is performed by using one of a method of collating four bits in the block, which are predetermined positions, respectively.
【請求項19】 IPパケットの目的アドレスを基に転
送先アドレスを決定しIPパケットを転送する交換機に
おいて、 前記目的アドレスによる木構造の探索を行なうための、
個々の目的アドレスのそれぞれに対応する転送先アドレ
スを示す検索テーブルを備え、 前記検索テーブルの各ノードにおける下位のノードエン
トリの探索を、各前記ノードのそれぞれの前記ノードエ
ントリの数に対応して指定された種類の多分木の探索方
法を用いて探索することを特徴とする交換機。
19. An exchange for determining a transfer destination address based on a destination address of an IP packet and transferring the IP packet, wherein a search for a tree structure based on the destination address is performed.
A search table indicating a transfer destination address corresponding to each of the target addresses; and specifying a search for a lower node entry in each node of the search table in accordance with the number of the node entries of each of the nodes. An exchange characterized in that a search is performed using a search method of a given type of multi-tree.
【請求項20】 前記検索テーブルは、 前記目的アドレスをその先頭から複数個の等長のブロッ
クに分割し、各前記ブロックを先頭から順次、上位の階
層から下位の階層に枝分かれさせて結ぶ階層構造による
木構造を有し、 各ノードにおいて、当該ノードからリンクする下位の各
ノードエントリを示すブロックのデータの記録と、前記
下位の各ノードエントリの抽出時において照合する前記
ブロック内のビット位置の指定を示す指定ビット情報の
記録を備えることを特徴とする請求項19に記載の交換
機。
20. The search table has a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and the blocks are sequentially linked from the beginning to the lower hierarchy from the upper hierarchy. In each node, at each node, record data of a block indicating each lower node entry linked from the node, and designate a bit position in the block to be collated when extracting each lower node entry 20. The exchange according to claim 19, further comprising a record of designated bit information indicating the following.
【請求項21】 各ノードにおいて、前記検索対象の目
的アドレスを分割した各ブロックと、当該ノードからリ
ンクする下位の各ノードエントリの前記ブロックとを、
前記指定ビット情報に示される位置の各ビットのデータ
を参照して照合し、該当する前記ノードエントリを抽出
するノード読み出し部と、 前記指定ビット情報に指定されていない位置のビットの
データの照合を行なうことにより、前記ノード読み出し
部により読み出された前記ノードエントリが、正しく前
記検索対象の目的アドレスを分割したブロックに該当す
るか否かを判定するノード判定部を備え、 各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索すること
を特徴とする請求項20に記載の交換機。
21. In each node, each block obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are
The node read unit that performs collation by referring to the data of each bit at the position indicated in the designated bit information and extracts the corresponding node entry, and performs collation of the data of the bit at a position not designated in the designated bit information. A node determining unit that determines whether the node entry read by the node reading unit correctly corresponds to a block obtained by dividing the target address of the search target. 21. The method according to claim 20, wherein an entry corresponding to the target address of the search target in the search table is searched by sequentially searching for the node entry corresponding to each of the blocks obtained by dividing the target address of the target. The exchange described.
【請求項22】 前記ノード判定部は、 検索対象の前記ブロックに該当する前記ノードエントリ
を、定められた個数である複数個、まとめて一度に抽出
する手段を備え、 前記ノード判定部は、 前記抽出された各ノードエントリのそれぞれを、当該検
索対象の前記ブロックに該当するか否かを判定し、正し
く該当する前記ノードエントリを検出することを特徴と
する請求項21に記載の交換機。
22. The node determination unit, comprising: means for extracting a predetermined number of the node entries corresponding to the block to be searched, a plurality of them at once, and the node determination unit comprises: 22. The exchange according to claim 21, wherein it is determined whether each of the extracted node entries corresponds to the block to be searched, and the node entry that is correctly detected is detected.
【請求項23】 IPv6のIPパケットの経路検索を
行なうことを特徴とする請求項21又は請求項22に記
載の交換機。
23. The exchange according to claim 21, wherein a route search for an IPv6 IP packet is performed.
【請求項24】 IPパケットの目的アドレスを基に転
送先アドレスを決定する経路検索方法において、 前記目的アドレスによる木構造の探索を行なうための、
個々の目的アドレスのそれぞれに対応する転送先アドレ
スを示す検索テーブルを参照するステップと、 前記検索テーブルの各ノードにおける下位のノードエン
トリの探索を、各前記ノードのそれぞれの前記ノードエ
ントリの数に対応して指定された種類の多分木の探索方
法を用いて探索するステップを備えることを特徴とする
経路検索方法。
24. A route search method for determining a transfer destination address based on a destination address of an IP packet, comprising:
Referring to a search table indicating a transfer destination address corresponding to each of the individual destination addresses; and searching for a lower node entry in each node of the search table according to the number of the node entries of each of the nodes. A step of searching using a multitree search method of the type specified in the step (a).
【請求項25】 前記検索テーブルは、 前記目的アドレスをその先頭から複数個の等長のブロッ
クに分割し、各前記ブロックを先頭から順次、上位の階
層から下位の階層に枝分かれさせて結ぶ階層構造による
木構造を有し、 各ノードにおいて、当該ノードからリンクする下位の各
ノードエントリを示すブロックのデータの記録と、前記
下位の各ノードエントリの抽出時において照合する前記
ブロック内のビット位置の指定を示す指定ビット情報の
記録を備えることを特徴とする請求項24に記載の経路
検索方法。
25. The search table has a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and each of the blocks is sequentially branched from an upper hierarchy to a lower hierarchy from the beginning. In each node, at each node, record data of a block indicating each lower node entry linked from the node, and designate a bit position in the block to be collated when extracting each lower node entry 25. The route search method according to claim 24, further comprising recording designated bit information that indicates
【請求項26】 各ノードにおいて、前記検索対象の目
的アドレスを分割した各ブロックと、当該ノードからリ
ンクする下位の各ノードエントリの前記ブロックとを、
前記指定ビット情報に示される位置の各ビットのデータ
を参照して照合し、該当する前記ノードエントリを抽出
するステップと、 前記指定ビット情報に指定されていない位置のビットの
データの照合を行なうことにより、前記ノード読み出し
部により読み出された前記ノードエントリが、正しく前
記検索対象の目的アドレスを分割したブロックに該当す
るか否かを判定するステップと、 各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索するステ
ップを備えることを特徴とする請求項25に記載の経路
検索方法。
26. In each node, each block obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are
Collating with reference to the data of each bit at the position indicated by the designated bit information to extract the corresponding node entry; collating the data of the bit at a position not designated in the designated bit information Determining whether the node entry read by the node reading unit correctly corresponds to a block obtained by dividing the target address of the search target. In each node, the target address of the search target is 26. The method according to claim 25, further comprising the step of sequentially searching for the node entry corresponding to each of the divided blocks to search for an entry corresponding to the target address of the search target in the search table. Route search method.
【請求項27】 前記検索テーブルの各前記ノードにお
ける前記指定ビット情報を、当該指定ビット情報におい
て指定されたビット位置において示されるデータのみに
より、各前記ノードからリンクする下位のノードエント
リが一意に識別されるように予め設定するステップを備
えることを特徴とする請求項26に記載の経路検索方
法。
27. A lower-level node entry linked from each node is uniquely identified from the designated bit information at each of the nodes in the search table by only data indicated at a bit position designated in the designated bit information. 27. The route search method according to claim 26, further comprising a step of presetting the route search.
【請求項28】 検索対象の前記ブロックに該当する前
記ノードエントリを、定められた個数である複数個、ま
とめて一度に抽出するステップと、 前記抽出された各ノードエントリのそれぞれを、当該検
索対象の前記ブロックに該当するか否かを判定し、正し
く該当する前記ノードエントリを検出するステップを備
えることを特徴とする請求項26に記載の経路検索方
法。
28. A step of extracting a plurality of node entries corresponding to the block to be searched, which is a predetermined number, all at once, and extracting each of the extracted node entries into the search object. 27. The route search method according to claim 26, further comprising the step of determining whether or not the block corresponds to the above-mentioned block, and detecting the node entry that corresponds to the block correctly.
【請求項29】 前記検索テーブルの各前記ノードにお
ける前記指定ビット情報を、当該指定ビット情報におい
て指定されたビット位置において示されるデータのみに
より探索した場合において、各前記ノードからリンクす
る下位のノードエントリの当該探索時に重複して該当す
る個数を、高々、前記ノード判定部が前記ノードエント
リを一度にまとめて取り出すことのできる前記定められ
た個数以下となるように予め設定するステップと、 各前記ノードにおける前記ノードエントリを、各前記指
定ビット情報毎に、当該指定ビット情報を用いた探索時
に重複して該当する前記ノードエントリをまとめて記録
するステップを備えることを特徴とする請求項28に記
載の経路検索方法。
29. A lower node entry linked from each of said nodes when said designated bit information at each of said nodes in said search table is searched for only by data indicated at a bit position designated in said designated bit information. Setting a number corresponding to the number of duplications at the time of the search at most to be equal to or less than the predetermined number at which the node determination unit can collectively extract the node entries at a time. 29. The method according to claim 28, further comprising the step of, for each specified bit information, collectively recording the node entries corresponding to the specified node information in a search when the specified bit information is used. Route search method.
【請求項30】 IPv6のIPパケットの経路検索を
行なうことを特徴とする請求項28又は請求項29に記
載の経路検索方法。
30. The route search method according to claim 28, wherein a route search of an IPv6 IP packet is performed.
【請求項31】 コンピュータを制御することにより、
IPパケットの目的アドレスを基に転送先アドレスを決
定する経路検索プログラムを記録した記録媒体におい
て、 前記目的アドレスによる木構造の探索を行なうための、
個々の目的アドレスのそれぞれに対応する転送先アドレ
スを示す検索テーブルを参照するステップと、 前記検索テーブルの各ノードにおける下位のノードエン
トリの探索を、各前記ノードのそれぞれの前記ノードエ
ントリの数に対応して指定された種類の多分木の探索方
法を用いて探索するステップを備えることを特徴とする
コンピュータにより読み取り可能な経路検索プログラム
を記録した記録媒体。
31. By controlling a computer,
A recording medium on which a route search program for determining a transfer destination address based on a destination address of an IP packet is recorded.
Referring to a search table indicating a transfer destination address corresponding to each of the individual destination addresses; and searching for a lower node entry in each node of the search table according to the number of the node entries of each of the nodes. A computer-readable recording medium storing a computer-readable path search program, the method further comprising a step of searching using a multitree search method of the type specified in the step (a).
【請求項32】 前記検索テーブルは、 前記目的アドレスをその先頭から複数個の等長のブロッ
クに分割し、各前記ブロックを先頭から順次、上位の階
層から下位の階層に枝分かれさせて結ぶ階層構造による
木構造を有し、 各ノードにおいて、当該ノードからリンクする下位の各
ノードエントリを示すブロックのデータの記録と、前記
下位の各ノードエントリの抽出時において照合する前記
ブロック内のビット位置の指定を示す指定ビット情報の
記録を備えることを特徴とする請求項31に記載のコン
ピュータにより読み取り可能な経路検索プログラムを記
録した記録媒体。
32. The search table has a hierarchical structure in which the target address is divided into a plurality of equal-length blocks from the beginning, and the blocks are sequentially connected from the beginning by branching from an upper hierarchy to a lower hierarchy. In each node, at each node, record data of a block indicating each lower node entry linked from the node, and designate a bit position in the block to be collated when extracting each lower node entry 32. The recording medium according to claim 31, further comprising recording of designated bit information that indicates a path search program readable by a computer.
【請求項33】 各ノードにおいて、前記検索対象の目
的アドレスを分割した各ブロックと、当該ノードからリ
ンクする下位の各ノードエントリの前記ブロックとを、
前記指定ビット情報に示される位置の各ビットのデータ
を参照して照合し、該当する前記ノードエントリを抽出
するステップと、 前記指定ビット情報に指定されていない位置のビットの
データの照合を行なうことにより、前記ノード読み出し
部により読み出された前記ノードエントリが、正しく前
記検索対象の目的アドレスを分割したブロックに該当す
るか否かを判定するステップと、 各ノードにおいて、前記検索対象の目的アドレスを分割
した各前記ブロックに該当する前記ノードエントリを順
次探索することにより、前記検索テーブル内の当該検索
対象の目的アドレスに該当するエントリを検索するステ
ップを備えることを特徴とする請求項32に記載のコン
ピュータにより読み取り可能な経路検索プログラムを記
録した記録媒体。
33. In each node, each block obtained by dividing the target address to be searched and the block of each lower node entry linked from the node are
Collating with reference to the data of each bit at the position indicated by the designated bit information to extract the corresponding node entry; collating the data of the bit at a position not designated in the designated bit information Determining whether the node entry read by the node reading unit correctly corresponds to a block obtained by dividing the target address of the search target. In each node, the target address of the search target is 33. The method according to claim 32, further comprising a step of sequentially searching for the node entry corresponding to each of the divided blocks to search for an entry corresponding to the target address of the search target in the search table. A recording medium recording a computer-readable route search program.
【請求項34】 前記検索テーブルの各前記ノードにお
ける前記指定ビット情報を、当該指定ビット情報におい
て指定されたビット位置において示されるデータのみに
より、各前記ノードからリンクする下位のノードエント
リが一意に識別されるように予め設定するステップを備
えることを特徴とする請求項33に記載のコンピュータ
により読み取り可能な経路検索プログラムを記録した記
録媒体。
34. The specified bit information at each of the nodes in the search table is uniquely identified as a lower node entry linked from each of the nodes only by data indicated at a bit position specified in the specified bit information. 34. The recording medium according to claim 33, further comprising a step of presetting a path search program readable by a computer.
【請求項35】 検索対象の前記ブロックに該当する前
記ノードエントリを、定められた個数である複数個、ま
とめて一度に抽出するステップと、 前記抽出された各ノードエントリのそれぞれを、当該検
索対象の前記ブロックに該当するか否かを判定し、正し
く該当する前記ノードエントリを検出するステップを備
えることを特徴とする請求項33に記載のコンピュータ
により読み取り可能な経路検索プログラムを記録した記
録媒体。
35. A step of extracting a plurality of node entries corresponding to the block to be searched, which is a predetermined number, all at once, and extracting each of the extracted node entries into the search target. 34. The recording medium according to claim 33, further comprising a step of determining whether or not the block corresponds to the block, and detecting the node entry that corresponds to the block correctly.
【請求項36】 前記検索テーブルの各前記ノードにお
ける前記指定ビット情報を、当該指定ビット情報におい
て指定されたビット位置において示されるデータのみに
より探索した場合において、各前記ノードからリンクす
る下位のノードエントリの当該探索時に重複して該当す
る個数を、高々、前記ノード判定部が前記ノードエント
リを一度にまとめて取り出すことのできる前記定められ
た個数以下となるように予め設定するステップと、 各前記ノードにおける前記ノードエントリを、各前記指
定ビット情報毎に、当該指定ビット情報を用いた探索時
に重複して該当する前記ノードエントリをまとめて記録
するステップを備えることを特徴とする請求項35に記
載のコンピュータにより読み取り可能な経路検索プログ
ラムを記録した記録媒体。
36. A lower node entry linked from each of said nodes when said specified bit information in each of said nodes of said search table is searched only by data indicated at a bit position specified in said specified bit information. Setting a number corresponding to the number of duplications at the time of the search at most to be equal to or less than the predetermined number at which the node determination unit can collectively extract the node entries at a time. 36. The method according to claim 35, further comprising the step of: collectively recording the node entries corresponding to each of the designated node entries in an overlapping manner when searching using the designated bit information for each of the designated bit information. A recording medium that stores a computer-readable route search program .
【請求項37】 IPv6のIPパケットの経路検索を
行なうことを特徴とする請求項35又は請求項36に記
載のコンピュータにより読み取り可能な経路検索プログ
ラムを記録した記録媒体。
37. The recording medium according to claim 35 or 36, wherein a path search of an IPv6 IP packet is performed.
JP2001004643A 2001-01-12 2001-01-12 Route search system, search method thereof, and recording medium storing route search program Expired - Fee Related JP3589349B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2001004643A JP3589349B2 (en) 2001-01-12 2001-01-12 Route search system, search method thereof, and recording medium storing route search program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2001004643A JP3589349B2 (en) 2001-01-12 2001-01-12 Route search system, search method thereof, and recording medium storing route search program

Publications (2)

Publication Number Publication Date
JP2002208947A true JP2002208947A (en) 2002-07-26
JP3589349B2 JP3589349B2 (en) 2004-11-17

Family

ID=18872800

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2001004643A Expired - Fee Related JP3589349B2 (en) 2001-01-12 2001-01-12 Route search system, search method thereof, and recording medium storing route search program

Country Status (1)

Country Link
JP (1) JP3589349B2 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1307584C (en) * 2003-11-17 2007-03-28 中兴通讯股份有限公司 Method for implementing tree storage and access by two-dimensional table
CN100442277C (en) * 2004-08-24 2008-12-10 侯方勇 Method and apparatus for optimizing test of Hasche tree integrity
KR102101419B1 (en) * 2019-03-04 2020-04-16 서강대학교 산학협력단 Method for routing table lookup and memory system implementing the same

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11341076A (en) * 1998-03-23 1999-12-10 Hitachi Ltd Network repeater and next network transfer destination retrieval method
JP2000115243A (en) * 1998-10-05 2000-04-21 Hitachi Ltd Packet repeater and multi-cast speedup system
JP2000324172A (en) * 1999-05-11 2000-11-24 Nec Corp Method for storing prefix concerning address
JP2000349811A (en) * 1999-06-09 2000-12-15 Nec Corp Communication controller

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11341076A (en) * 1998-03-23 1999-12-10 Hitachi Ltd Network repeater and next network transfer destination retrieval method
JP2000115243A (en) * 1998-10-05 2000-04-21 Hitachi Ltd Packet repeater and multi-cast speedup system
JP2000324172A (en) * 1999-05-11 2000-11-24 Nec Corp Method for storing prefix concerning address
JP2000349811A (en) * 1999-06-09 2000-12-15 Nec Corp Communication controller

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1307584C (en) * 2003-11-17 2007-03-28 中兴通讯股份有限公司 Method for implementing tree storage and access by two-dimensional table
CN100442277C (en) * 2004-08-24 2008-12-10 侯方勇 Method and apparatus for optimizing test of Hasche tree integrity
KR102101419B1 (en) * 2019-03-04 2020-04-16 서강대학교 산학협력단 Method for routing table lookup and memory system implementing the same

Also Published As

Publication number Publication date
JP3589349B2 (en) 2004-11-17

Similar Documents

Publication Publication Date Title
US6434144B1 (en) Multi-level table lookup
US7058642B2 (en) Method and data structure for a low memory overhead database
EP1623347B1 (en) Comparison tree data structures and lookup operations
US6691124B2 (en) Compact data structures for pipelined message forwarding lookups
US5946679A (en) System and method for locating a route in a route table using hashing and compressed radix tree searching
US7349382B2 (en) Reverse path forwarding protection of packets using automated population of access control lists based on a forwarding information base
US7415472B2 (en) Comparison tree data structures of particular use in performing lookup operations
CN111937360B (en) Longest prefix matching
EP1358739A2 (en) Method and apparatus for routing table management
JPS63231550A (en) Multiple virtual space control system
WO2001005116A2 (en) Routing method and apparatus
JP2004328433A (en) Communication controller, communication control method, communication control program, data structure for communication control
US7299317B1 (en) Assigning prefixes to associative memory classes based on a value of a last bit of each prefix and their use including but not limited to locating a prefix and for maintaining a Patricia tree data structure
US20020009056A1 (en) Route retrieving system, method therefor and a router device to be used in the same
JP2002208947A (en) Route retrieval system and its method and route recording medium with route retrieval program recorded
US7154892B2 (en) Method and apparatus for managing LPM-based CAM look-up table, and recording medium therefor
CN111865804B (en) Method and system for improving route issuing efficiency through hardware packet issuing mechanism
JP3660311B2 (en) Table search apparatus and method, program, and recording medium
US7539694B1 (en) Concurrently searching and manipulating binary trees
JP2004056639A (en) Address retrieval device
US20030031179A1 (en) Self-updateable longest prefix matching method and apparatus
US8199756B2 (en) Forwarding apparatus, forwarding method, and computer product
CN112565089B (en) Method and device for processing routing information
CN112115312B (en) Data name searching method, system and storage medium
JPH05241936A (en) Garbage collection processing system and storage device for the system

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20040427

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20040506

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20040705

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20040729

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20040811

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees