JPS6152739A - Method and apparatus of searching - Google Patents

Method and apparatus of searching

Info

Publication number
JPS6152739A
JPS6152739A JP59173310A JP17331084A JPS6152739A JP S6152739 A JPS6152739 A JP S6152739A JP 59173310 A JP59173310 A JP 59173310A JP 17331084 A JP17331084 A JP 17331084A JP S6152739 A JPS6152739 A JP S6152739A
Authority
JP
Japan
Prior art keywords
search
slice
level
bit
search engine
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
JP59173310A
Other languages
Japanese (ja)
Other versions
JPH0795324B2 (en
Inventor
Yuzuru Tanaka
譲 田中
Masashi Tsuchida
正士 土田
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.)
Hitachi Ltd
Original Assignee
Hitachi Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP59173310A priority Critical patent/JPH0795324B2/en
Priority to DE3588212T priority patent/DE3588212T2/en
Priority to EP91120314A priority patent/EP0478006B1/en
Priority to DE8585109999T priority patent/DE3587176T2/en
Priority to EP85109999A priority patent/EP0214313B1/en
Priority to US06/767,852 priority patent/US5185888A/en
Publication of JPS6152739A publication Critical patent/JPS6152739A/en
Publication of JPH0795324B2 publication Critical patent/JPH0795324B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PURPOSE:To attain flexible processing to variable length data with simple constitution by applying bit slice to constitute a search engine thereby changing the number of connections of search engine subjected to bit slicing. CONSTITUTION:The key word of the search engine is stored in the structure of LSBT and a search engine MBS20 applying search processing to the most significant (m) bit of a search key and a search engine 21BSE21 applying the search processing of each (m) bit of the search key except the MBSE20 are provided. Further, a CL50 is a control circuit disconnecting the search engine subject to bit slicing and the BSE21 with the CS51 set applies operation equivalent to the MBSE20. Thus, the processing high flexibility is simplified against the change in data length by setting or resetting an optional CS51.

Description

【発明の詳細な説明】 〔発明の利用分野〕 本発明は、データベース、あるいはファイルなどのサー
チ処理に関し、主としてサーチ処理専用ハードウェアお
よび処理方式などに好適なサーチ方式および装置に関す
るものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Application of the Invention] The present invention relates to search processing for databases or files, and mainly relates to a search method and apparatus suitable for search processing-dedicated hardware and processing methods.

〔発明の背景〕[Background of the invention]

データベース、あるいはファイル処理ばおいて、サーチ
処理は基本演算である。サーチ処理は、比較的負荷の高
い演算であり、使用頻度も高いので、サーチ処理の高速
化は重要である。ソフトウェアによってサーチ処理を実
現すると、データの比較、データ構造の操作などの処理
の効率が悪く、汎用コンピュータでは低効率にならざる
を得ない。
Search processing is a basic operation in database or file processing. Search processing is a computation with a relatively high load and is frequently used, so it is important to speed up the search processing. If search processing is implemented using software, processing such as data comparison and data structure manipulation will be inefficient, and a general-purpose computer will inevitably be inefficient.

そこで、サーチ処理専用ハードウェアを開発するという
動向にあるがLSI技術の発展とともに、ハードウェア
でサーチ処理を実現するための処理方式が数々提案され
ている。例えばO(LOGN)の比較器を持つサーチエ
ンジンが有望である(Tanaka Y、et、al、
、Pipeline SearchingandSor
ting Modules as Component
s of a DatafiowCon+puter、
IFIP Congress  80 ’ +pp、 
427−432 、 Oct、1980) 、しかし、
このサーチエンジンは、固定長データ処理を目指してい
るので、可変長データの取扱いが問題であった。
Therefore, there is a trend to develop hardware dedicated to search processing, and with the development of LSI technology, a number of processing methods have been proposed for realizing search processing using hardware. For example, search engines with O(LOGN) comparators are promising (Tanaka Y, et al.
, Pipeline Searching and Sor
ting Modules as Components
s of a DatafiowCon+puter,
IFIP Congress 80' +pp,
427-432, Oct. 1980), but
Since this search engine aims to process fixed-length data, handling variable-length data has been a problem.

本発明では、この問題を、ビットスライス化したサーチ
エンジンを採用することによりN消し、しかも、可変長
データに対して柔軟な処理を簡単な制御で行うことが可
能になった。
In the present invention, this problem can be solved by employing a bit-sliced search engine, and moreover, it has become possible to perform flexible processing on variable length data with simple control.

〔発明の目的〕[Purpose of the invention]

本発明の目的は、データ長の変化に対して、柔軟性の高
いサーチエンジンを提供し、特にLSI化を目射し、回
路構成をできるだけ簡単になるようなビットスライス化
サーチエンジン等のサーチ方式および装置を提供するこ
とにある。
An object of the present invention is to provide a search engine that is highly flexible in response to changes in data length, and is particularly aimed at LSI implementation, using a search method such as a bit slicing search engine that makes the circuit configuration as simple as possible. and equipment.

(発明の概要〕 従来のサーチエンジンは、すべて固定長データのサーチ
処理を目的として設計しており、データ長の変化に対す
る拡張性を必要とするデータベース、あるいはファイル
処理に対して、柔軟性が高いとは言い難い。そのため1
本発明では、サーチエンジンをビットスライス化して構
成し、ビットスライス化サーチエンジンを複数化接続す
る。データ長の変化に対しては、ビットスライス化サー
チエンジンの接続個数を変更することで対処する。
(Summary of the invention) Conventional search engines are all designed for the purpose of searching fixed-length data, and are highly flexible for database or file processing that requires scalability to changes in data length. It is difficult to say. Therefore, 1
In the present invention, a search engine is configured by bit slicing, and a plurality of bit slicing search engines are connected. Changes in data length are handled by changing the number of bit-slicing search engines connected.

この場合、各ビットスライス化サーチエンジン間で制御
情報の転送量をLSI化という面から最小限に抑える必
要がある。
In this case, it is necessary to minimize the amount of control information transferred between each bit slicing search engine from the viewpoint of LSI implementation.

そこで1本発明では、当該ビットスライス化サーチエン
ジンは、1つ上位のビットスライス化サーチエンジンだ
けから制御情報を入力し、当該ビットスライス化サーチ
エンジンの演算結果を1つ下位のビットスライス化サー
チエンジンだけに制御情報を出力するという構成とする
ものである。
Therefore, in the present invention, the bit slicing search engine inputs control information only from the next higher bit slicing search engine, and transfers the calculation result of the bit slicing search engine to the next lower bit slicing search engine. The configuration is such that control information is output only when the

〔発明の実施例〕[Embodiments of the invention]

以下、本発明を一実施例により詳細に説明する。 Hereinafter, the present invention will be explained in detail by way of an example.

サーチエンジンは、一括サーチ処理を高速に行う、サー
チ対象のデータであるキーワードは、昇順に、あるいは
降順に整列している。キーワードは、左充填2進木(以
下略してLSBTと書く)構造で格納する(例えば前記
文献参照)。ここで言うサーチ処理は、予めキーワード
をり、SBT構造で格納し、このLSBTとサーチキー
との演算処理を行い、サーチキーと一致するキーワード
格納アドレスの範囲を求めることである。
Search engines perform bulk search processing at high speed. Keywords, which are data to be searched, are arranged in ascending order or descending order. Keywords are stored in a left-filled binary tree (hereinafter abbreviated as LSBT) structure (see, for example, the above-mentioned document). The search processing referred to here means that a keyword is stored in advance in an SBT structure, and arithmetic processing is performed on this LSBT and a search key to find a range of keyword storage addresses that match the search key.

第1図は、サーチエンジンのサーチ処理過程を説明する
ためのものである。サーチエンジンは、キーワードを第
1図(a)に示すようにLSBT構造で格納している。
FIG. 1 is for explaining the search processing process of a search engine. The search engine stores keywords in an LSBT structure as shown in FIG. 1(a).

キーワードは、LSBTの各レベルに以下述べるように
格納する。すなわち、第ルベルに32.第2レベルに3
0.50、第3レベルに23.31,36.71を格納
する。
Keywords are stored in each level of LSBT as described below. That is, in the 32nd rubel. 3 to second level
0.50, 23.31, 36.71 are stored in the third level.

サーチエンジンのサーチ処理過程において。In the search processing process of search engines.

LSBTのルートノード、すなわち第1図の第ルベルか
ら始め、リーフノードへ向って進み、結果としてサーチ
キーと等しいキーワードを持つメモリバンクアドレスの
範囲を求める。第1図(a)では、サーチキーが31の
場合、サーチ処理においてLSBTを辿る手順を実線、
および破線で示す。実線は、サーチキーより大か等しい
という関係を満たすキーワードを持つメモリバンクアド
レスで最小のものを求める過程を示し、破線は、サーチ
キーより大という関係を満たすキーワードを持つメモリ
バンクアドレスで最小のものを求める過程を示す。第1
図(a)では、アドレスの小さい順にキーワード(23
,30,31,32゜36.50.71)を8順に格納
している。実線では、第ルベルのキーワード32とサー
チキー31との比較処理の結果、サーチキーの方が小で
あるので、LSBTの左側を辿る。次に、第2レベルの
キーワード30とサーチキー31との比較処理の結果、
サーチキーの方が大であるので、LSBTの右側を辿る
。、最後に、第3レベルのキーワード31とサーチキー
31とは等しいので、LSBTの左側を辿り終了する。
Starting from the root node of the LSBT, that is, the first rubel in FIG. 1, proceeding toward the leaf nodes, a range of memory bank addresses having a keyword equal to the search key is determined. In FIG. 1(a), when the search key is 31, the procedure for tracing the LSBT in the search process is shown by a solid line.
and indicated by dashed lines. The solid line shows the process of finding the smallest memory bank address that has a keyword that satisfies the relationship of greater than or equal to the search key, and the dashed line shows the process of finding the smallest memory bank address that has a keyword that satisfies the relationship of greater than or equal to the search key. The process of finding . 1st
In figure (a), keywords (23
, 30, 31, 32°36.50.71) are stored in 8 order. In the solid line, as a result of the comparison process between the keyword 32 of the th label and the search key 31, the search key is smaller, so the left side of the LSBT is traced. Next, as a result of the comparison process between the second level keyword 30 and the search key 31,
Since the search key is larger, follow the right side of LSBT. , Finally, since the third level keyword 31 and the search key 31 are equal, the left side of the LSBT is traced and the process ends.

この結果。As a result.

LSBTを左、右、左と辿り、左に0.右に1を対応さ
せることにより、010□ に2)番地からサーチキー
と等しいキーワードを格納していることが分る。このア
ドレスを左境界と呼ぶ。同様にして、破線では、第ルベ
ルのキーワード32とサーチキー31との比較処理の結
果、サーチキーの方が小であるので、LSBTの左側を
辿る。
Tracing LSBT left, right, left, 0. By associating 1 to the right, it can be seen that 010□ stores a keyword that is the same as the search key from 2) address. This address is called the left boundary. Similarly, on the broken line, as a result of the comparison process between the keyword 32 of the th level and the search key 31, the search key is smaller, so the left side of the LSBT is followed.

次に、第2レベルのキーワード30とサーチキー31と
の比較処理の結果、サーチキーが大であるので、LSB
Tの右側を辿る。最後に、第3レベルのキーワード31
とサーチキー31とは等しいので、左境界を求める場合
と異なり、LSBTの右側を辿り終了する。この結果、
LSBTを左。
Next, as a result of comparison processing between the second level keyword 30 and the search key 31, since the search key is large, the LSB
Follow the right side of the T. Finally, the third level keyword 31
and the search key 31 are equal, so unlike the case of finding the left boundary, the right side of LSBT is traced and the process ends. As a result,
Left LSBT.

右、右と辿り、左にO1右に1を対応させることにより
、011□ (=3)番地からサーチキーより大なるキ
ーワードを格納していることが分る。
By tracing from right to right and associating O1 with the left and 1 with the right, it can be seen that a keyword greater than the search key is stored starting from address 011□ (=3).

このアドレスを右境界と呼ぶ、左境界は、右境界より大
か等しいという性質を満たす。
This address is called the right boundary, and the left boundary satisfies the property that it is greater than or equal to the right boundary.

これまでは、2桁数字をサーチ処理の対象としえ、Jl
□、え。よい、1ッ、ユつイユイ、ヶー7.1′ンジン
を用いてサーチ処理を実現した例を第1図(b)に示す
、2桁数字を1桁数字ビットスライス化すると、2つの
ビットスライス化サーチエンジンで構成することになる
。第1番目スライスには、キーワード(2,3,3,3
,3,5,7)をアドレス順に格納し、第2番目スライ
スには、キーワード(3,0,1,2,6,0,1)を
アドレス順に格納する。サーチキー31も1桁数字ビッ
トスライス化し、第1番目スライスに3、第2番目スラ
イスに1をそれぞれサーチキーとして入力する0両スラ
イスにおいて、サーチ処理は、第ルベルから始まり、第
3レベルで終了し、左境界、右境界を決定する。ただし
、ビットスライス化サーチエンジンでは、第1番目スラ
イスの第ルベルの演算結果を用いて、第2番目スライス
の第ルベルの比較処理を行う必要がある。一般的に、第
(k+1)fR目ススライス第aレベルの比較処理を行
うために、第に番目スライスの第Qレベルの演算結果を
用いる必要がある。第1番目スライスで決定する左境界
、右境界の範囲は、同一レベルにおいて、第2番目スラ
イスで決定する左境界、右境界の範囲より大であるとい
う特徴を持つ、このことは、第1図(b)の第2番目ス
ライスのハツチング部分が、第1番目スライスの左境界
、右境界を示し、第2番目スライスの左境界。
Until now, only two-digit numbers could be searched, and Jl.
□, yeah. 7. An example of realizing search processing using the engine is shown in Figure 1 (b). When a two-digit number is converted into a one-digit number bit slice, two bit slices are created. It will consist of a search engine. The first slice contains the keyword (2, 3, 3, 3
, 3, 5, 7) are stored in address order, and the keywords (3, 0, 1, 2, 6, 0, 1) are stored in address order in the second slice. The search key 31 is also converted into a single-digit number bit slice, and in the 0-ryo slice where 3 is input into the first slice and 1 is input into the second slice as the search key, the search process starts from the 1st level and ends at the 3rd level. Then, determine the left boundary and right boundary. However, in the bit slicing search engine, it is necessary to perform a comparison process of the first rubel of the second slice using the calculation result of the first rubel of the first slice. Generally, in order to perform the comparison process of the a-th level of the (k+1)th fRth slice, it is necessary to use the calculation result of the Q-th level of the th slice. The range of the left boundary and right boundary determined by the first slice is larger than the range of the left boundary and right boundary determined by the second slice at the same level. The hatched portion of the second slice in (b) indicates the left boundary and right boundary of the first slice, and is the left boundary of the second slice.

右境界は、ハツチングで囲む領域内に存在することから
分る。
The right boundary can be seen from the fact that it exists within the area surrounded by hatching.

次に、第1番目スライスのサーチ処理過程を用いて、第
2番目スライスのサーチ処理過程を決定する手段につい
て述べる。まず、左境界を求める手順について述べる。
Next, a means for determining the search process for the second slice using the search process for the first slice will be described. First, the procedure for finding the left boundary will be described.

探索過程として4つのケースを考える。We consider four cases as part of the search process.

ケースX’:第1番目スライスの左境界、右境界、第2
番目スライスの左境界が 一致 ケースLL :第1番目スライスの左境界と第2番目ス
ライスの左境界が一致し。
Case X': Left boundary of the first slice, right boundary, second
Case LL where the left border of the 1st slice matches the left border of the 2nd slice.

第1番目スライスの右境界が両者 より大 ケースNL、第1番目スライスの左境界、第2番目スラ
イスの左境界、第1番目 スライスの右境界の順で大 ケースRL :第1番目スライスの右境界と第2番目ス
ライスの左境界が一致し、 第1@目スライスの左境界が両者 より小 第1番目スライスから第2番目スライスへ伝える制御情
報は、各レベル毎に、第1番目スライスの左境界が左側
、あるいは右側へ移動したことを示すCOLである。c
o’は、(0,1)を取り、左境界が左側に移動した場
合O1右側に移動した場合1となる。これらの制御情報
は、各スライスにおいて2次のレベルで左境界、右境界
を決定するため比較処理を行うキーワードを格納してい
るメモリバンクアドレスを生成するためにも用いられる
6また、第1番目スライスの左境界の移動方向をCIL
、第1番目スライスの右境界の移動方向をCl11で表
す、C0ND’は、キーワードがサーチキーより大か等
しい、もしくは、左境界が、キーワード格納するアドレ
スより大であることを示す真理値を取る。
Case NL where the right boundary of the first slice is larger than both, case RL where the left boundary of the first slice, left boundary of the second slice, right boundary of the first slice are larger in this order: RL: the right boundary of the first slice. The border and the left border of the second slice match, and the left border of the first @th slice is smaller than both.The control information transmitted from the first slice to the second slice is COL indicates that the left border has moved to the left or right. c.
o' takes (0, 1), and if the left boundary moves to the left, it becomes O1, and if it moves to the right, it becomes 1. These control information are also used to generate memory bank addresses that store keywords that are compared to determine the left and right boundaries at the secondary level in each slice. CIL the moving direction of the left border of the slice
, the moving direction of the right boundary of the first slice is represented by Cl11, and C0ND' takes a truth value indicating that the keyword is greater than or equal to the search key, or that the left boundary is greater than the address storing the keyword. .

以上、探索過程(X’、LL、NL、R’)とCI’。Above is the search process (X', LL, NL, R') and CI'.

CI’、C0ND’の4人力からCOLを決定する。COL is determined by the four people of CI' and C0ND'.

その状態遷移図を第2図(a)に示す。同様にして、右
境界の移動を示すCOI″を決定する。その状態遷移図
を第2図(b)に示す。
The state transition diagram is shown in FIG. 2(a). Similarly, COI'' indicating the movement of the right boundary is determined. Its state transition diagram is shown in FIG. 2(b).

最後に、同一レベルに関して、第1:?I¥目スラスラ
イス索過程を第2番目スライスで把握するために、探索
過程の状m遷移を考える。左境界を決定する探索過程の
状態と右境界を決定する探索過程の状態を対にすると、
下記の7通りの組合せが存在する。
Finally, regarding the same level, number 1:? In order to understand the I\th slice slice process in the second slice, consider the shape m transition of the search process. If we pair the state of the search process that determines the left boundary with the state of the search process that determines the right boundary, we get
There are the following seven combinations.

(X’、X”):第1番目スライスの左境界■ 第2番目スライスの左境界 口 第2番目スライスの右境界 ■ 第1番目スライスの右境界        I(LL、
L”):第」番目スライスの左境界第2番目スライスの
左境界 第2番目スライスの右境界 △ 第1@目スライスの右境界 (L’、N”):第1番目スライスの左境界第2ti目
スライスの左境界 △ 第2番目スライスの右境界 △ 第1番目スライスの右境界 (L’、R”):第1番目スライスの左境界■ 第2番目スライスの左境界 第2番目スライスの右境界 ■ 第1番目スライスの右境界 (NL、 NU)  、第1番目スライスの左境界△ 第2番目スライスの左境界 、へ■ 第2番目スライスの右境界 7・\ 第1番目スライスの右境界 (NL、 R1′)  :第1番目スライスの左境界△ 第2番目スライスの左境界 ゛ △ 第2番目スライスの右境界 ■ 第1番目スライスの右境界 (R’、 R11)  :第1番目スライスの左境界△ 第2番目スライスの左境界 口 第2番目スライスの右境界 口 第1番目スライスの右境界 サーチ処理は、第ルベルにおいて(x&、 xll)を
初期状態として始まる6第2図(c)に、左境界の探索
過程の状態遷移図、第2図(d)に、右境界の探索過程
の状態遷移図を示す。
(X',
L"): Left border of the 2nd slice. Left border of the 2nd slice. Right border of the 2nd slice. Left boundary of the 2ti-th slice △ Right boundary of the 2nd slice △ Right boundary of the 1st slice (L', R''): Left boundary of the 1st slice ■ Left boundary of the 2nd slice of the 2nd slice Right boundary ■ Right boundary of the 1st slice (NL, NU), left boundary of the 1st slice △ Left boundary of the 2nd slice, to ■ Right boundary of the 2nd slice 7・\ Right of the 1st slice Boundary (NL, R1'): Left boundary of the 1st slice △ Left boundary of the 2nd slice゛ △ Right boundary of the 2nd slice ■ Right boundary of the 1st slice (R', R11): 1st slice Left boundary of the slice △ Left boundary of the second slice Right boundary of the second slice The right boundary search process of the first slice starts with (x&, FIG. 2(c) shows a state transition diagram of the left boundary search process, and FIG. 2(d) shows a state transition diagram of the right boundary search process.

以上、サーチ処理過程は、4人力のオートマトン2個で
表現でき、サーチ結果を得ることができる。例では、2
個のビットスライス化サーチエンジンで3レベルのLS
BT構成のサーチエンジンであったが、k個のビットス
ライス化サーチエンジンで、2レベルのLSBT構成の
サーチエンジンについても同様にして実現できる。
As described above, the search processing process can be expressed by two automatons powered by four people, and the search results can be obtained. In the example, 2
3-level LS with bit-sliced search engine
Although the search engine has a BT configuration, a search engine with a two-level LSBT configuration using k bit-sliced search engines can be similarly implemented.

第3図は1本発明のサーチエンジンに刻するサーチキー
人力方法を示すものである。第3図では、k+1個のビ
ットスライス化サーチエンジンから構成される。ここで
、サーチキーの最上位mビットのサーチ処理を行うサー
チエンジンをモディファイドビットスライス化サーチエ
ンジン20(以下略してMBSE20と書<) 、MB
SE20以外で、サーチキーの各mビットのサーチ処理
を行うサーチエンジンをビットスライス化サーチエンジ
ン21(以下略してBSE21と書く)、各サーチエン
ジンに入力するビットスライス化したサーチキーを入力
ストリーム、各サーチエンジンから出力するアドレス情
報を出力ストリームと呼ぶ。
FIG. 3 shows a manual method of entering a search key into a search engine according to the present invention. In FIG. 3, it is composed of k+1 bit-slicing search engines. Here, a search engine that performs search processing for the most significant m bits of a search key is a modified bit slicing search engine 20 (hereinafter abbreviated as MBSE20), MB
In addition to the SE20, a search engine that performs search processing for each m bit of a search key is a bit-slicing search engine 21 (hereinafter abbreviated as BSE21), and a bit-slicing search engine 21 (hereinafter abbreviated as BSE21) is used as an input stream for the bit-sliced search keys input to each search engine. Address information output from a search engine is called an output stream.

ただし、MBSE20には、入力ストリーム0を入力、
出力ストリーム0を出力し、BSE21−1には、入力
ストリーム1を入力、出力ストリーム1を出力し、以下
BSE21−kには、入力ストリームkを入力、出力ス
トリームkを出力する。
However, input stream 0 is input to MBSE20,
Output stream 0 is output, input stream 1 is input to BSE 21-1, and output stream 1 is output. Below, input stream k is input to BSE 21-k, and output stream k is output.

MBSE20に関して、DT22は、サーチキーの最上
位mビット(人力ストリームO)の入力ボート、L83
6は、サーチキーと等しいか大となる関係を満たすキー
ワードを格納するメモリバンクアドレスの中で最小のも
のを出力するボート。
Regarding MBSE20, DT22 inputs the input port of the most significant m bits of the search key (manual stream O), L83
6 is a port that outputs the smallest memory bank address that stores keywords that satisfy the relationship of being equal to or greater than the search key.

RB37は、サーチキーより大となる関係を潤だすキー
ワードを格納するメモリバンクアドレスの中で最小のも
のを出力するボート、LO24−1、RO25−1は、
MBSE20の第ルベルで演算結果出力ポート、以下L
O26−L、RO27b−りは1MBSE20の第Lレ
ベルでの演算結果出力ポートである。各BSE21に関
して、DT23は、ビットスライス化したサーチキーの
各mビットの入力ボート、L838は、サーチキーと等
しいか大となる関係を満たすキーワードを格納するメモ
リバンクアドレスの中で最小のものを出力するボート、
RB39は、サーチキーより大となる関係を満たすキー
ワードを格納するメモリバンクアドレスの中の最小のも
のを出力するボート、LI28−1.RI29−1は、
第ルベルの1つ上位スライスから入力する制御情報信号
の入力ポート、以下LI30−L、RI31−Lは、第
Lレベルの1つ上位スライスから入力する制御情報信号
の入力ポート、LO32−1,RO32−1は、第ルベ
ルでの演算結果の出力ポート、以下、LO34−L、R
O35−Lは、第Lレベルでの演算結果の出力ポートで
ある。サーチキーは、第3図に示すようにに+1個にm
ビットスライス化している。MBSE20にal+。を
入力するのをタイム0とする。BSE21−1cに81
rk を入力するのは、タイムにである。すなわち、B
SE21−には、BSE21−に−1より1タイムずつ
演算が遅れて進行する。これは、BSE21−kにおい
て、a1+k を演算するために、BSE21−、k 
−1におけるa□、に−4に対する演算結果を必要とす
るためである。これらに関する制御情報を、BSE21
−には、BSE21−に−1より得る。
RB37 is a boat that outputs the smallest memory bank address that stores keywords that satisfy a relationship greater than the search key, and LO24-1 and RO25-1 are
Calculation result output port at the MBSE20 level, hereinafter L
O26-L and RO27b-ri are operation result output ports at the L-th level of 1MBSE20. For each BSE21, DT23 outputs the input port for each m bit of the bit-sliced search key, and L838 outputs the smallest memory bank address that stores a keyword that satisfies the relationship of being equal to or greater than the search key. boat,
RB39 is a port that outputs the smallest memory bank address that stores a keyword that satisfies the relationship of being greater than the search key, LI28-1. RI29-1 is
Input ports for control information signals input from the slice one above the L-th level, hereinafter referred to as LI30-L and RI31-L, are input ports for control information signals input from the slice one above the L-th level, LO32-1 and RO32. -1 is the output port of the calculation result at the 1st level, hereinafter LO34-L, R
O35-L is an output port for the calculation result at the L-th level. The search key is +1 m as shown in Figure 3.
Bit sliced. al+ for MBSE20. Time 0 is the input of . 81 to BSE21-1c
Enter rk in time. That is, B
In SE21-, the calculation progresses one time later than in BSE21-1. This is done in BSE21-k in order to calculate a1+k.
This is because a□ at -1 requires the calculation result for -4. Control information related to these, BSE21
- is obtained from BSE21- to -1.

第4図は、ビットスライス化サーチエンジンの構成図で
ある。第4図は、第3図のBSE21−kに相当する。
FIG. 4 is a block diagram of a bit slicing search engine. FIG. 4 corresponds to BSE21-k in FIG.

ビットスライス化サーチエンジンは、制御回路30(以
下略してCL30と書く)とキーワードを格納するメモ
リバンク31(以下略してMB31と書く)から構成さ
れる。キーワードをLSBT構造で格納するので、第ル
ベルのMB31−1に1ワード、第2レベルのMB31
−2に2ワード等、第LレベルのMB31−Lに2L−
1ワードをそれぞれ格納する。本発明のサーチエンジン
のサーチ処理は、LSBT構造のルートから始める。す
なわち、第ルベルのMB31−1とサーチキーとの演算
結果を伝え、以下同様に下位レベルへ進み、第Lレベル
のMB31−Lとサーチキーとの演算結果より、サーチ
キーと一致するキーワードの格納領域の範囲を求める。
The bit-slicing search engine includes a control circuit 30 (hereinafter abbreviated as CL30) and a memory bank 31 (hereinafter abbreviated as MB31) for storing keywords. Since keywords are stored in LSBT structure, one word is stored in MB31-1 of the second level, and one word is stored in MB31-1 of the second level.
2 words etc. to -2, 2L- to MB31-L of Lth level
Stores one word each. The search process of the search engine of the present invention starts from the root of the LSBT structure. That is, it conveys the calculation result between the MB31-1 of the Lth level and the search key, proceeds to the lower level in the same way, and stores the keyword that matches the search key based on the calculation result of the Lth level MB31-L and the search key. Find the range of the area.

第1図に示しているビットスライス化サーチ・エンジン
内部の各レベルの制御回路30は共通である。
The control circuitry 30 at each level within the bitslicing search engine shown in FIG. 1 is common.

各レベルにおける入力情報、出力情報に関して説明する
。ここでは、第αレベルについて述べる。
The input information and output information at each level will be explained. Here, the α-th level will be described.

32は、第(k−1)fi目ススライス第αレベルでの
演算処理結果、決定された左境界の移動方向を示す制御
情報、33は、同じく第(k−1)番目スライスの第α
レベルでの演算処理結果、決定された右境界の移動方向
を示す制御情報、310は、第2レベルのキーワードと
比較処理を行うサーチキー、311は、第(Q、 −1
)  レベルで演算処理結果、決定した左境界、312
は、第(Q−1)レベルで演算処理結果、決定した右境
界め動きを第(k+1)番目スライスの第αレベルへ云
える制御情報、37は、当該スライスの当該レベルでの
右境界の動きを第(k+1)番目スライスの第αレベル
へ伝える制御情報、313は、当該スライスの第(Q+
1)レベルへ伝えるサーチキー、314は、当該スライ
スの当該レベルでの演算処理結果、決定した左境界、3
14は、当該スライスの当該レベルでの演算処理結果、
決定した右境界を伝える入出力線である。
32 is control information indicating the moving direction of the left boundary determined as a result of the arithmetic processing at the α-th level of the fi-th (k-1)th slice; 33 is the α-th information of the (k-1)th slice;
310 is a search key that performs a comparison process with the keyword of the second level; 311 is the (Q, -1
) Level arithmetic processing result, determined left boundary, 312
37 is the control information that allows the determined right boundary movement to be directed to the α-th level of the (k+1)th slice as a result of the arithmetic processing at the (Q-1)th level; Control information 313 that conveys motion to the α-th level of the (k+1)th slice is
1) A search key 314 that transmits to the level is the result of arithmetic processing of the slice at the level, the determined left boundary, 3
14 is the arithmetic processing result of the slice at the relevant level;
This is an input/output line that conveys the determined right boundary.

第5図は、第4図に示すビットスライス化サーチエンジ
ン21−に中の第αレベルの制御回路30−Qの構成図
である。WL40は、第(Q −1)レベルの演算処理
結果、決定した左境界を入力するラッチ、WR41は、
第(ρ−1)レベルの演算処理結果、決定した右境界を
入力するラッチ、CL42は、第(Q−1)レベルで決
定する左境界、右境界で指すメモリバンク中のキーワー
ドとサーチキーとBSE21−に−1中の第2レベルか
ら入力する左境界、右境界の動きを表す制御情報を入力
とし、BSE21−に+1中の第αレベルへ当該スライ
スの当該レベルでの左境界、右境界の動きを出力する制
御回路、K43は、第(Q −1)レベルから入力する
サーチキーのラッチ、LB44は、当該スライスの当該
レベルでの演算結果の左境界の動きと第(Q −1)レ
ベルで決定した左境界を入力とし、第αレベルで決定し
た左境界を出力とするレジスタ、RB45は、当該スラ
イスの当該レベルでの演算結果の右境界の動きと第(Q
 −1)レベルで決定した右境界を入力とし、第αレベ
ルで決定した右境界を出力とするレジスタ、L046は
、当該レベルでの演算処理結果の左境界の動きを入力と
し、BSE21−に+1の第悲レベルへ左境界の動きを
出力とするラッチ、RO47は、当該レベルでの演算処
理結果の右境界の動きを入力とし、BSE21−に+1
の第αレベルへ右境界の動きを出力とするラッチである
FIG. 5 is a block diagram of the α-th level control circuit 30-Q in the bit slicing search engine 21- shown in FIG. WL40 is a latch that inputs the (Q-1)th level arithmetic processing result and the determined left boundary, and WR41 is
The latch CL42 inputs the arithmetic processing result of the (ρ-1)th level and the determined right boundary, and the keyword and search key in the memory bank pointed to by the left boundary and right boundary determined at the (Q-1)th level. Input control information representing the movement of the left boundary and right boundary input from the second level in -1 to BSE21-, and input the left boundary and right boundary at the relevant level of the slice to the α-th level in +1 to BSE21-. K43 is a latch for a search key input from the (Q-1)th level, and LB44 is a control circuit that outputs the movement of the left boundary of the calculation result at the level of the slice and the (Q-1)th level. The register RB45 receives the left boundary determined at the level α and outputs the left boundary determined at the α-th level.
-1) The register L046, which inputs the right boundary determined at the level and outputs the right boundary determined at the α-th level, inputs the movement of the left boundary of the arithmetic processing result at the level, and adds +1 to BSE21-. The latch RO47, which outputs the movement of the left boundary to the third level of
This is a latch that outputs the movement of the right boundary to the α-th level.

CL42は、第2図の状態遷移図を回路で実現したもの
である。BSE21−に中の第αレベルと第1表では、
32がCI’、33がCl11.36がCOL、 37
がCO8にそれぞれ対応する。
CL42 is a circuit that implements the state transition diagram of FIG. In Table 1 and the alpha level in BSE21-,
32 is CI', 33 is Cl11.36 is COL, 37
correspond to CO8, respectively.

LB44、RB45は、第(Q −1)レベルから入力
した左境界、右境界の最下位ビットに、当該レベルで決
定した左境界、右境界の動きを表すビットを合せて、第
αレベルでの左境界、右境界を決定し、第(fi+1)
レベルへ送出する。
LB44 and RB45 combine the least significant bits of the left boundary and right boundary input from the (Q-1)th level with the bits representing the movements of the left boundary and right boundary determined at that level, and calculate the result at the α-th level. Determine the left boundary and right boundary, and
Send to level.

第6図は、ビットスライス化サーチエンジンで可変長デ
ータを扱う場合を説゛明するためのものである。Cn2
Oは、ビットスライス化サーチエンジンの切離し制御を
行うための制御回路、C851は、Cn2Oに入力する
制御信号である。
FIG. 6 is for explaining the case where variable length data is handled by a bit slicing search engine. Cn2
O is a control circuit for controlling the separation of the bit slicing search engine, and C851 is a control signal input to Cn2O.

C551−0は常にONとし、MBSE2]:入力する
。第6図に示すように、各BSE21にCn2Oを設け
、C851をON、OFFすルコとにより、LI28.
RI29に、1つ上位スライスの出力信号LO32、R
O33をそのまま入力するか(C351=OFF(7)
l路合)、LI28にO,RI29に1を常に入力する
(C351=ONの場合)ことができる、この制御信号
は、同一スライスの各レベル共通して入力する。C85
1−kをONにしたBSE21−には、サーチキーの最
上位mビットの処理を行うR4B S E 20と等価
な動作を行う。したがって、任意のC351をON、O
FFに設定することにより、1つの長いデータのサーチ
処理を行うサーチエンジン、あるいは、短いデータのサ
ーチ処理を行う複数のサーチエンジンを構築することが
できる6〔発明の効果〕 本発明によれば、データ長の変化に対応したサーチエン
ジンが柔軟に構築可能である。ただし、サーチエンジン
は、ビットスライス化し、各ピッ1−スライス化サーチ
エンジンを複数個接続したものである。ビットスライス
化サーチエンジンから入出力する制御情報は各2ビツト
であり、N個のキーワードを対象とするサーチ処理では
C551-0 is always ON, and MBSE2]: is input. As shown in FIG. 6, by providing Cn2O in each BSE21 and turning on and off C851, LI28.
The output signals LO32 and R of the next higher slice are sent to RI29.
Input O33 as is (C351=OFF(7)
This control signal, which can always input O to LI28 and 1 to RI29 (when C351=ON), is commonly input to each level of the same slice. C85
The BSE 21- with 1-k turned on performs an operation equivalent to the R4B SE 20 that processes the most significant m bits of the search key. Therefore, any C351 can be turned on or off.
By setting FF, it is possible to construct a search engine that performs search processing for one long piece of data or multiple search engines that perform search processing for short data.6 [Effects of the Invention] According to the present invention, It is possible to flexibly construct a search engine that responds to changes in data length. However, the search engine is one in which a plurality of bit-sliced search engines are connected. The control information input and output from the bit-slicing search engine is 2 bits each, and in search processing targeting N keywords.

LOG、Nの比較器が必要であるので、ビットスライス
化サーチエンジンをLSI化した場合、必要ピン数は入
出力制御情報を合せて4・LOG2Nとなる。N=40
96とすると、この値は48となる。サーチキーを1ビ
ツトスライス化した場合、入力データ、電源、接地など
のビン数を合計しても50本強で済む。また、必要なト
ランジスタ数も、S RAM (Statie Ran
dom Access Memory )で10万個程
度、 DRAM (Dynamic RandomΔc
cess Memory )で5万個程度と予測され、
現在のLSI化技+l?でも充分実現可能である。
Since LOG, N comparators are required, if the bit slicing search engine is implemented as an LSI, the required number of pins including input/output control information will be 4.LOG2N. N=40
96, this value becomes 48. If the search key is sliced into 1-bit slices, the total number of bins for input data, power supply, ground, etc. will be just over 50. In addition, the number of transistors required is also
Dom Access Memory) is about 100,000 pieces, DRAM (Dynamic RandomΔc
cess Memory) is predicted to be around 50,000 pieces,
Current LSI technology +l? But it is quite possible.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は1本発明サーチエンジンのサーチ処理過程を示
すフロー図、第2図(a)、(b)。 (c)、(d)は本発明探索過程の遷移状態の説明図、
第3図は1本発明のサーチエンジンへのサーチキー人力
方法、第4図は、ビットスライス化サーチエンジンの構
成図、第5図は、ビットスライス化サーチエンジン内部
の制御回路構成図、第6図は、ビットスライス化サーチ
エンジンで可変長データを取扱う場合の解説図である。 20・・・モディファイドビットスライス化サーチエン
ジン、21・・・ビットスライス化サーチエンジン、3
0・・・制御回路、31・・・メモリバンク、50・・
・切祐2図 (すOoLり訂草 (刃 CO2の計算 第2図 (ご)ン:I;5 の〕ノこγ玖のンチL逅1(&芙慣
しじ〈トンC0ND”<tl )>’hy L ’i9
.yr うづてと残ヒ(右n’Jf>coHv”茗、3
ffi 出〃ストソームθ    fi刀又Tリーム1    
  甑でス]リー2(パニフ’r(4−7反う4スエリ
  Lオ又トリーへイー垢5図 局(1すlルへ]しへ
FIG. 1 is a flowchart showing the search processing process of the search engine of the present invention, and FIGS. 2(a) and (b). (c) and (d) are explanatory diagrams of the transition state of the search process of the present invention,
3 shows a manual search key method for a search engine according to the present invention, FIG. 4 is a block diagram of a bit-slicing search engine, FIG. 5 is a block diagram of a control circuit inside the bit-slicing search engine, and FIG. The figure is an explanatory diagram when variable length data is handled by a bit slicing search engine. 20... Modified bit slicing search engine, 21... Bit slicing search engine, 3
0... Control circuit, 31... Memory bank, 50...
・Kirisuke 2nd figure )>'hy L'i9
.. yr Uzute and Zanhi (right n'Jf>coHv" Mei, 3
ffi Outstosome θ fi Katamata T Ream 1
2 (Panif'r (4-7)

Claims (1)

【特許請求の範囲】 1、サーチ対象のデータであるキーワードを格納する領
域とサーチを行うサーチキーを格納する領域とサーチキ
ーの転送を制御する制御回路を有する系において、mビ
ットスライス化したキーワードの格納領域のデータとサ
ーチキーとの比較処理を行い、サーチキーと一致するキ
ーワードの格納領域の範囲を求めることを特徴とするサ
ーチ方式。 2、各スライスに関して、当該スライスのキーワードの
上位mビットを格納する1つ上位のスライスから1つ下
位のスライスへ制御情報が流れ、1つ上位のスライスで
サーチする探索範囲を当該スライスに伝え、1つ上位の
スライスの探索範囲内のキーワードだけを当該スライス
でサーチ対象とすることを特徴とする特許請求の範囲第
1項記載のサーチ方式。 3、制御情報により、1つの長いデータまたは短いデー
タを処理する複数のサーチエンジンを実現可能とする特
許請求の範囲第1項記載のサーチ方式。 4、サーチキーは、1つ上位のスライスと当該スライス
とでは1タイムずらし、パイプライン的に複数のサーチ
キーを入力し、サーチ処理を行うことを特徴とする特許
請求の範囲第1項記載のサーチ方式。 5、サーチ対象のデータであるキーワードを格納する手
段とサーチを行うサーチキーを格納する手段とサーチキ
ーの転送を制御する制御回路を有する系において、mビ
ットスライス化したキーワードの格納領域のデータとサ
ーチキーとの比較処理を行い、サーチキーと一致するキ
ーワードの格納領域の範囲を求める手段と、各スライス
に関して、1つ上位のスライスから入力する探索範囲の
動作を表す2つの制御情報と当該スライスのキーワード
とサーチキーとの比較結果の情報と探索過程の状態の情
報の計4つを入力とするオートマトンを2個有し、1つ
下位のスライスへ探索範囲を伝え、当該スライスの探索
過程の状態を決定する手段を有することを特徴とするサ
ーチ装置。
[Scope of Claims] 1. In a system having an area for storing a keyword which is data to be searched, an area for storing a search key for performing a search, and a control circuit for controlling transfer of the search key, an m-bit sliced keyword is used. A search method characterized by performing comparison processing between data in a storage area and a search key to determine the range of a storage area for keywords that match the search key. 2. Regarding each slice, control information flows from the next higher slice that stores the upper m bits of the keyword of the slice to the one lower slice, and tells the slice the search range to be searched in the next higher slice; 2. The search method according to claim 1, wherein only keywords within the search range of the next higher slice are searched for in that slice. 3. The search method according to claim 1, which makes it possible to implement a plurality of search engines that process one long piece of data or one short piece of data using control information. 4. The search key is shifted by one time between the next higher slice and the slice, and a plurality of search keys are inputted in a pipeline to perform the search process. Search method. 5. In a system having a means for storing a keyword which is data to be searched, a means for storing a search key for performing a search, and a control circuit for controlling transfer of the search key, m-bit sliced data in the keyword storage area and A means for performing a comparison process with a search key to determine the storage area range of keywords that match the search key, and for each slice, two pieces of control information representing the operation of the search range input from the next higher slice, and the slice concerned. It has two automatons that receive a total of four inputs: information on comparison results between keywords and search keys, and information on the state of the search process. A search device comprising means for determining a state.
JP59173310A 1984-08-22 1984-08-22 Search method and device Expired - Lifetime JPH0795324B2 (en)

Priority Applications (6)

Application Number Priority Date Filing Date Title
JP59173310A JPH0795324B2 (en) 1984-08-22 1984-08-22 Search method and device
DE3588212T DE3588212T2 (en) 1984-08-22 1985-08-08 Method and device for searching data
EP91120314A EP0478006B1 (en) 1984-08-22 1985-08-08 Method and apparatus for searching data
DE8585109999T DE3587176T2 (en) 1984-08-22 1985-08-08 METHOD AND DEVICE FOR MIXING / SORTING DATA.
EP85109999A EP0214313B1 (en) 1984-08-22 1985-08-08 Method and apparatus for data merging/sorting
US06/767,852 US5185888A (en) 1984-08-22 1985-08-21 Method and apparatus for data merging/sorting and searching using a plurality of bit-sliced processing units

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP59173310A JPH0795324B2 (en) 1984-08-22 1984-08-22 Search method and device

Publications (2)

Publication Number Publication Date
JPS6152739A true JPS6152739A (en) 1986-03-15
JPH0795324B2 JPH0795324B2 (en) 1995-10-11

Family

ID=15958072

Family Applications (1)

Application Number Title Priority Date Filing Date
JP59173310A Expired - Lifetime JPH0795324B2 (en) 1984-08-22 1984-08-22 Search method and device

Country Status (1)

Country Link
JP (1) JPH0795324B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0393615A (en) * 1989-09-06 1991-04-18 Daicel Chem Ind Ltd Production of formed carbon material
JP2001160292A (en) * 1999-09-10 2001-06-12 Sibercore Technologies Inc Content addressable memory device of variable width for retrieving data of variable width

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
A.KNUTH THE ART OF COMPUTER PROGRAMMENG VOL.3SORTENG AND SEARCHING=1973 *
IFIP CONGRESS80'=1980 *
THE ART OF COMPUTER PROGRAMMING V3 SORTING AND SEARCHINNG=1973 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0393615A (en) * 1989-09-06 1991-04-18 Daicel Chem Ind Ltd Production of formed carbon material
JP2001160292A (en) * 1999-09-10 2001-06-12 Sibercore Technologies Inc Content addressable memory device of variable width for retrieving data of variable width

Also Published As

Publication number Publication date
JPH0795324B2 (en) 1995-10-11

Similar Documents

Publication Publication Date Title
US6392910B1 (en) Priority encoder with multiple match function for content addressable memories and methods for implementing the same
Vintan et al. Towards a high performance neural branch predictor
EP0478006B1 (en) Method and apparatus for searching data
Poduval et al. Cognitive correlative encoding for genome sequence matching in hyperdimensional system
US20150070957A1 (en) Semiconductor device and method of writing/reading entry address into/from semiconductor device
US11669521B2 (en) Accelerated filtering, grouping and aggregation in a database system
KR20190131771A (en) Effective quantum RAM architecture for quantum database
Chen et al. A high-throughput FPGA accelerator for short-read mapping of the whole human genome
US20200401553A1 (en) Devices for time division multiplexing of state machine engine signals
KR20230170891A (en) In-memory efficient multistep search
US20230385258A1 (en) Dynamic random access memory-based content-addressable memory (dram-cam) architecture for exact pattern matching
Burkowski A hardware hashing scheme in the design of a multiterm string comparator
US7152141B2 (en) Obtaining search results for content addressable memory
JPS6152739A (en) Method and apparatus of searching
US10761847B2 (en) Linear feedback shift register for a reconfigurable logic unit
US11494676B2 (en) Architecture for table-based mathematical operations for inference acceleration in machine learning
Gu et al. Using disk based index and box queries for genome sequencing error correction
Chisvin et al. Content-addressable and associative memory
JPH03212896A (en) Content-addressable memory
JPH04111064A (en) Parallel string search device
JPS6150359B2 (en)
Dugan et al. A study of the utility of associative memory processors
KR920006794B1 (en) Method for searching an association matrix
JPH05282362A (en) Data retrieving circuit
Peng et al. A branch-and-bound-based minterm assignment algorithm for synthesizing stochastic circuit

Legal Events

Date Code Title Description
EXPY Cancellation because of completion of term