WO2007119540A1 - 連想メモリ - Google Patents

連想メモリ Download PDF

Info

Publication number
WO2007119540A1
WO2007119540A1 PCT/JP2007/056498 JP2007056498W WO2007119540A1 WO 2007119540 A1 WO2007119540 A1 WO 2007119540A1 JP 2007056498 W JP2007056498 W JP 2007056498W WO 2007119540 A1 WO2007119540 A1 WO 2007119540A1
Authority
WO
WIPO (PCT)
Prior art keywords
function
output
cam
lut
value
Prior art date
Application number
PCT/JP2007/056498
Other languages
English (en)
French (fr)
Inventor
Tsutomu Sasao
Original Assignee
Kyushu Institute Of Technology
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 Kyushu Institute Of Technology filed Critical Kyushu Institute Of Technology
Priority to US12/294,786 priority Critical patent/US8352677B2/en
Priority to JP2008510867A priority patent/JP4934825B2/ja
Publication of WO2007119540A1 publication Critical patent/WO2007119540A1/ja

Links

Classifications

    • GPHYSICS
    • G11INFORMATION STORAGE
    • G11CSTATIC STORES
    • G11C15/00Digital stores in which information comprising one or more characteristic parts is written into the store and in which information is read-out by searching for one or more of these characteristic parts, i.e. associative or content-addressed stores

Definitions

  • the present invention relates to an associative memory (content addressable memory: hereinafter referred to as "CAM”), and in particular, an associative memory capable of high-speed search, suppressing power consumption, and mounting with a small mounting area. About.
  • CAM content addressable memory
  • a normal memory generates registration data stored at an address (address) for a given index.
  • the CAM generates an index (address) of the CAM that stores the given search (input) data (see Non-Patent Documents 1 and 2).
  • CAM is widely used in various fields such as pattern matching, Internet router, processor cache, TLB (Translation Lookaside Buffer), data compression, database accelerator, dual net, and memory patch.
  • TLB Translation Lookaside Buffer
  • CAMs are classified into two types according to their functions: binary CAM (Binary CAM: “BCAM” t hereafter) and ternary CAM (Ternary CAM: TCAM). Is done. In BCAM, 0 and 1 are stored in each cell. TCAM stores 0, 1, and * in each cell. Here, “*” represents don't care and matches both 0 and 1.
  • a BCAM table with n entries and a registration data count of p stores p different binary vectors. Also assume that p vectors are stored in order from address 1 to address p. Each vector address can be expressed in m bits. m is expressed by the following equation (1).
  • Table 1 shows a BCAM that stores seven binary vectors.
  • the corresponding BCAM functions are shown in (Table 2). In either case, the address that stores the vector that completely matches the input data is output as a 3-bit number (eg, '011'). If the input vector does not match the BCAM, 0 is output.
  • the TCAM table with ⁇ elements and ⁇ elements stores ⁇ ternary vectors. Also assume that ⁇ vectors are stored in order from address 1 to address ⁇ . Each vector address can be expressed in m bits. Here, m is represented by the above formula (1). Each ternary vector consists of 0, 1, or * (don't care).
  • Corresponding TC AM function: f: ⁇ 0, l ⁇ n ⁇ ⁇ 0, l ⁇ m satisfies the following condition:
  • output x indicates the lowest address in the matched vector. If there is no vector in the TCAM table that matches X, 0 is output.
  • the TCAM shown in (Table 3) stores seven ternary vectors.
  • the corresponding TCAM functions are shown in (Table 4).
  • the input ⁇ (1,0,1,1) matches the pattern stored at addresses 5 and 6. Since 5 is smaller, the output is (0,1,0,1). (End of example)
  • FIG. 8 is a block diagram showing an example of a basic configuration of a conventional CAM (see Patent Document 1).
  • CAM 100 includes comparison register 101, search bit line driver 102, n words W to W, n match sense circuits MSC to MSC, n match flag registers MFR to MFR, and priority encoder (priority code). Circuit) with PE.
  • the comparison register 101 is a register that stores m-bit search data.
  • the search bit line driver 102 drives each bit of the comparison register 101 onto the search bit line.
  • Each node W to W has m-bit CAM cells.
  • FIG. 9 is a configuration circuit diagram of the CAM cell in FIG.
  • the CAM cell 103 illustrated in FIG. 9 is of a mismatch detection type.
  • the CAM cell 103 includes a memory cell 104 and a coincidence comparison circuit 105.
  • Memory 'cell 104 is an SRAM-configured memory' cell that stores 1-bit data.
  • D represents data
  • DN represents inverted data.
  • the match comparison circuit 105 compares the 1-bit data stored in the memory cell 104 with the search data driven on the search bit line pair SL, SLN, and outputs the match comparison result on the match line ML.
  • the match comparison circuit 105 compares the 1-bit data stored in the memory cell 104 with the search data driven on the search bit line pair SL, SLN, and outputs the match comparison result on the match line ML.
  • the coincidence comparison circuit 105 includes three nMOS transistors (hereinafter “nMOS” t) 106, 10 7, and 108.
  • the nMOSs 106 and 107 are connected in series between the search bit line SLN and the search bit line SL.
  • the gates of the nMOSs 106 and 107 are connected to the data D and the inverted data DN of the memory cell 104, respectively.
  • the nMOS 108 is connected between the match line ML and the ground.
  • the gate of the nMOS 108 is connected to the node 109 between the nMOSs 106 and 107.
  • data to be searched is stored in each word W to W of the CAM 100.
  • data writing to the memory cell 104 and data reading from the memory cell 104 are performed in the same manner as in ordinary SRAM.
  • search data is stored in the comparison register 101.
  • Each bit of the search data is driven by the search bit line driver 102 onto the corresponding search bit line.
  • each word W to W data and a search bit stored in advance in each CAM cell A match search with the search data driven on the line is executed simultaneously (in parallel), and the result is output on the matching line ML to ML.
  • These search results are input to the coincidence sense circuits MSC to MSC, respectively.
  • Each match sense circuit MSC to MSC amplifies each search result and outputs it as a match sense output to match sense output lines MT to MT.
  • Each match sense output is stored in the match flag registers MFR to MFR and output to the match flag output output lines MF to MF as a match flag output. In the match flag, “1” represents “match”, and “0” represents “no match”.
  • Each match flag output is input to a priority 'encoder PE.
  • the priority 'encoder PE selects and outputs the address of the highest priority word (highest priority match address: HMA) from the detected words according to the predetermined prioritization. As for the priority of each word, it is assumed that the priority becomes lower in order as the power of W is the highest.
  • each CAM cell 103 in each word W to W is executed as follows.
  • each bit of the search data stored in the comparison register 101 is input to each CAM cell 103 via the search bit line.
  • the search data S one of the search bit line pairs S L and SLN becomes “H” and the other becomes “L”.
  • the level of the node 109 is' L, and the nMOS 108 is held in the off state.
  • the CAM word match line ML composed of m-bit CAM cells 103 constitutes a wired OR circuit in which the nMOSs 108 of the CAM cells 103 are connected in parallel. Therefore, the match line ML is held in the “ ⁇ ” (“match”) state only when a match is detected in all of the m-bit CAM cells 103 constituting one word. On the other hand, if a mismatch is detected in CAM cell 103 even for one bit, match line ML becomes 'L'("mismatch").
  • W address can be output as HMA. Similarly, a match is detected.
  • the addresses of the read words can be output sequentially.
  • FIG. 10 is a configuration circuit diagram of another example of the CAM cell in FIG.
  • the CAM cell 103 shown in FIG. 10 is of a coincidence detection type, and includes a memory cell 104 having an SRAM configuration and a match comparison circuit 105 as in FIG.
  • the CAM cell 103 differs from the CAM cell 103 in FIG. 9 in the connection of the nMOS 108 of the coincidence comparison circuit 105.
  • the nMOS 108 in FIG. D is connected between the match line ML and the match line ML.
  • the gate of nMOS108 is nMOS106, 10 a b
  • the bit line pair SL and SLN are both set to “H” as an initialization operation at the time of search.
  • one of the nMOSs 106 and 107 of the coincidence comparison circuit 105 is turned on and the other is turned off. Therefore, the level of the node 109 between the nMOSs 106 and 107 becomes “ ⁇ ” via the on state, and the nMOS 108 is turned on.
  • a match line ML of CAM words composed of m-bit CAM cells 103 constitutes an AND circuit in which nMOSs 108 of the CAM cells 103 are serially connected. Therefore, each CA The coincidence lines ML and ML of the M cell are ' ⁇ ' via the nMOS 108 of each CAM cell 103.
  • each bit of the search data stored in the comparison register 101 is input to each CAM cell 103 ′ via the search bit line.
  • search data S one of the search bit line pair SL, SLN becomes “H” and the other becomes “L”.
  • the 109 level is 'H,' and the nMOS 108 is kept on.
  • the level of the node 109 becomes 'L', and the nMOS 108 is turned off.
  • the match comparison result is 'L', that is, a match state.
  • the search bit line pair S is used for the don't care bit.
  • Patent Document 1 Japanese Patent Application Laid-Open No. 2004-295967
  • Patent Document 2 Japanese Patent Application No. 2003-389264 Specification
  • Patent Document 3 Japanese Patent Application Laid-Open No. 2004-258799
  • Patent Document 4 Japanese Patent Laid-Open No. 2004-258799
  • Non-Patent Document 1 Supervised by Takuo Kanno, Satoshi Kayama, “Ultra High-Speed Device, Series 2 Ultra High-Speed MOS Device”, First Edition, Baifukan, February 1986, pp. 324-325.
  • Non-Patent Document 2 The Institute of Electronics, Information and Communication Engineers, “LSI Handbook”, 1st edition, Ohmsha, November 1994, pp. 523-525.
  • Non-patent literature 3 Kostas Pagiamtzis ana Ali Sheikholeslami, A Low-Power Content- Addressable Memory (CAM) Using Pipelined Hierarchical Search Scheme ", IEEE Journal of Solid-State Circuits, Vol.39, No.9, Sept.2004 , pp.1512- 1519.
  • Patent Document 4 T. Sasao, M. Matsuura, and Y. Iguchi, "A cascade realization of multi-o utput lunction for reconfigurable hardware ", International Workshop on Logic and Synthesis (IWLS01), Lake Tahoe, CA, June 12-15, 2001, pp.225—230.
  • Patent Document 5 T. Sasao and M. Matsuura, "BDD representation for incompletely sped fied multiple-output logic functions and its applications to lunctional decomposition,
  • Non-Patent Document 6 Iguchi, Kashio, “LUT Cascade” Architecture, “The Institute of Electrical Engineers of Japan“ Information ”System Division Conference, MC2-4, August 29-30, 2003, Akita University.
  • the conventional CAM is faster than a RAM because it can be searched in parallel.
  • the price per bit (bit cost) of CAM is about 10 to 30 times higher than RAM.
  • the power consumption per bit is about 50 times that of normal RAM.
  • an object of the present invention is to provide an associative memory that can be mounted with a small mounting area by reducing the power consumption and simplifying the structure of the device while maintaining the high-speed search. is there.
  • the row labels are all possible combinations of X and B components. Is assigned to each other. Also, the corresponding matrix value is equal to the value of ⁇ , ⁇ )
  • the decomposition table of H nL + 1 nL + 2 n) is called “basic decomposition table”.
  • the number of different column patterns in the decomposition table is the “column complexity” of the decomposition table.
  • the C measure is a measure of the complexity of implementing a logical function with a LUT force scale.
  • the C measure for that BCAM function is at most p + 1.
  • the CAM function can be realized with ordinary RAM.
  • the BCAM function of element 7 shown in (Table 1) above can be realized with 16-word RAM as shown in (Table 2).
  • each word is 3 bits.
  • the size of the RAM increases in proportion to 2 n even if the BCAM contains only a few vectors. Therefore, using the LUT cascade makes it possible to significantly reduce the amount of memory required (see Patent Document 3).
  • L is a variable corresponding to a column of the decomposition table
  • H be the variable corresponding to the row, and be the column complexity of the decomposition table.
  • the function f can be realized by a circuit as shown in FIG.
  • the number of signal lines connecting between the two blocks H and G (hereinafter referred to as “the number of rails”) is
  • a LUT cascade as shown in Fig. 2 can be obtained by repeatedly decomposing a given function (see Non-Patent Document 4).
  • the LUT cascade consists of “cells”, and the signal line that connects adjacent cells is called a “rail”.
  • a function with a small C scale can be realized with a small LUT cascade.
  • It is efficiently calculated from a binary decision diagram (Binary Decision Diagram for Characteristic Function: hereinafter referred to as “BDD_for_CF”). be able to( (See Patent Document 2 and Non-Patent Document 5).
  • a cell force of log 2 ⁇ ⁇ (4) can also be realized with a configured LUT cascade.
  • n is an external input variable
  • s is the number of cells
  • r is the maximum number of rails (ie, the number of signal lines between cells)
  • k is the maximum number of input cells
  • is the C scale of the function f.
  • LUT cascade 1 Generate LUT cascade 1 from the simplified BDD.
  • LUT cascade 1 is simpler than the 3 ⁇ 4 realized LUT cascade (this is called the “strict LUT cascade”).
  • the auxiliary memory 2 stores the corresponding data of the BCAM table at each address.
  • the total number of bits of the auxiliary memory 2 is n2 m , and the hardware cost is negligible compared to the LUT cascade 1 cost.
  • the TCAM table has three values, so auxiliary memory 2 has m inputs and 2n outputs. In the match circuit 3, the bit corresponding to the don't care is ignored.
  • the other parts are the same as BCAM.
  • the structure of the associative memory according to the present invention is an associative memory that outputs a unique index corresponding to the input data.
  • CAM Content Addressable Memory
  • Simple CAM function A function that replaces the invalid output value of f with don't care (hereinafter “simplified CAM function”) (Referred to as “reduced content addressable memory routing”).
  • LUT coupled logic circuit or PLA Programmable Logic Array
  • An auxiliary memory storing the inverse function f_1 of the CAM function f;
  • Match determination means for determining whether the output value of the LUT calculation means matches the output of the CAM function f;
  • the LUT calculation means outputs a calculation value of the simplified CAM function g (hereinafter referred to as “temporary index value”) as a read address of the auxiliary memory for the input data, and the auxiliary memory stores the temporary index.
  • temporary index value a calculation value of the simplified CAM function g (hereinafter referred to as “temporary index value”) as a read address of the auxiliary memory for the input data
  • the auxiliary memory stores the temporary index.
  • the value of the inverse function f _ 1 for the temporary index value is output.
  • the determination means compares the input data with the value of the inverse function f_1 output from the auxiliary memory, and if both match, outputs the output value of the LUT calculation means, otherwise invalid A signal is output.
  • the LUT coupling logic circuit can be configured using a plurality of normal RAMs.
  • the auxiliary memory can also be composed of normal RAM.
  • the LUT coupling logic circuit or PLA that expresses the simplified gfunction g in which the invalid output value of the CAM function f is replaced by don't care instead of the LUT coupling logic circuit that represents the CAM function f itself, The amount of memory required to configure a LUT coupled logic circuit or PLA can be greatly reduced. Therefore, as a whole, the device structure can be simplified and mounted with a small mounting area compared to the conventional CAM.
  • a dedicated CAM circuit is not required. Therefore, in addition to ASIC configuration, it can be easily configured at low cost by using programmable devices such as FPG A (Field Programmable Gate Array) and CLD (Complex Programmable Logic Device) with built-in general-purpose RAM. You can also
  • All but the determination means can be configured with normal RAM.
  • a temporary index value can be obtained by RAM access several times (number of RAM accesses in the LUT coupling logic circuit + 1) for one search operation. For each RAM access, only one address in the RAM is accessed.
  • provisional index values can be obtained with only a few RAM accesses. Therefore, power consumption can be significantly reduced compared to conventional CAM.
  • LUT coupling logic circuit refers to a circuit in which a plurality of LUTs (Look-Up Tables) are coupled in cascade or network form, but a plurality of LUTs are not necessarily arranged in hardware. do not have to. For example, even a circuit that stores multiple LUTs in one memory and realizes LUT coupling by feeding back the memory output value to the memory read address while sequentially switching the selection of LUTs. Yo ...
  • the LUT connection logic circuit is a LUT connected in a network. It is also possible to use a LUT network or the like.
  • an associative memory that can be mounted with a small mounting area by reducing the power consumption and simplifying the structure of the device while maintaining the high-speed search. be able to.
  • FIG. 1 is a diagram illustrating functional decomposition of a logical function.
  • FIG. 2 is a diagram representing a LUT cascade having an intermediate output.
  • FIG. 3 is a diagram for explaining a method for realizing a CAM function using don't care.
  • FIG. 4 is a diagram illustrating an overall configuration of an associative memory according to the first embodiment of the present invention.
  • FIG. 5 is a diagram showing the configuration of the simplified key function calculation unit 5 of FIG.
  • FIG. 6 is a diagram showing the configuration of the coincidence determination means 7 in FIG.
  • Fig. 7 is a diagram illustrating a configuration of an associative memory matching determination unit 7 according to the second embodiment.
  • FIG. 8 is a block diagram showing an example of a basic configuration of a conventional CAM.
  • FIG. 9 is a configuration circuit diagram of the CAM cell in FIG.
  • FIG. 10 is a configuration circuit diagram of another example of the CAM cell in FIG.
  • FIG. 4 is a diagram illustrating the overall configuration of the associative memory according to the first embodiment of the present invention.
  • the associative memory 10 of this embodiment includes a simplified function calculation unit 5, an auxiliary memory 6, and a coincidence determination means 7.
  • the input data X is input to the simplified function calculation unit 5 and the coincidence determination means 7.
  • the CAM function that outputs the unique index A corresponding to the input data X with respect to the input data X will be denoted as F.
  • the simplified CAM function in which invalid index values are replaced with don't care is denoted as G.
  • the simplified function calculation unit 5 includes a LUT coupling logic circuit that calculates the simplified CAM function G.
  • an inverse function F of the CAM function F—that is, a data output function for outputting data X corresponding to the index A for a specific index A is stored as an LUT.
  • the temporary index A ′ is output to the coincidence determination means 7.
  • the coincidence determination means 7 compares the input data X and the back-calculation data X 'and determines whether or not they match. Determine whether. If both match, the temporary index A 'is set as the output index.
  • FIG. 5 is a diagram illustrating a configuration of the simplified key function calculation unit 5 of FIG. In this example 1,
  • the LUT cascade logic circuit is used as the simplified function calculation unit 5.
  • the simplified function operation unit 5 includes an input variable register 11, logical function memories 12-1 to 12-s, and an output variable register 13.
  • the input variable register 11 is a register that temporarily holds input data X input from the outside.
  • the logical function memories 12-1 to 12-s are stored as partial functions G, ---, G force LUT of the CAM function G obtained by functional decomposition of the simplified CAM function G.
  • each partial function G,-, G is as follows.
  • the vector A ', ⁇ ', ..., ⁇ ' is the intermediate output of the LUT cascade, and the vector A
  • the temporary index A ' is expressed as a combination of these vectors.
  • the vectors R, R, ---, R represent intermediate variables of the LUT cascade.
  • the output variable register 13 is an intermediate output A ′ output from each logical function memory 12—l to 12—s.
  • FIG. 6 is a diagram illustrating the configuration of the coincidence determination unit 7 in FIG.
  • the input data X is 8 bits and the output index A is 8 bits.
  • the number of bits of the input data X and the output index A is not limited to this.
  • the coincidence determination means 7 includes an EXNOR gate 2 provided corresponding to each bit of the input data X. 1, A AND gate 22 and A provided for each bit of output index A
  • EXNOR gate 21 Input to EXNOR gate 21 to perform EXNOR operation.
  • the operation result of each EXNOR gate 21 is input to the AND gate 22 and AND operation is performed.
  • the output Q of the AND gate 22 is called a coincidence determination signal.
  • each bit a ', a', ..., & 'of the temporary index A' is assigned to each AND gate 23.
  • the simplified function calculation unit 5 calculates the CAM function G (X) and outputs the result as a temporary index A ′.
  • the value of the temporary index A matcheses the true index value.
  • the value of provisional index A ' is don't care. Therefore, the provisional index A 'contains a true index, but it cannot be determined whether the value represents a true index or don't care.
  • the temporary index A ′ is input to the auxiliary memory 6.
  • the temporary index A ′ represents a true index
  • the back-calculated data X ′ has the same value as the input data X.
  • the temporary index A ' is don't care, the temporary index A' is a flawless value, so an invalid value is output to the back-calculation data X '.
  • EXNO R gate 21 is a logical operation
  • Each operation value q. I s input to the AND gate 22, and an AND operation is performed.
  • the coincidence determination signal Q is 1 when the components of the input data X and the back-calculation data X ′ are completely coincident, and the coincidence determination signal Q is 0 otherwise. Therefore, by using the coincidence determination signal Q, it is possible to determine whether or not the temporary index A ′ represents a true index value.
  • the CAM function is calculated for the input data X.
  • the simple key function calculation unit 5 and the auxiliary memory 6 are all configured by memories, and thus can be configured using ordinary RAM. Therefore, the process can be easily miniaturized and the circuit scale can be reduced. In addition, since it is a memory, it is possible to reduce power consumption by setting the unused period to a power saving state.
  • FIG. 7 is a diagram illustrating the configuration of the simplified power function calculation unit 5 of the associative memory according to the second embodiment.
  • the simplified power function calculation unit 5 of this embodiment has a configuration in which a plurality of pq elements 31 are coupled in a bowl shape.
  • the pq element 31 is a p input q output memory.
  • the values of p and q of each pq element 31 are arbitrarily set for each pq element 31.
  • Each pq element 31 has a simplified ⁇ CAM function G.
  • the partial functions G, G, ... obtained by the number decomposition are stored as LUTs. Multiple like this
  • a circuit in which the pq elements 31 are coupled in a bowl shape is referred to as a “pq network”.
  • FIG. 7 is an example, and the way of coupling the pq elements 31 is appropriately selected by the CAM function G.

Landscapes

  • Memory System (AREA)
  • Semiconductor Memories (AREA)

Abstract

 検索の高速性を維持しつつも、消費電力を抑え且つデバイスの構造を簡単化して小さい実装面積で実装可能な連想メモリを提供する。  CAM関数fの無効出力をドントケアで置換した簡略化CAM関数gのLUT結合論理回路で構成された簡略化関数演算部と、CAM関数fの逆関数f-1が記憶された補助メモリと、LUT演算手段の出力がCAM関数fの出力に一致するか判定する一致判定手段とを備え、LUT演算手段は、入力データに対し簡略化CAM関数gの演算値(仮インデックス値)を出力し、補助メモリは、仮インデックス値が入力されるとそれに対しする逆関数f-1の値を出力し、判定手段は、入力データと逆関数f-1の値とを比較して、両者が一致する場合はLUT演算手段の出力値を出力し、それ以外の場合は無効信号を出力する。

Description

明 細 書
連想メモリ
技術分野
[0001] 本発明は、連想メモリ(内容検査メモリ: Content Addressable Memory:以下「CAM 」という。 )に関し、特に、高速検索が可能で、消費電力を抑え、且つ小さい実装面積 で実装可能な連想メモリに関する。
背景技術
[0002] 通常のメモリは、与えられたインデックス(アドレス)に対して、そのアドレスに格納さ れている登録データを生成する。一方、 CAMは、与えられた検索 (入力)データに対 して、それを格納する CAMのインデックス (アドレス)を生成する(非特許文献 1, 2参 照)。
[0003] CAMは、パターン 'マッチング、インターネットのルータ、プロセッサのキャッシュ、 T LB (Translation Lookaside Buffer)、データ圧縮、データベースのァクセラレータ、二 ユーラルネット、メモリパッチなど幅広 、分野にぉ 、て利用されて 、る。
[0004] 通常、 CAMは、その機能から、 2値 CAM (Binary CAM:以下「: BCAM」 t 、う。)及 び 3値 CAM (Ternary CAM :以下「TCAM」という。)の二種類に分類される。 BCA Mでは、各セルに 0及び 1を格納する。 TCAMでは各セルに 0, 1,及び *を格納す る。ここで、「*」はドント'ケア(don't care)を表し、 0と 1の両方にマッチする。
[0005] 〔定義 1〕 (BCAM)
n入力で登録データ数 pの BCAMテーブルは、 p個の異なる 2値ベクトルを格納す る。また、 p個のベクトルは、アドレス 1からアドレス pに順に格納されていると仮定する 。また、各ベクトルのアドレスは mビットで表現可能である。 mは次式(1)により表され る。
[0006] [数 1]
Figure imgf000003_0001
また、 p個のベクトルは、アドレス 1からアドレス pに順に格納されていると仮定する。 対応する BCAM関数 f:{0,l}n→{0,l}mは、以下の条件を満たす: x)は入力 xと同じベクトルが BCAMテーブル中にあるとき、ベクトル Xを格納する C AMのアドレス(1力も pの値の何れ力)を出力する。入力 Xと同じパターンが BCAMテ 一ブル中に無 、場合には、 x)の値は 0である。
(定義終り)
[0007] (例 1)
(表 1)は、 7個の 2値ベクトルを格納する BCAMを示す。対応する BCAM関数を( 表 2)に示す。何れも、入力データに完全に一致したベクトルを格納するアドレスを 3 ビットの数 (例えば、 '011 ' )として出力する。入力ベクトルと一致するものが BCAM 中に格納されていない場合には、 0を出力する。
(例終わり)
[0008] [表 1]
.お 1: BCAM関数の例
Figure imgf000004_0001
[0009] [表 2]
Figure imgf000005_0001
[0010] 〔定義 2〕 (TCAM)
η入力で要素数 ρの TCAMテーブルは、 ρ個の 3値ベクトルを格納する。また、 ρ個 のベクトルは、アドレス 1からアドレス ρに順に格納されていると仮定する。また、各べク トルのアドレスは mビットで表現可能である。ここで、 mは上記式(1)により表される。 各 3値ベクトルは、 0, 1,又は * (ドント'ケア)から構成される。対応する TC AM関数 : f:{0,l}n→{0,l}mは、以下の条件を満たす:
入力 Xに対して、 Xと一致するベクトルが TCAMテーブル中にある場合、出力 x)は 、一致したベクトル中の最小のアドレスを示す。また、 Xと一致するベクトルが TC AM テーブル中に無い場合には、 0を出力する。
(定義終り)
[0011] (例 2)
(表 3)に示す TCAMは、 7個の 3値ベクトルを格納する。対応する TCAM関数を( 表 4)に示す。入力 χ=(1,0,1,1)は、アドレス 5及び 6に蓄えられているパターンと一致す る。 5の方が小さいので、出力は (0,1,0,1)となる。 (例終わり)
[0012] [表 3]
表 3: TCAM関数の例
Figure imgf000006_0001
[0013] [表 4]
表 4: TC AMテーブルの例
•^2 h f、 h
0 0 0 0 0 0 0
0 (} 0 1 1 1 1
0 0 1 0 0 0 1
0 0 1 1 0 丄 0
ϋ 1 0 0 0 ϋ 0
0 1 0 1 0 0 0
0 1 1 0 0 0 0
0 1 1 1 0 0 0
1 0 0 0 0 1 0
1 0 0 1 1 1 1
1 0 1 0 0 0 1
1 0 1 1 1 0 1
1 1 0 0 1 0 0
1 丄 0 1 0 丄 1
1 1 1 0 0 0 0
1 丄 1 1 丄 丄 0
[0014] CAMの機能をソフトウェアで実現することも可能である力 ソフトウェアで実現したも のは大幅に低速である。そのため、専用のハードウェア(半導体メモリ)を用いて CA Mを実現することが多い。以下、ハードウェアで構成された従来の CAMについて説 明する。 [0015] 図 8は、従来の CAMの基本構成の一例を表すブロック図である(特許文献 1参照) 。 CAM100は、比較レジスタ 101、検索ビット線ドライバ 102、 n個のワード W〜W、 n個の一致センス回路 MSC〜MSC、 n個の一致フラグレジスタ MFR〜MFR、 及びプライオリティ ·ェンコーダ (優先度付符号化回路) PEを備えて 、る。
[0016] 比較レジスタ 101は、 mビットの検索データを格納するレジスタである。検索ビット線 ドライバ 102は、比較レジスタ 101の各ビットを検索ビット線上にドライブする。各ヮー ド W〜Wは、それぞれ mビットの CAMセルを備えている。
[0017] 図 9は、図 8の CAMセルの構成回路図である。図 9に例示した CAMセル 103は、 不一致検出型のものである。 CAMセル 103は、メモリ'セル 104及び一致比較回路 105から構成される。メモリ'セル 104は、 1ビットのデータを記憶する SRAM構成のメ モリ'セルである。図 9において Dがデータ、 DNが反転データを表す。一致比較回路 105は、メモリ'セル 104に記憶された 1ビットのデータと検索ビット線対 SL, SLN上 にドライブされる検索データとを比較し、その一致比較結果を一致線 ML上に出力す る。
[0018] 一致比較回路 105は、 3つの nMOSトランジスタ(以下「nMOS」 t 、う。) 106, 10 7, 108を備えている。 nMOS 106, 107は、検索ビット線 SLNと検索ビット線 SLとの 間に直列に接続されている。 nMOS106, 107のゲートは、それぞれ、メモリ'セル 10 4のデータ D,反転データ DNに接続されている。 nMOS108は、一致線 MLとグラン ドとの間に接続されている。 nMOS108のゲートは、 nMOS106, 107の間のノード 1 09に接続されている。
[0019] まず、検索を行う前に、 CAM100のそれぞれのワード W〜Wに、検索対象である データが記憶される。各ワード内の各 CAMセル 103において、メモリ'セル 104への データの書き込み及びメモリ.セル 104からのデータの読み出しは、通常の SRAMと 同様にして行われる。
[0020] 検索時には、まず、比較レジスタ 101に検索データが格納される。検索データの各 のビットは、検索ビット線ドライバ 102により、各々対応する検索ビット線上にドライブさ れる。
[0021] 各々のワード W〜Wでは、各 CAMセルに予め記憶されているデータと検索ビット 線上にドライブされた検索データとの一致検索が同時 (並列)に実行され、その結果 がー致線 ML〜ML上に出力される。これらの検索結果は、それぞれ一致センス回 路 MSC〜MSCに入力される。各一致センス回路 MSC〜MSCは、各検索結果 を増幅し、一致センス出力として一致センス出力線 MT〜MTに出力する。各一致 センス出力は、一致フラグレジスタ MFR〜MFRに格納され、一致フラグ出力として 一致フラグ出力出力線 MF〜MFに出力される。一致フラグは、 ' 1 'が「一致あり」、 '0,が「一致なし」を表すものとする。
[0022] 各一致フラグ出力は、プライオリティ 'エンコーダ PEに入力される。プライオリティ' エンコーダ PEでは、所定の優先順位付けに従って、一致が検出されたワードの中か ら最優先順位のワードのアドレス (最優先一致アドレス: HMA)を選択し出力する。各 ワードの優先順位は、ワード Wが最も高ぐ Wに向力うに従って順次優先順位が低 くなるちのとする。
[0023] 尚、各ワード W〜W内の各 CAMセル 103における一致検索は、次のようにして 実行される。
[0024] まず、初期化動作を実行する。初期化動作では、検索ビット線対 SL, SLNがともに
'L' (= '〇')とされる。一方、メモリ'セル 104に記憶されているデータに応じて、一致 比較回路 105の nMOS106, 107のうち一方がオン状態、他方がオフ状態となる。 従って、 nMOS106, 107のうちオン状態の方を介して、両者の間のノード 109のレ ベルが' L,となり、 nMOS108はオフ状態となる。この状態で、一致線 ML力 'H, (= ' 1 ' )状態にプリチャージされる。尚、一致線 MLは 'H'が「一致」を表す。
[0025] 次に、検索ビット線を介して比較レジスタ 101に記憶された検索データの各ビットが 各 CAMセル 103に入力される。これにより、検索データ Sに応じて、検索ビット線対 S L, SLNの何れか一方が 'H'、他方が 'L'となる。
[0026] メモリ'セル 104に記憶されているデータ Dと検索データ Sとが一致する場合、ノード 109のレベルは' L,であり、 nMOS108はオフ状態に保持される。
[0027] 一方、データ Dと検索データ Sとが一致しない場合、ノード 109のレベルは 'Η'とな り、 nMOS108はオン状態になる。これにより、一致線 MLはデイスチャージされて' L '状態となる。 [0028] mビットの CAMセル 103からなる CAMワードの一致線 MLは、各 CAMセル 103 の nMOS 108がパラレルに接続されたワイヤード OR回路を構成している。従って、 1 ワードを構成する mビットの CAMセル 103のすべてにおいて一致が検出された場合 に限り、一致線 MLは 'Η' (「一致」)の状態に保持される。一方、 1ビットでも CAMセ ル 103で不一致が検出されると、一致線 MLは' L' (「不一致」)の状態となる。
[0029] 例えば、検索の結果、一致フラグレジスタ MFR〜MFRに、一致フラグとして' 0, , Ί ' , ' 1 ' , '0,, · ··, ' 1 ' , '0,が格納されたとする。この場合、ワード W , W , · ··,
2 3
W で一致が検出されている。従って、プライオリティ 'エンコーダ PEは、最も優先 順位が高いワード Wのアドレスを HMAとして出力する。また、一致フラグレジスタ M
2
FRに格納された一致フラグを' 0'にクリアすることで、その次に優先順位が高いヮー
2
Wのアドレスを HMAとして出力することができる。以下同様にして、一致が検出さ
3
れたワードのアドレスを順次出力することができる。
[0030] 尚、 TC AMとして使用する場合、ドント'ケアのビットについては、検索ビット線対 S L, SLNをともに 'L,(= '〇')としておけばよい。
[0031] 図 10は、図 8の CAMセルの別の例の構成回路図である。図 10に示す CAMセル 103,は一致検出型のものであり、図 9と同様、 SRAM構成のメモリ'セル 104及び一 致比較回路 105を備えている。 CAMセル 103,は、図 9の CAMセル 103において、 一致比較回路 105の nMOS108の接続が異なる。図 Dの nMOS108は、一致線 M Lと一致線 MLとの間に接続されている。 nMOS108のゲートは、 nMOS106, 10 a b
7の間のノード 109に接続されている。
[0032] CAMセル 103'では、検索時には、初期化動作として、ビット線対 SL, SLNが共 に 'H'とされる。一方、メモリ'セル 104に記憶されているデータに応じて、一致比較 回路 105の nMOS106, 107のうち一方がオン状態、他方がオフ状態となる。従って 、 nMOS106, 107のうちオン状態の方を介して、両者の間のノード 109のレベルが 'Η'となり、 nMOS108はオン状態となる。この状態で、一致線 MLの一端力 'H, (= ' 1 ' )状態にプリチャージされる。尚、一致線 MLは 'H'が「不一致」を表す。
[0033] mビットの CAMセル 103,からなる CAMワードの一致線 MLは、各 CAMセル 103 ,の nMOS 108がシリアルに接続された AND回路を構成する。従って、各々の CA Mセルの一致線 ML , MLは、各々の CAMセル 103,の nMOS108を介して 'Η'
a b
にプリチャージされる。
[0034] その後、検索ビット線を介して比較レジスタ 101に記憶された検索データの各ビット が各 CAMセル 103 'に入力される。これにより、検索データ Sに応じて、検索ビット線 対 SL, SLNの何れか一方が 'H'、他方が 'L'となる。
[0035] メモリ'セル 104に記憶されているデータ Dと検索データ Sとが一致する場合、ノード
109のレベルは 'H,であり、 nMOS108はオン状態に保持される。
[0036] 一方、データ Dと検索データ Sとが一致しない場合、ノード 109のレベルは 'L,とな り、 nMOS108はオフ状態になる。
[0037] CAMワードの mビットの CAMセル 103,のすベての状態が確定した後、一致線 M
Lの一方の端部からデイスチャージを開始し、他方の端部で一致比較結果を判定す る。このとき、 1ビットでも不一致の CAMセル 103 'がある場合には、一致比較結果は
'H,、すなわち、不一致の状態に保持される。一方、すべての CAMセル 103,で一 致が検出された場合のみ、一致比較結果は' L'、すなわち一致状態となる。
[0038] 尚、 TC AMとして使用する場合、ドント'ケアのビットについては、検索ビット線対 S
L, SLNをともに 'H' ( = ' 1 ' )としておけばよい。
特許文献 1:特開 2004— 295967号公報
特許文献 2:特願 2003 - 389264号明細書
特許文献 3:特開 2004— 258799号公報
特許文献 4:特開 2004-258799号公報
非特許文献 1 :菅野卓雄監修,香山晋編, 「超高速デバイス,シリーズ 2 超高速 MO Sデバイス」,初版,倍風館, 1986年 2月, pp. 324- 325.
非特許文献 2 :電子情報通信学会編, 「LSIハンドブック」,第 1版,オーム社, 1994 年 11月, pp. 523 - 525.
非特干文献 3: Kostas Pagiamtzis ana Ali Sheikholeslami, A Low-Power Content- A ddressable Memory (CAM) Using Pipelined Hierarchical Search Scheme", IEEE Jour nal of Solid-State Circuits, Vol.39, No.9, Sept.2004, pp.1512- 1519.
特許文献 4 : T.Sasao, M.Matsuura, and Y.Iguchi, "A cascade realization of multi-o utput lunction for reconfigurable hardware", International Workshop on Logic and S ynthesis (IWLS01), Lake Tahoe, CA, June 12—15, 2001, pp.225— 230.
特許文献 5 : T.Sasao and M.Matsuura, "BDD representation for incompletely sped fied multiple-output logic functions and its applications to lunctional decomposition,
Design Autonmation Conference, June 2005, (pp.373- 378).
非特許文献 6 :井口、笹尾、 "LUTカスケード 'アーキテクチャについて、 "平成 15年 電気学会電子 '情報'システム部門大会、 MC2-4, 2003年 8月 29日〜 30日、秋田大 学。
発明の開示
発明が解決しょうとする課題
[0039] 上記従来の CAMは、 RAMに比べると、並列に検索可能であるため高速であるが
、デバイスの構成は複雑となる。そのため、 CAMの 1ビットあたりの価格(ビットコスト) は、 RAMに比べると 10〜30倍程度、高価なものになる。
[0040] また、 1ビットあたりの消費電力が RAMに比べて遙かに大きい(非特許文献 3参照)
。これは、上で説明したように、すべての CAMセルを同時にアクセスするためである
。そのため、 1ビットあたりの消費電力は、通常の RAMの約 50倍程度にもなる。
[0041] そこで、本発明の目的は、検索の高速性を維持しつつも、消費電力を抑え且つデ バイスの構造を簡単ィ匕して小さい実装面積で実装可能な連想メモリを提供することに ある。
課題を解決するための手段
[0042] 以下、本明細書において使用する用語の定義及び本発明の前提となる理論を説 明し、その後本発明の構成及び作用について説明する。
[0043] 〔 1〕 CAM関数の性質
〔定義 3〕(分解表、基本分解表、列複雑度)
関数 X): Bn→Bq、及び Χ=(χ ,χ ,· · ·,χ )が与えられているものとする。ここで、 Β={0,1}
1 2 η
である。(X , X )を Xの分割とする。 fの「分解表」とは、二次元のマトリックスであって、
L H
列のラベルは、 Xに Bの構成要素をすベての可能な組み合わせに対して割り当てた し
ものであり、また行のラベルは、 Xに Bの構成要素をすベての可能な組み合わせに 対して割り当てたものである。また、対応するマトリックスの値は χ ,χ )の値に等しい
L Η 関数 fの分解表のうちで、 X =(χ , X , ···, X
L 1 2 nL )且つ X =(χ , X , ···, X
H nL+1 nL+2 n )となる分解 表を「基本分解表」という。
分解表の異なる列パターンの個数を分解表の「列複雑度」 、う。
尚、分解表の特別な場合として、 X =X
し の場合も考える。
(定義終り)
[0044] 〔定義 4〕(C尺度)
変数の順序を (X ,χ ,···,χ
1 2 n )としたとき、論理関数 fの基本分解表の列複雑度の最大値 を、 fの「C尺度」という。
(定義終り)
[0045] (例 3)
f=xx Vxx Vxxの C尺度は 3である力 f=xx Vxx Vxxの C尺度は 8である。
1 1 2 3 4 5 6 2 1 5 2 6 3 4
(例終わり)
[0046] 分解表の列複雑度は、 MTBDD (多端子二分決定グラフ)の幅に等 、。従って、 論理関数の C尺度は、与えられた入力変数の順における MTBDDの幅の最大値に 等しい。与えられた論理関数 χ ,χ ,···,χ)に対して、 C尺度は容易に計算でき、一意
1 2 n
的に定まる。後述するように、 C尺度が小さい関数は、 LUTカスケード (LUT (Lookup -table) cascade)で効率的に実現可能である。従って、 C尺度は、論理関数を LUT力 スケードで実現する際の複雑さの尺度となる。
[0047] 〔補題 1〕
与えられた関数 fに対して、非零出力を生ずる入力の組み合わせの個数を pとする。 このとき、 fの C尺度は高々 p+1である。
(補題終り)
[0048] 〔定理 1〕(BCAM関数の C尺度)
要素数 Pの BCAMテーブルが与えられたとき、その BCAM関数の C尺度は高々 p+ 1である。
(定理終り) [0049] 〔定理 2〕(TCAM関数の C尺度)
TC AMテーブル力 ¾個のベクトルを格納し、各ベクトルが高々 k個のドント'ケアを有 するとき、対応する TCAM関数の C尺度は高々 2kp+lである。
(定理終り)
[0050] 〔2〕LUTカスケード
CAM関数は通常の RAMでも実現可能である。例えば、上記(表 1)に示した要素 7の BCAM関数は、(表 2)に示したように、 16ワードの RAMにより実現することがで きる。ここで、各ワードは 3ビットである。 n入力の CAM関数を単一の RAMで実現す る場合、 RAMの大きさは、 BCAMがわずか数個のベクトルしか含まない場合であつ ても、 2nに比例して大きくなる。そこで、 LUTカスケードを用いることにより、必要なメ モリ量を大幅に削減することが可能となる(特許文献 3参照)。
[0051] 〔定理 3〕
与えられた関数 fに対して、 X
Lを分解表の列に対応する変数、 X
Hを行に対応する変 数とし、 を分解表の列複雑度とする。このとき、関数 fは図 1に示すような回路で実 現することが可能である。この場合、二つのブロック Hと Gの間を結ぶ信号線数 (以下 「レイル数」という。)は
[0052] [数 2]
Figure imgf000013_0001
である。
(定理終り)
[0053] 二つのブロック間を結ぶ信号線数が X中の変数の個数よりも少ないとき、関数を実 し
現するためのメモリ量を削減できる可能性がある。この手法を「関数分解」という。与え られた関数を繰り返し関数分解することにより、図 2に示すような LUTカスケードが得 られる(非特許文献 4参照)。 LUTカスケードは「セル」から構成され、隣接するセル 間を接続する信号線を「レイル」という。 C尺度が小さな関数は小型の LUTカスケード で実現可能である。 C尺度を求めるには、必ずしも分解表を使用する必要はなぐ多 出力関数の特性関数を表現する二分決定グラフ(Binary Decision Diagram for Chara cteristic Function:以下「BDD_for_CF」という。)から効率的に計算することができる( 特許文献 2,非特許文献 5参照)。
[0054] 〔定理 4〕
C尺度が; zの論理関数は、入力数が高々
[0055] [数 3]
「 g2 ] + l (3) 出力数が
[0056] 画
「log2 μ \ (4) のセル力も構成された LUTカスケードで実現可能である。
(定理終り)
[0057] 〔定理 5〕
関数 実現する LUTカスケードを考える。いま、 nを外部入力変数、 sをセル数、 rを 最大レイル数 (即ち、セル間の信号線数)、 kをセルの最大入力数、 μを関数 fの C尺 度とする。
[0058] [数 5] k > r, τ =「 g2 μ,Ι C-r)) が成立するとき、以下の関係を満たす 実現する LUTカスケードが存在する
[0059] [数 6]
Figure imgf000014_0001
(定理終り)
[0060] 〔3〕ドント'ケアを用いた設計法
〔3— 1〕BCAM関数の設計法
BCAM関数では、真理値表において、非零出力の値力 全体の組み合わせの数 2 nに比べて大幅に少ない。つまり、次の(仮定 1)が成立するものとする。
[0061] (仮定 1) BCAMテーブルの入力ビット数を n、ベクトル数を pとするとき、 p《2n
[0062] 例えば、 n=32で p=1000の BCAMを考えるとき、非零出力の割合は全最小項の個 数の 1000/232=2.3 X 10— 7となる。
[0063] BCAM関数を BDDで表現すると、 BDDの最大幅力 C尺度を超えな!/、こと、及び 〔定理 1〕から、レイル幅は p+1を超えないことがわかる。し力し、全体の幅は p+1近くな る。従って、 BCAM関数を LUTカスケードで実現する場合、入力数が
[0064] [数 7]
0¾(p + l)] + l (7) のセルが多数必要となる。そこで、ここではドント'ケアの概念を用いて、 BCAM関数 を実現するハードウェア量を削減する方法について、図 3を参照しながら説明する。
[0065] 〔ァノレゴリズム 1〕
(l)f^BCAM関数とする。また、 fにおいて CAMに登録されていないデータに対 する出力値をドント ·ケアとした関数を gとする。
[0066] (2) gの特性関数を表現する二分決定グラフ(BDD_for_CF)を生成し、簡単ィ匕を行う
[0067] (3)簡単化した BDDから、 LUTカスケード 1を生成する。一般に、 LUTカスケード 1 は、 ¾実現する LUTカスケード (これを「厳密な LUTカスケード」と呼ぶ。)よりも簡単 になる。
[0068] (4)検索データが登録データと一致するときは、 LUTカスケード 1は正し 、値を出 力する。検索データが登録データと一致しないときは、 LUTカスケード 1は、誤った 値を出力する可能性がある。
[0069] (5)誤りを補正するために、 m入力 n出力の補助メモリ 2を用いる。ここで、 mは次式 で表される。
[0070] [数 8]
m = log2(p + l)l (8) この補助メモリ 2には、各アドレスに BCAMテーブルの対応するデータが格納されて いる。
[0071] (6) LUTカスケード 1の出力のインデックスを補助メモリ 2に供給し、補助メモリ 2内 の登録データを読み出す。そして、一致回路 3により、入力データと補助メモリ 2の出 力データとを比較する。両者が一致すれば、 LUTカスケード 1の出力値は正しいこと が保証される。従ってエンコーダ 4は LUTカスケード 1の出力のインデックスをそのま ま出力する。一方、補助メモリ 2の出力データと入力データとがー致しないときは、 C AM内にそのデータは登録されていない。従って、そのときには、エンコーダ 4は無効 のインデックス (0)を出力する。
(アルゴリズム終り)
[0072] 補助メモリ 2の全ビット数は、 n2mであり、ハードウェアのコストは、 LUTカスケード 1の コストに比べ無視できる程度である。
[0073] 〔3— 2〕TCAM関数の設計法
TCAM関数の場合、 TC AMテーブルは 3値となるので、補助メモリ 2は、 m入力 2n 出力となる。また、一致回路 3で、ドント'ケアに対応するビットは無視する。他の部分 は BCAMと同じである。
[0074] 〔4〕本発明の構成
本発明に係る連想メモリの構成は、入力データに対しそのデータに対応する固有 のインデックスを出力する連想記憶メモリであって、
入力データに対しそのデータに対応する固有のインデックスを出力する関数 (以下 「CAM (Content Addressable Memory)関数」という。)fの無効出力値をドント'ケアで 置き換えた関数(以下「簡略化 CAM関数(reduced Content Addressable Memory lu nction)」という。)gを表す LUT結合論理回路又は PLA (Programmable Logic Array) により構成された簡略ィ匕関数演算部と、
前記 CAM関数 fの逆関数 f_1が記憶された補助メモリと、
前記 LUT演算手段の出力値が CAM関数 fの出力に一致するカゝ否かを判定する一 致判定手段と、
を備え、
前記 LUT演算手段は、前記入力データに対して前記簡略化 CAM関数 gの演算値 (以下「仮インデックス値」という。 )を前記補助メモリの読み出しアドレスとして出力し、 前記補助メモリは、前記仮インデックス値が読み出しアドレスとして入力されると、そ の仮インデックス値に対しする逆関数 f_ 1の値を出力し、 前記判定手段は、前記入力データと前記補助メモリが出力する逆関数 f_1の値とを 比較して、両者が一致する場合は前記 LUT演算手段の出力値を出力し、それ以外 の場合は無効信号を出力することを特徴とする。
[0075] この構成によれば、 LUT結合論理回路は、通常の RAMを複数個用いて構成する ことができる。また、補助メモリも通常の RAMで構成できる。また、 CAM関数 fそのも のを表す LUT結合論理回路ではなぐ CAM関数 fの無効出力値をドント'ケアで置き 換えた簡略ィ匕関数 gを表す LUT結合論理回路又は PLAを用いることによって、当該 LUT結合論理回路又は PLAを構成するために必要なメモリ量を大幅に削減するこ とができる。従って、全体として、従来の CAMに比べ、デバイスの構造を簡単ィ匕して 小さい実装面積により実装が可能となる。
[0076] また、通常の RAMで構成することによって、専用の CAM回路を必要としない。故 に、 ASICで構成する以外に、汎用の RAMを内蔵した FPG A (Field Programmable Gate Array)や CLD (Complex Programmable Logic Device)のようなプログラマブノレ' デバイスを用いて簡単に低コストで構成することもできる。
[0077] また、判定手段以外はすべて通常の RAMで構成できる。そして、 1回の検索動作 に対して、数回(LUT結合論理回路での RAMのアクセス回数 + 1)の RAMのァクセ スで仮インデックス値が得られる。各 RAMのアクセスでは、 RAM内の 1つのアドレス のみがアクセスされる。全体として、数回の RAMのメモリ'アクセスのみで仮インデッ タス値が得られる。従って、従来の CAMに比べると、消費電力を大幅に低減すること が可能となる。
[0078] 一方、高速性の面では、従来の CAMに比べると遅くなるものの、通常の RAMを C PUを用いて検索する方法に比べると遙かに高速に検索を行うことができる。
[0079] ここで、「LUT結合論理回路」とは、複数の LUT (Look- Up Table)をカスケード状 又はネットワーク状に結合した回路をいうが、必ずしもハードウエア的に複数の LUT を配置'結合する必要はない。例えば、 1つのメモリ内に複数の LUTを記憶させ、 LU Tの選択を順次切り替えながら、メモリの出力値をメモリの読み出しアドレスにフィード ノックすることによって LUT結合を実現するような回路であってもよ 、。 LUT結合論 理回路としては、 LUTカスケード論理回路の他に、 LUTをネットワーク状に結合した LUTネットワークなどを使用することも可能である。
[0080] 尚、本発明は BCAM及び TCAMの双方に適用することが可能である。
発明の効果
[0081] 以上のように、本発明によれば、検索の高速性を維持しつつ、消費電力を抑え且 つデバイスの構造を簡単ィ匕して小さい実装面積で実装可能な連想メモリを提供する ことができる。
図面の簡単な説明
[0082] [図 1]論理関数の関数分解を表す図である。
[図 2]中間出力を有する LUTカスケードを表す図である。
[図 3]ドント'ケアを用いた CAM関数の実現法を説明する図である。
[図 4]本発明の実施例 1に係る連想メモリの全体構成を表す図である。
[図 5]図 4の簡略ィ匕関数演算部 5の構成を表す図である。
[図 6]図 4の一致判定手段 7の構成を表す図である。
[図 7]実施例 2に係る連想メモリの一致判定手段 7の構成を表す図である。
[図 8]従来の CAMの基本構成の一例を表すブロック図である。
[図 9]図 8の CAMセルの構成回路図である。
[図 10]図 8の CAMセルの別の例の構成回路図である。
符号の説明
[0083] 1 LUTカスケード
2 補助メモリ
3 一致回路
4 エンコーダ
5 簡略化関数演算部
6 補助メモリ
7 一致判定手段
10 連想メモリ
11 入力変数レジスタ
12— 1〜12— s 論理関数メモリ 13 出力変数レジスタ
21 EXNORゲート
22 ANDゲート
23 ANDゲート
31 pq素子
発明を実施するための最良の形態
[0084] 以下、本発明を実施するための最良の形態について、図面を参照しながら説明す る。
実施例 1
[0085] 図 4は、本発明の実施例 1に係る連想メモリの全体構成を表す図である。本実施例 の連想メモリ 10は、簡略化関数演算部 5、補助メモリ 6、及び一致判定手段 7を備え ている。
[0086] 連想メモリ 10は、外部回路力も入力される nビットの入力データ Χ=(χ , · · · ,χ )に対し
1 η その入力データ Xに対応する mビットの固有のインデックス A=(a , - - - ,a )を出力する。
1 m
入力データ Xは、簡略化関数演算部 5及び一致判定手段 7に入力される。
[0087] 以下では、入力データ Xに対しその入力データ Xに対応する固有のインデックス Aを 出力する CAM関数を、 Fと記す。また、 CAM関数 Fの出力のうち、無効なインデック ス値をドント ·ケアで置き換えた簡略ィ匕 CAM関数を、 Gと記す。
[0088] 簡略化関数演算部 5は、簡略化 CAM関数 Gを演算する LUT結合論理回路により 構成されている。簡略化関数演算部 5は、入力データ Xに対し仮インデックス A'=G(X) を演算する。この仮インデックス A'は、補助メモリ 6及び一致判定手段 7に出力される
[0089] 補助メモリ 6は、 CAM関数 Fの逆関数 F— すなわち、固有のインデックス Aに対しそ のインデックス Aに対応するデータ Xを出力するデータ出力関数が、 LUTとして記憶 されている。補助メモリ 6には、簡略ィ匕関数演算部 5が出力する仮インデックス A'が入 力され、それに対する逆算データ X'=F— ')が出力される。仮インデックス A'は、一致 判定手段 7に出力される。
[0090] 一致判定手段 7は、入力データ Xと逆算データ X'とを比較し、両者が一致するか否 かを判定する。そして、両者が一致する場合には仮インデックス A'を出力インデックス
Aとして出力し、一致しない場合には無効値を出力する。
[0091] 図 5は、図 4の簡略ィ匕関数演算部 5の構成を表す図である。本実施例 1においては
、簡略ィ匕関数演算部 5として、 LUTカスケード論理回路を用いる。
[0092] 簡略化関数演算部 5は、入力変数レジスタ 11、論理関数メモリ 12— 1〜12— s、及 び出力変数レジスタ 13を備えている。
[0093] 入力変数レジスタ 11は、外部から入力される入力データ Xを一時的に保持するレジ スタである。論理関数メモリ 12— 1〜12— sは、簡略ィ匕 CAM関数 Gを関数分解して 得られる CAM関数 Gの部分関数 G ,---,G力LUTとして格納されている。ここで、 Xの
1 s
分割を Χ=(Χ ,Χ ,···,Χ)とした場合、各部分関数 G ,-,Gは次のようになる。
1 2 s I s
[0094] [数 9]
(A ,RL) = G^
( '2!¾) G2( 2 ¾)
, ; (9)
(As-l! ¾-l ) = «^ΐ-Ι ( — 1' 2)
Α' {Α'Ϊ:Α'2,... ,A'S)
[0095] ここでは、ベクトル A ',Α ',···,Α 'は、 LUTカスケードの中間出力であり、ベクトル A
1 2 s-1 s
'は LUTカスケードの最終出力である。仮インデックス A'は、これらのベクトルの合成 として表される。また、ベクトル R ,R,---,R は、 LUTカスケードの中間変数を表す。
1 2 s-1
[0096] 出力変数レジスタ 13は、各論理関数メモリ 12— l〜12— sが出力する中間出力 A '
1
,Α ',···,Α '及び最終出力 Α 'を保持し、仮インデックス A'として出力するレジスタであ
2 s-1 s
る。
[0097] 尚、 LUTカスケード論理回路の詳 、動作にっ 、ては、特許文献 4及び非特許文 献 6に記載されているため、ここでは説明を省略する。
[0098] 図 6は、図 4の一致判定手段 7の構成を表す図である。図 6では、一例として、入力 データ Xが 8ビット、出力インデックス Aが 8ビットの場合を示している力 入力データ X 及び出力インデックス Aのビット数はこれに限られるものではない。
[0099] 一致判定手段 7は、入力データ Xの各ビットに対応して設けられた EXNORゲート 2 1、 1個の ANDゲート 22、及び出力インデックス Aの各ビットに対応して設けられた A
NDゲート 23により構成される。
[0100] 入力データ X及び逆算データ X'の各ビット X , χ ' (ί=1,2,· ··,8)は、それぞれ対応する
EXNORゲート 21に入力され、 EXNOR演算が行われる。各 EXNORゲート 21の演 算結果は、 ANDゲート 22に入力され、 AND演算が行われる。この ANDゲート 22の 出力 Qを、一致判定信号と呼ぶ。
[0101] 一方、仮インデックス A'の各ビット a ',a ',· ··,& 'は、それぞれ各 ANDゲート 23の一
1 2 8
方の入力ノードに入力される。また、各 ANDゲート 23の他方の入力ゲートには、一 致判定信号 Qが入力される。
[0102] 以上のように構成された本実施例に係る連想メモリ 10について、以下その動作を 説明する。
[0103] まず、外部回路力 入力データ Xが入力されると、簡略化関数演算部 5は、 CAM 関数 G(X)の演算を行い、その結果を仮インデックス A'として出力する。ここで、入力 データ Xに対する真のインデックスが存在する場合、仮インデックス A'の値は真のイン デッタスの値に一致する。一方、真のインデックスが存在しない場合には、仮インデッ タス A'の値はドント'ケアとなる。従って、仮インデックス A'は真のインデックスを含むも のの、その値が真のインデックスを表すのかドント'ケアを表すのかの判別はできない
[0104] 次に、仮インデックス A'は補助メモリ 6に入力される。補助メモリ 6は、仮インデックス A'に対してデータ出力関数 F— ')の LUT演算を行い、その結果を逆算データ X'= F 1 (Α')として出力する。このとき、仮インデックス A'は真のインデックスを表す場合には 、逆算データ X'は入力データ Xと同じ値となる。しかし、仮インデックス A'がドント'ケア の場合には、仮インデックス A'はデタラメな値なので、逆算データ X'には無効値が出 力される。
[0105] 次に、一致判定手段 7の i番目の EXNORゲート 21 (ί=1,2,· ··,8)には、それぞれ入 力データ Xの i番目の成分 Xと逆算データ X'の i番目の成分 X 'とが入力される。 EXNO Rゲート 21は、論理演算
[0106] [数 10] φ = Φ (10) を行い、演算値 q;を出力する。演算値 q;の値は、成分 X;と成分 Xとが一致する場合は 1 、一致しない場合は 0となる。
[0107] 各演算値 q.は、 ANDゲート 22に入力され、 AND演算が行われる。これにより、入 力データ Xと逆算データ X'の各成分が完全に一致する場合には一致判定信号 Qは 1 となり、それ以外の場合には一致判定信号 Qは 0となる。従って、この一致判定信号 Qを用いることによって、仮インデックス A'が真のインデックス値を表しているか否かの 判別ができる。
[0108] i番目の ANDゲート 23 (ί=1,2,· ··,8)には、それぞれ仮インデックス A'の i番目の成分 Xと一致判定信号 Qが入力される。そして、各 ANDゲート 23はこれらの AND演算を 行い、その結果を出力インデックス Aの i番目の成分 aとして出力する。これにより、仮 インデックス A'が真のインデックス値を表して 、る場合には、出力インデックス Aとして 真のインデックス値が出力され、それ以外の場合は出力インデックス Aとして 0が出力 される。
[0109] 以上のようにして、入力データ Xに対する CAM関数の演算が行われる。上述のよう に、本実施の形態では、簡略ィ匕関数演算部 5及び補助メモリ 6はすべてメモリで構成 されているため、通常の RAMを用いて構成することが可能である。従って、プロセスの 微細化が容易であり回路規模を小さくすることができる。また、メモリであるため、使用 しない期間を省電力状態として消費電力の節減を図ることも可能である。
実施例 2
[0110] 本実施例 2に係る連想メモリの全体構成及び一致判定手段 7の構成は、図 4,図 6 と同様であり、説明は省略する。実施例 2に係る連想メモリは、簡略化関数演算部 5 の構成が実施例 1とは異なる。
[0111] 図 7は、実施例 2に係る連想メモリの簡略ィ匕関数演算部 5の構成を表す図である。
本実施例の簡略ィ匕関数演算部 5は、複数の pq素子 31を榭形状に結合した構成から なる。 pq素子 31は、 p入力 q出力のメモリである。各 pq素子 31の p, qの値はそれぞれ の pq素子 31ごとに任意に設定される。各 pq素子 31には、簡略ィ匕 CAM関数 Gを関 数分解して得られる部分関数 G ,G,…が LUTとして格納されている。このように複数
1 2
の pq素子 31を榭形状に結合した回路をここでは「pq回路網」と呼ぶ。
[0112] 尚、図 7の構成は一例であり、 pq素子 31の結合の仕方は、 CAM関数 Gにより適宜 選択される。
[0113] このように、簡略ィ匕関数演算部 5として pq回路網を使用しても、実施例 1と同様の連 想メモリを構成することができる。

Claims

請求の範囲
[1] 入力データに対しそのデータに対応する固有のインデックスを出力する連想記憶メ モリであって、
入力データに対しそのデータに対応する固有のインデックスを出力する関数 (以下
「CAM (Content Addressable Memory)関数」という。)fの無効出力値をドント'ケアで 置き換えた関数 (以下「簡略化 CAM関数」と ヽぅ。 ) gを表す LUT結合論理回路又は PLAにより構成された簡略ィ匕関数演算部と、
前記 CAM関数 fの逆関数 f_1が記憶された補助メモリと、
前記 LUT演算手段の出力値が CAM関数 fの出力に一致するカゝ否かを判定する一 致判定手段と、
を備え、
前記 LUT演算手段は、前記入力データに対して前記簡略化 CAM関数 gの演算値 (以下「仮インデックス値」という。 )を前記補助メモリの読み出しアドレスとして出力し、 前記補助メモリは、前記仮インデックス値が読み出しアドレスとして入力されると、そ の仮インデックス値に対しする逆関数 f_ 1の値を出力し、
前記判定手段は、前記入力データと前記補助メモリが出力する逆関数 f_1の値とを 比較して、両者が一致する場合は前記 LUT演算手段の出力値を出力し、それ以外 の場合は無効信号を出力すること
を特徴とする連想メモリ。
[2] 前記 LUT結合論理回路は、 LUTカスケード論理回路であることを特徴とする請求 項 1記載の連想メモリ。
[3] 前記 LUT結合論理回路は、 pq回路網であることを特徴とする請求項 1記載の連想 メモリ。
PCT/JP2007/056498 2006-03-31 2007-03-27 連想メモリ WO2007119540A1 (ja)

Priority Applications (2)

Application Number Priority Date Filing Date Title
US12/294,786 US8352677B2 (en) 2006-03-31 2007-03-27 Associative memory
JP2008510867A JP4934825B2 (ja) 2006-03-31 2007-03-27 連想メモリ

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2006-101106 2006-03-31
JP2006101106 2006-03-31

Publications (1)

Publication Number Publication Date
WO2007119540A1 true WO2007119540A1 (ja) 2007-10-25

Family

ID=38609318

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2007/056498 WO2007119540A1 (ja) 2006-03-31 2007-03-27 連想メモリ

Country Status (3)

Country Link
US (1) US8352677B2 (ja)
JP (1) JP4934825B2 (ja)
WO (1) WO2007119540A1 (ja)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPWO2016027829A1 (ja) * 2014-08-21 2017-04-27 学校法人明治大学 連想記憶装置、インデックス生成器、及び登録情報更新方法
CN113378009A (zh) * 2021-06-03 2021-09-10 上海科技大学 基于二元决策图的二值神经网络定量分析方法

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9430735B1 (en) 2012-02-23 2016-08-30 Micron Technology, Inc. Neural network in a memory device
KR101780610B1 (ko) * 2014-06-20 2017-09-21 에스지 준정 디지털 비디오 코., 엘티디 조색모니터, 조색시스템 및 조색방법
JP6666686B2 (ja) 2015-08-18 2020-03-18 株式会社ポコアポコネットワークス メモリ機器
US11232038B2 (en) 2019-06-05 2022-01-25 Samsung Electronics Co., Ltd. Ternary content addressable memory and operating method thereof

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000105770A (ja) * 1998-09-28 2000-04-11 Matsushita Electric Ind Co Ltd ハッシュテーブル検索方法および装置
JP2002334114A (ja) * 2001-05-10 2002-11-22 Allied Tereshisu Kk テーブル管理方法及び装置
JP2004229163A (ja) * 2003-01-27 2004-08-12 Internatl Business Mach Corp <Ibm> 固定長データ検索装置、及び固定長データ検索方法、及びコンピュータプログラム、並びにコンピュータ読み取り可能な記録媒体

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004258799A (ja) 2003-02-24 2004-09-16 Kitakyushu Foundation For The Advancement Of Industry Science & Technology ルックアップテーブル・カスケード論理回路
JP2004295967A (ja) 2003-03-26 2004-10-21 Kawasaki Microelectronics Kk 連想メモリ
US7243290B2 (en) * 2003-07-11 2007-07-10 Micron Technology, Inc. Data encoding for fast CAM and TCAM access times
KR100651743B1 (ko) * 2005-10-26 2006-12-01 한국전자통신연구원 Tcam 엔트리 생성 및 검색 방법과 그 장치

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000105770A (ja) * 1998-09-28 2000-04-11 Matsushita Electric Ind Co Ltd ハッシュテーブル検索方法および装置
JP2002334114A (ja) * 2001-05-10 2002-11-22 Allied Tereshisu Kk テーブル管理方法及び装置
JP2004229163A (ja) * 2003-01-27 2004-08-12 Internatl Business Mach Corp <Ibm> 固定長データ検索装置、及び固定長データ検索方法、及びコンピュータプログラム、並びにコンピュータ読み取り可能な記録媒体

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
SASAO T.: "Design Methods for Multiple-Valued Input Address Generators", 36TH INTERNATIONAL SYMPOSIUM ON MULTIPLE-VALUED LOGIC (ISMVL'06), May 2006 (2006-05-01), pages 1, XP010917777 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPWO2016027829A1 (ja) * 2014-08-21 2017-04-27 学校法人明治大学 連想記憶装置、インデックス生成器、及び登録情報更新方法
US9865350B2 (en) 2014-08-21 2018-01-09 Meiji University Content addressable memory, an index generator, and a registered information update method
CN113378009A (zh) * 2021-06-03 2021-09-10 上海科技大学 基于二元决策图的二值神经网络定量分析方法
CN113378009B (zh) * 2021-06-03 2023-12-01 上海科技大学 基于二元决策图的二值神经网络定量分析方法

Also Published As

Publication number Publication date
US8352677B2 (en) 2013-01-08
US20100228911A1 (en) 2010-09-09
JP4934825B2 (ja) 2012-05-23
JPWO2007119540A1 (ja) 2009-08-27

Similar Documents

Publication Publication Date Title
Kaplan et al. A resistive CAM processing-in-storage architecture for DNA sequence alignment
Maurya et al. A dynamic longest prefix matching content addressable memory for IP routing
US9159421B2 (en) Longest prefix match internet protocol content addressable memories and related methods
Jarollahi et al. Algorithm and architecture for a low-power content-addressable memory based on sparse clustered networks
WO2007119540A1 (ja) 連想メモリ
Ullah et al. DURE: An energy-and resource-efficient TCAM architecture for FPGAs with dynamic updates
JP4892693B2 (ja) アドレス生成器
JP5027515B2 (ja) 任意のアルゴリズムを並列計算するための再構成可能な論理回路装置
Garzón et al. AM 4: MRAM crossbar based CAM/TCAM/ACAM/AP for in-memory computing
Jarollahi et al. A low-power content-addressable memory based on clustered-sparse networks
Jothi et al. Design and analysis of power efficient binary content addressable memory (PEBCAM) core cells
TWI391946B (zh) 內容可定址記憶體
Onizawa et al. High-throughput low-energy self-timed CAM based on reordered overlapped search mechanism
Abdelhadi et al. Modular block-RAM-based longest-prefix match ternary content-addressable memories
Datti et al. Performance evaluation of content addressable memories
JP2015225675A (ja) 連想メモリおよび半導体装置
Rakka et al. Dt2cam: A decision tree to content addressable memory framework
Jarollahi et al. Algorithm and architecture of fully-parallel associative memories based on sparse clustered networks
US20160358654A1 (en) Low-power ternary content addressable memory
Hussain et al. SMS-CAM: Shared matchline scheme for content addressable memory
Hout et al. In-memory multi-valued associative processor
Kim et al. Combination-Encoding Content-Addressable Memory With High Content Density
Amrouch et al. Cross-layer design for Computing-in-Memory: From devices, circuits, to architectures and applications
JP4742281B2 (ja) 多段論理回路の再構成装置及び再構成方法、論理回路修正装置、並びに再構成可能な多段論理回路
Le et al. A fully-parallel information detection hardware system employing Content Addressable Memory

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 07739936

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 2008510867

Country of ref document: JP

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 07739936

Country of ref document: EP

Kind code of ref document: A1

WWE Wipo information: entry into national phase

Ref document number: 12294786

Country of ref document: US