JP2008131351A - Cache system, cache device, packet processor, caching method, packet processing method, caching program, and packet processing program - Google Patents

Cache system, cache device, packet processor, caching method, packet processing method, caching program, and packet processing program Download PDF

Info

Publication number
JP2008131351A
JP2008131351A JP2006314237A JP2006314237A JP2008131351A JP 2008131351 A JP2008131351 A JP 2008131351A JP 2006314237 A JP2006314237 A JP 2006314237A JP 2006314237 A JP2006314237 A JP 2006314237A JP 2008131351 A JP2008131351 A JP 2008131351A
Authority
JP
Japan
Prior art keywords
cache
packet
data
processing
packet processing
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
JP2006314237A
Other languages
Japanese (ja)
Other versions
JP4630262B2 (en
Inventor
Koji Sugisono
幸司 杉園
Takafumi Hamano
貴文 濱野
Michihiro Aoki
道宏 青木
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.)
Nippon Telegraph and Telephone Corp
Original Assignee
Nippon Telegraph and Telephone 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 Nippon Telegraph and Telephone Corp filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2006314237A priority Critical patent/JP4630262B2/en
Publication of JP2008131351A publication Critical patent/JP2008131351A/en
Application granted granted Critical
Publication of JP4630262B2 publication Critical patent/JP4630262B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To actualize load dispersion in a cache system by processing packets belonging to the same flow by a plurality of processors. <P>SOLUTION: A cache device 1 retrieves cache data based upon a flow identifier of a received packet, and passes the data and information for packet processing to a packet processor 2 when cache data corresponding to the flow identifier are found, but requests the packet processor 2 to process the data when not. The cache device caches the processed data after receiving them, manages the arrival order of packets by flows, and sorts the data processed by the packet processor 2 in the order of arrival at a transfer device. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明はプロセスやデータを複数のプロセッサ、ならびにプロセッサ内に存在するスレッドを用いて並列処理を行う計算機に関する。特にパケット処理プロセッサが複数の処理を並列に処理することができるデータ転送装置におけるキャッシュの実現方法に関するものである。   The present invention relates to a computer that performs parallel processing of processes and data using a plurality of processors and threads existing in the processors. In particular, the present invention relates to a cache implementation method in a data transfer apparatus in which a packet processor can process a plurality of processes in parallel.

近年、プロセッサの性能向上に限界が見えてきたのに伴い複数のプロセッサを用意し、それぞれで並列処理を行うようなマルチプロセッサシステムが提供されている。また、プロセッサの処理能力の向上の一手法として、高速なキャッシュを用いて、低速なキャッシュへのアクセス回数を削減する方式が存在する。パケット処理を行う場合でもこのような高速手法は有効であり、現在、多くの方法が検討されている。このような手法をマルチプロセッサシステムに適用する際、次の非特許文献1に示されるような方式が使用される。   In recent years, there has been provided a multiprocessor system in which a plurality of processors are prepared and parallel processing is performed on each of them as the limit of improvement in processor performance has been seen. As a technique for improving the processing capacity of a processor, there is a system that uses a high-speed cache to reduce the number of accesses to a low-speed cache. Even when packet processing is performed, such a high-speed method is effective, and many methods are currently being studied. When such a method is applied to a multiprocessor system, a method as shown in the following non-patent document 1 is used.

パケット処理では、同一フローに属するパケット同士で経路などの検索結果を共用することができる。このため、同一フローに属するパケット同士でキャッシュされたデータを使用することで処理の高速化が見込まれる。非特許文献1で紹介する方式では、同一フローに属するパケットを同一のプロセッサで処理させることでキャッシュの効果を利用している。これを実現するために、処理プロセッサの前にフローIDを元にハッシュ計算を行い、計算結果を、パケットを処理するプロセッサのIDと関連づけるという機能を用意している。ハッシュを利用すると、同一のフローIDを持つパケットは同じプロセッサによりパケットを処理されることになる。
W. Shi, et al., “Load Balancing for Parallel Forwarding,” IEEE/ACM Transaction on Networking, pp.790−801, 2005
In packet processing, search results such as routes can be shared between packets belonging to the same flow. For this reason, speeding up of processing is expected by using data cached between packets belonging to the same flow. In the method introduced in Non-Patent Document 1, the cache effect is used by processing packets belonging to the same flow with the same processor. In order to realize this, a function of performing hash calculation based on the flow ID before the processing processor and associating the calculation result with the ID of the processor that processes the packet is prepared. When the hash is used, packets having the same flow ID are processed by the same processor.
W. Shi, et al. "Load Balancing for Parallel Forwarding," IEEE / ACM Transaction on Networking, pp. 790-801, 2005

ハッシュの問題点として、パケットの振り分け先をプロセッサの処理に応じて変更することができない点にある。この場合、1つのプロセッサに処理が集中する可能性が存在し、並列処理の効果を十分に得ることができない。これはフローIDごとに計算結果が決まっているというハッシュの特徴によるものである。
本発明の目的は、同一のフローに属するプロセッサを複数のプロセッサで処理し、負荷分散を実現するキャッシュシステム、キャッシュ装置、パケット処理装置、キャッシュ方法、パケット処理方法、キャッシュプログラム、およびパケット処理プログラムを提供することにある。
A problem with hashing is that the packet distribution destination cannot be changed according to the processing of the processor. In this case, there is a possibility that the processing is concentrated on one processor, and the effect of parallel processing cannot be obtained sufficiently. This is due to the hash feature that the calculation result is determined for each flow ID.
An object of the present invention is to provide a cache system, a cache device, a packet processing device, a cache method, a packet processing method, a cache program, and a packet processing program for processing a processor belonging to the same flow by a plurality of processors and realizing load distribution. It is to provide.

本発明のキャッシュシステムは、
キャッシュを提供するキャッシュ装置と、複数のパケット処理装置からなり、
前記キャッシュ装置は、受信したパケットのフロー識別子からキャッシュデータを検索し、前記フロー識別子に対応するキャッシュデータが存在する場合、データとパケット処理用の情報を前記パケット処理装置に渡し、前記フロー識別子に対応するキャッシュデータが存在しなければ前記パケット処理装置にデータの処理を依頼して、処理データをもらった後キャッシュし、フローごとにパケットの到着順序を管理して、前記パケット処理装置で処理してもらったデータを転送装置への到着順にソートし、
前記パケット処理装置は、前記キャッシュ装置からパケット処理用の情報を受け取り、前記キャッシュ装置からデータを処理する指示を受けるとデータを処理した後、結果を前記キャッシュ装置に渡し、前記指示がない場合、一緒に受け取ったキャッシュデータを用いてパケット処理を行い、処理が終わると前記キャッシュ装置にパケット処理用の情報を送る。
The cache system of the present invention
A cache device that provides a cache and a plurality of packet processing devices,
The cache device retrieves cache data from the flow identifier of the received packet, and when there is cache data corresponding to the flow identifier, passes the data and information for packet processing to the packet processing device, If there is no corresponding cache data, request the packet processing device to process the data, receive the processing data, cache it, manage the arrival order of the packets for each flow, and process the packet processing device. Sort the received data in the order of arrival at the transfer device,
The packet processing device receives information for packet processing from the cache device, processes data when receiving an instruction to process data from the cache device, passes the result to the cache device, and if there is no instruction, Packet processing is performed using the cache data received together, and when processing is completed, packet processing information is sent to the cache device.

パケットの到着順序を管理することで、同一フローに属するパケットを異なるパケット処理装置に送る場合であっても到着順序と同じ順序でパケットを送信するシステムを提供することが可能になる。結果として、パケットの処理を担当するパケット処理装置を自由に選べるため、パケット処理の負荷分散を行うことが可能となる。   By managing the arrival order of packets, it is possible to provide a system that transmits packets in the same order as the arrival order even when packets belonging to the same flow are sent to different packet processing devices. As a result, since the packet processing apparatus in charge of packet processing can be freely selected, load distribution of packet processing can be performed.

本発明のキャッシュ装置は、
パケットの処理データを格納するキャッシュと、フローごとの転送装置への到着順序をFIFOのキューで記録する順序データベースと、パケットを処理させるパケット処理装置を決定するアルゴリズムを記録したアルゴリズムテーブルと、パケットのフロー識別子から前記キャッシュのエントリを探すためのキャッシュ検索手段と、パケットを処理してもらうパケット処理装置を決定するパケット分配手段と、前記パケット処理装置から受信したキャッシュデータを前記キャッシュに記録するキャッシュアップデート手段と、前記パケット処理装置での処理が終了したパケットを転送装置の到着順にソートするソート手段と、を備え、
前記キャッシュ検索手段は、パケットからフロー識別子を調べ、前記キャッシュの中に該フロー識別子に対応するキャッシュのデータが存在するか否か調べ、存在するならば該キャッシュデータをパケット処理用の情報に追加し、存在しなければ、前記順序データベースに該フロー識別子に対するエントリが存在するか否か調べ、存在するならば対応するキャッシュデータが到着するまで待機し、存在しなければ前記キャッシュに書き込まれるデータの処理を前記パケット処理装置に指示する情報をパケット処理用の情報に追記し、
前記パケット分配手段は、パケットを処理させるパケット処理装置を前記アルゴリズムテーブルに存在するアルゴリズムに従って決定し、決定したパケット処理装置の識別子を前記順序データベースに存在するフロー識別子に対するFIFOのキューに入力し、
前記キャッシュアップデート手段は、前記パケット処理装置から送られてきたキャッシュデータを前記キャッシュに追記し、データが前記キャッシュの容量を超えると前記キャッシュからデータを削除し、
前記ソート手段は、前記パケット処理装置からパケット処理用の情報が送られてくると、パケット処理装置の識別子と、パケットのフロー識別子を確認し、前記順序データベースにおけるフロー識別子に対応するFIFOキューの先頭の識別子とパケット処理装置の識別子を比較し、異なればパケットをバッファに格納し、同じであればパケットを送信し、前記FIFOキューの先頭の識別子を削除し、バッファに格納しているパケットの存在を確認し、もし存在すれば、FIFOキューの先頭に存在する識別子と比較する、前記の動作と同様の動作を繰り返す。
The cache device of the present invention is
A cache that stores packet processing data, an order database that records the arrival order of each flow in a transfer device in a FIFO queue, an algorithm table that records an algorithm that determines a packet processing device that processes a packet, Cache search means for searching for an entry in the cache from a flow identifier, packet distribution means for determining a packet processing apparatus to process a packet, and cache update for recording cache data received from the packet processing apparatus in the cache And sorting means for sorting the packets that have been processed by the packet processing device in the order of arrival of the transfer device,
The cache search means checks a flow identifier from a packet, checks whether or not cache data corresponding to the flow identifier exists in the cache, and adds the cache data to packet processing information if it exists. If it does not exist, it is checked whether or not an entry for the flow identifier exists in the order database. If it does exist, the process waits until the corresponding cache data arrives. Add information instructing the packet processing device to the packet processing information,
The packet distribution means determines a packet processing device for processing a packet according to an algorithm existing in the algorithm table, and inputs the determined packet processing device identifier to a FIFO queue for a flow identifier existing in the order database,
The cache update means appends cache data sent from the packet processing device to the cache, and deletes data from the cache when the data exceeds the capacity of the cache,
When the packet processing information is sent from the packet processing device, the sorting unit confirms the identifier of the packet processing device and the flow identifier of the packet, and starts the FIFO queue corresponding to the flow identifier in the order database. The packet identifier is compared with the identifier of the packet processing apparatus. If they are different, the packet is stored in the buffer. If they are the same, the packet is transmitted. The identifier at the head of the FIFO queue is deleted and the packet stored in the buffer exists. And if it exists, the same operation as described above is repeated, comparing with the identifier existing at the head of the FIFO queue.

パケットの到着順序を管理することで、同一フローに属するパケットを異なるパケット処理装置に送る場合であっても到着順序と同じ順序でパケットを送信するシステムを提供することが可能になる。結果として、パケットの処理を担当するパケット処理装置を自由に選べるため、パケット処理の負荷分散を行うことが可能となる。また、パケット処理を担当するパケット処理装置を決定するアルゴリズムを複数用意することが可能であるため、管理者のポリシーに応じた負荷分散を行うことが可能になる。   By managing the arrival order of packets, it is possible to provide a system that transmits packets in the same order as the arrival order even when packets belonging to the same flow are sent to different packet processing devices. As a result, since the packet processing apparatus in charge of packet processing can be freely selected, load distribution of packet processing can be performed. In addition, since a plurality of algorithms for determining the packet processing device in charge of packet processing can be prepared, load distribution according to the administrator's policy can be performed.

本発明の実施態様によれば、キャッシュ装置は、パケット分配手段は、前記キャッシュの中に受信パケットが属するフローに対応するデータが存在せず、かつ該フローに対応する前記順序データベースのFIFOキューにパケット処理装置の識別子が存在するときに、パケットを待機させずに、処理を行っているパケット処理装置とキャッシュを共有できるパケット処理装置を、受信パケットを処理する装置として決定する。   According to the embodiment of the present invention, in the cache device, the packet distribution means has no data corresponding to the flow to which the received packet belongs in the cache, and is stored in the FIFO queue of the order database corresponding to the flow. When the identifier of the packet processing device exists, the packet processing device that can share the cache with the processing packet processing device without waiting for the packet is determined as the device that processes the received packet.

パケットの到着順序を管理することで、同一フローに属するパケットを異なるパケット処理装置に送る場合であっても到着順序と同じ順序でパケットを送信することが可能になる。さらに、同一フローに属するパケットが連続して到着し、かつキャッシュ装置に該フローに関連するキャッシュデータが存在しないと時に、先頭以外のパケットをキャッシュ装置に待機させずに、先頭のパケットを処理するパケット処理装置とキャッシュ装置とは別に設けているキャッシュを共有しているパケット処理装置に該パケットを送信することが可能であり、結果的にキャッシュ装置での待ち時間が短縮される。   By managing the arrival order of packets, packets can be transmitted in the same order as the arrival order even when packets belonging to the same flow are sent to different packet processing devices. Further, when packets belonging to the same flow arrive continuously and there is no cache data related to the flow in the cache device, the first packet is processed without waiting for the cache device to wait for a packet other than the first packet. The packet can be transmitted to a packet processing device sharing a cache provided separately from the packet processing device and the cache device, and as a result, the waiting time in the cache device is reduced.

本発明のパケット処理装置は、
キャッシュ装置から送られてきたパケット処理用の情報における、キャッシュ対象データの処理を指示する情報の有無を確認するキャッシュ有無判定手段と、前記指示があった場合、キャッシュ対象データの処理を行うキャッシュ対象データ処理手段と、前記キャッシュ対象データ以外のパケット処理行うパケット処理手段と、キャッシュ対象データの処理が終了したとき、データを前記キャッシュ装置に送るキャッシュアップデート手段と
を有し、
前記キャッシュ有無判定手段は、前記指示の情報が存在する場合、前記キャッシュ対象データ処理手段を用いてキャッシュ対象データの処理を行い、存在しなければ一緒に送られてきたキャッシュデータを用いて、前記パケット処理手段によりキャッシュ対象のデータと関連のない、もしくはキャッシュ対象のデータを使用する処理を行い、
前記キャッシュ対象データ処理手段は、前記キャッシュ対象データの処理が終了すると、前記キャッシュアップデート手段に処理結果を送り、データを前記キャッシュ装置に送る動作を行う。
The packet processing device of the present invention
In the packet processing information sent from the cache device, a cache presence / absence determining means for confirming presence / absence of information for instructing processing of the cache target data, and a cache target for processing the cache target data when the instruction is given Data processing means, packet processing means for performing packet processing other than the cache target data, and cache update means for sending data to the cache device when processing of the cache target data is completed,
The cache presence / absence determining means performs processing of the cache target data using the cache target data processing means when the instruction information exists, and if not, using the cache data sent together, Performs processing that uses data that is not related to the cache target data or that is cache target by the packet processing means,
When the processing of the cache target data is completed, the cache target data processing means sends a processing result to the cache update means and performs an operation of sending data to the cache device.

送られてきたパケットをフローの種類を問わずに処理することが可能であり、キャッシュデータと共に送られてきたパケットに対してデータの処理を行う必要がなくなるため、パケット処理装置の負荷を低減することが可能となる。   It is possible to process sent packets regardless of the type of flow, and it is not necessary to process data for packets sent with cache data, reducing the load on the packet processing device. It becomes possible.

本発明の実施態様によれば、前記キャッシュ対象データ処理手段は、パケットを処理する際に請求項2に記載のキャッシュ装置から送られてきたパケット処理用の情報の中にキャッシュ対象処理を実行する指示が存在せず、かつキャッシュデータが存在しない場合に、情報を受信したパケットに対してはキャッシュ対象データを利用しない処理を行い、処理終了後はパケット処理装置のキャッシュに対象データが書き込まれるまで待機し、受信したパケットと同じフロー識別子を持つキャッシュ対象データの処理を行っているパケットについてはデータ処理終了後、データをキャッシュ装置に送るだけでなく、パケット処理装置のキャッシュにも書き込む。   According to the embodiment of the present invention, the cache target data processing means executes the cache target processing in the packet processing information sent from the cache device according to claim 2 when processing the packet. When there is no instruction and there is no cache data, a process that does not use the cache target data is performed on the packet that received the information, and after the process ends, the target data is written to the cache of the packet processing device. For packets that are waiting and processing cache target data having the same flow identifier as the received packet, not only data is sent to the cache device but also written to the cache of the packet processing device after the data processing ends.

送られてきたパケットをフローの種類を問わずに処理することが可能であり、キャッシュデータと共に送られてきたパケットに対してデータの処理を行う必要がなくなるため、パケット処理装置の負荷を低減することが可能となる。また、請求項3の発明と組み合わせることでキャッシュ装置とは別に設けられたキャッシュを共有するパケット処理装置に、同一フローに属するパケットを送信することができる。これにより、キャッシュ装置でパケットを待機させる必要がなくなり、結果としてパケットの待ち時間が短縮される。   It is possible to process sent packets regardless of the type of flow, and it is not necessary to process data for packets sent with cache data, reducing the load on the packet processing device. It becomes possible. Further, in combination with the invention of claim 3, packets belonging to the same flow can be transmitted to a packet processing device sharing a cache provided separately from the cache device. This eliminates the need for the cache device to wait for the packet, and as a result, the packet waiting time is reduced.

本発明によれば、同一フローに属するパケットであっても、任意のパケット処理装置に処理をさせることが可能となり、結果として、負荷分散が実現される。   According to the present invention, even a packet belonging to the same flow can be processed by an arbitrary packet processing apparatus, and as a result, load distribution is realized.

次に、本発明の実施の形態について図面を参照して説明する。   Next, embodiments of the present invention will be described with reference to the drawings.

図1を参照すると、本発明の一実施形態のキャッシュシステムは、キャッシュデータを格納するキャッシュ装置1と、パケットを処理する3台のパケット処理装置2からなる。キャッシュ装置1はキャッシュデータの提供と、パケットを処理させるパケット処理装置2を決定する機能を有する。さらに、キャッシュ装置1は、この実施形態では、同一フローに属するパケットを複数のパケット処理装置2で処理させるために、パケットの処理終了順序がパケット処理装置2の負荷の状況などの要因により、必ずしもパケットの到着順序と同じでない場合が存在するため、パケットの到着順序をそろえるソート機能を持つ。
キャッシュ装置1は、図2に示すように、プロセッサ11と記憶媒体16からなる。記憶媒体16には、フローIDごとにキャッシュされたデータを格納するキャッシュ17と、パケットを処理させるパケット処理装置2を決定するア分配アルゴリズムが格納されているデータベースである分配アルゴリズム18と、フローごとの転送装置への到着順序をFIFOのキューで記録する順序データベース19とが含まれる。プロセッサ11には、パケット処理装置2から受信した、パケット処理装置2で処理されたキャッシュデータをキャッシュ17に記録するキャッシュアップデート部12と、キャッシュ17のなかに調査対象のパケットのフローID用のキャッシュデータが存在する否かを、パケットのフロー識別子から検索するキャッシュ検索部13と、パケットを処理してもらうパケット処理装置2を決定するとともに、パケットをパケット処理装置2に送るときに送る順序を順序データベース19に記録するパケット分配部14と、パケット処理装置2での処理が終了したパケットを転送装置の到着順にソートするソーター15とが含まれる。
Referring to FIG. 1, a cache system according to an embodiment of the present invention includes a cache device 1 that stores cache data and three packet processing devices 2 that process packets. The cache device 1 has functions of providing cache data and determining a packet processing device 2 that processes a packet. Furthermore, in this embodiment, since the cache device 1 causes a plurality of packet processing devices 2 to process packets belonging to the same flow, the processing end order of the packets is not necessarily due to factors such as the load status of the packet processing device 2. Since there are cases where the packet arrival order is not the same, a sort function for aligning the packet arrival order is provided.
As shown in FIG. 2, the cache device 1 includes a processor 11 and a storage medium 16. The storage medium 16 includes a cache 17 that stores data cached for each flow ID, a distribution algorithm 18 that is a database that stores a distribution algorithm that determines a packet processing device 2 that processes a packet, and a flow And an order database 19 for recording the arrival order at the transfer device in the FIFO queue. The processor 11 includes a cache update unit 12 that records the cache data received from the packet processing device 2 and processed by the packet processing device 2 in the cache 17, and a cache for the flow ID of the packet to be investigated in the cache 17. The cache search unit 13 that searches for the presence or absence of data from the flow identifier of the packet and the packet processing device 2 that receives the packet are determined, and the order in which the packet is sent to the packet processing device 2 is determined. A packet distribution unit 14 that records in the database 19 and a sorter 15 that sorts packets that have been processed by the packet processing device 2 in the order of arrival of the transfer devices are included.

パケット処理装置2は、図3に示すように、キャッシュ装置1から送られてきたパケットの情報に含まれる、キャッシュ対象データに対する処理を行うかどうかを指示するデータの有無をチェックするキャッシュ有無判定部21と、キャッシュ対象データ処理指示があったときにキャッシュ対象データのデータ処理を行うキャッシュ対象データ処理部22と、キャッシュ対象データの処理が終了したときに、処理結果をキャッシュ装置1に送るキャッシュアップデート部23と、キャッシュ対象データ処理以外のパケット処理を行うパケット処理部24と、パケット処理に使用するデータが格納されている記憶媒体25を有する。   As shown in FIG. 3, the packet processing device 2 includes a cache presence / absence determining unit that checks whether there is data instructing whether or not to process the cache target data included in the packet information transmitted from the cache device 1. 21, a cache target data processing unit 22 that performs data processing of cache target data when a cache target data processing instruction is issued, and a cache update that sends a processing result to the cache device 1 when the processing of the cache target data is completed Unit 23, a packet processing unit 24 that performs packet processing other than cache target data processing, and a storage medium 25 that stores data used for packet processing.

まず、キャッシュ装置1の動作について説明する。キャッシュ装置1の動作は、一部のパケット処理装置2との間で装置内のキャッシュを共有できる場合とそうでない場合の2種類の動作が存在する。   First, the operation of the cache device 1 will be described. There are two types of operations of the cache device 1, that is, when the cache in the device can be shared with some packet processing devices 2 and when it is not.

まず、パケット処理装置2との間でキャッシュを共有できない場合の動作を、図4を参照して説明する。キャッシュ装置1のキャッシュ検索部13はパケットを受信すると(ステップ101)、ヘッダ内のフローIDを抽出する(ステップ102)。そして、キャッシュ17を検索し、前記フローIDと同じIDに対するエントリにキャッシュデータが存在するかどうかを確認する(ステップ103)。もし存在していれば、パケット処理装置2でデータ処理を行う必要がないため、パケット処理装置2にキャッシュ対象データ処理を行わないように指示する情報を作成し、パケット情報に追加する(ステップ104)。そして、パケットを処理させるパケット処理装置2を決定する(ステップ109)。もし、エントリ自体は存在するが、キャッシュデータが存在しない場合は、同じフローに属する別のパケットに対し、パケット処理装置2がキャッシュ対象のデータの処理を行っている場合であるので、その処理が終了するまで待機する(ステップ105、106)。キャッシュ対象データの処理が終了し、処理結果がキャッシュ17に格納されると、そのキャッシュデータをパケット情報に記録する。そして、待機していた同一フローに属するすべてのパケットに対し、処理してもらうパケット処理装置2を決定し、そのパケット処理装置2にパケットを送出する(ステップ107)。エントリ自体が存在しない場合、パケット処理装置2にデータ処理を指示する情報を作成し、パケット情報に追記する(ステップ108)。そして、パケットを処理してもらうパケット処理装置2を決定する(ステップ109)。パケットを処理させるパケット処理装置2が決定すると、パケットを到着順に並べるため、順序データベース19に記録されているFIFOキューに処理させるパケット処理装置2のIDを入れる(ステップ110)。そして、選択したパケット処理装置2にパケットの情報を送信する(ステップ111、112)。   First, the operation when the cache cannot be shared with the packet processing device 2 will be described with reference to FIG. When the cache search unit 13 of the cache device 1 receives the packet (step 101), it extracts the flow ID in the header (step 102). Then, the cache 17 is searched, and it is confirmed whether or not cache data exists in an entry corresponding to the same ID as the flow ID (step 103). If it exists, since it is not necessary to perform data processing in the packet processing device 2, information that instructs the packet processing device 2 not to perform cache target data processing is created and added to the packet information (step 104). ). Then, the packet processing device 2 that processes the packet is determined (step 109). If the entry itself exists but the cache data does not exist, the packet processing device 2 is processing the data to be cached for another packet belonging to the same flow. Wait until the process is completed (steps 105 and 106). When the processing of the cache target data is completed and the processing result is stored in the cache 17, the cache data is recorded in the packet information. Then, the packet processing device 2 to be processed is determined for all packets belonging to the same flow that have been waiting, and the packet is sent to the packet processing device 2 (step 107). If the entry itself does not exist, information for instructing the packet processing device 2 to perform data processing is created and added to the packet information (step 108). Then, the packet processing device 2 that receives the packet is determined (step 109). When the packet processing device 2 that processes the packet is determined, in order to arrange the packets in the order of arrival, the ID of the packet processing device 2 that is to be processed is entered in the FIFO queue recorded in the order database 19 (step 110). Then, the packet information is transmitted to the selected packet processing device 2 (steps 111 and 112).

次に、パケット処理装置2が装置間でキャッシュの共通利用が可能な場合の動作を、図5を参照して説明する。図4の場合との違いは、キャッシュ17内にエントリは存在するが、キャッシュデータが存在しない場合(図4のステップ103、105)の動作である。図5ではエントリは存在するが、キャッシュデータが存在しない場合、パケットを待機させずに、現在データ処理中のパケットを処理しているパケット処理装置2とキャッシュを共通利用できるパケット処理装置2に送り込む(ステップ113)。このとき、パケット処理装置2ではデータ処理を行わない。   Next, an operation when the packet processing apparatus 2 can share the cache between the apparatuses will be described with reference to FIG. The difference from the case of FIG. 4 is the operation when there is an entry in the cache 17 but no cache data (steps 103 and 105 in FIG. 4). In FIG. 5, if there is an entry but no cache data exists, the packet is sent to the packet processing apparatus 2 that is currently processing the packet and the packet processing apparatus 2 that can commonly use the cache without waiting for the packet. (Step 113). At this time, the packet processing device 2 does not perform data processing.

次に、パケット処理装置2の動作を図6により説明する。パケット処理装置2はパケットをキャッシュ装置1から受信すると(ステップ201)、パケット情報中に、キャッシュ対象データの処理の指示を示す情報が存在するかどうかを確認する(ステップ202)。もし指示が存在すれば、データ処理を実行する(ステップ203)。処理が終了すると、処理結果をキャッシュするようキャッシュ装置1に指示を送る(ステップ204)。このとき、処理された結果も同時に送信する。もし、キャッシュ対象データの処理の指示が存在しなければ、ステップ203,204をスキップする。これらの処理が終了すると、データ処理以外の、処理結果を利用する処理を含めた処理を行う(ステップ205)。そして、自身のIDを含んだパケット情報をキャッシュ装置1に送り、処理を終える(ステップ206)。   Next, the operation of the packet processing device 2 will be described with reference to FIG. When the packet processing device 2 receives the packet from the cache device 1 (step 201), the packet processing device 2 checks whether there is information indicating an instruction to process the cache target data in the packet information (step 202). If there is an instruction, data processing is executed (step 203). When the processing is completed, an instruction is sent to the cache device 1 to cache the processing result (step 204). At this time, the processed result is also transmitted simultaneously. If there is no instruction for processing the cache target data, steps 203 and 204 are skipped. When these processes are completed, the process including the process using the process result other than the data process is performed (step 205). Then, packet information including its own ID is sent to the cache device 1 and the process is finished (step 206).

次に、パケット処理装置2間でキャッシュの共有が可能である場合の動作を図7により説明する。図6の場合との違いは、ステップ202におけるキャッシュ対象データの処理の指示の存在の処理以降で、特に指示が存在しない場合の動作である。指示が存在しない場合、パケット処理装置2はキャッシュを共有している別のパケット処理装置2で、同一フローに属するパケットがないか確認する(ステップ207)。存在する場合、先に処理結果を利用しない処理を行い、処理終了後は処理中のデータがキャッシュ17に書き込まれたか否かを確認し、もし書き込まれていれば、処理結果を用いた処理を行い、そうでなければキャッシュ17にデータが書き込まれるまで待機する(ステップ208)。その他の処理は図6と同じである。   Next, the operation when the cache can be shared between the packet processing devices 2 will be described with reference to FIG. The difference from the case of FIG. 6 is the operation when there is no particular instruction after the processing of the presence of the instruction to process the data to be cached in step 202. If there is no instruction, the packet processing device 2 confirms whether there is any packet belonging to the same flow in another packet processing device 2 sharing the cache (step 207). If it exists, the process that does not use the process result is performed first, and after the process is completed, it is checked whether or not the data being processed has been written to the cache 17, and if it has been written, the process using the process result is performed. If not, wait until data is written to the cache 17 (step 208). Other processes are the same as those in FIG.

次に、パケットの処理が終了した後にキャッシュ装置1がパケットを到着順に並べる処理を図8により説明する。パケット情報をパケット処理装置2から受信すると(ステップ301)、パケットのフローIDとパケットを処理したパケット処理装置2のIDを確認する(ステップ302)。そして、順序データベース19内にある、フローIDごとのFIFOキューの先頭にある、パケット処理装置のIDと比較し、次に送信するパケットかどうかを確認する(ステップ303)。IDが一致しなければ、先に到着しているパケットがまだ処理中であるため、待機させる(ステップ304)。もし一致すれば、現在処理中のパケットのうち、一番先に到着したものであるため、次に送信する(ステップ305)。このとき、FIFOキューの先頭にあった、送信したパケットを処理していたパケット処理装置のIDを削除し、次に送信するパケットを処理しているパケット処理装置のIDを見る(ステップ306)。その後、送信したパケットより先に処理が終了し、待機しているパケットがないか確認する(ステップ307)。もし存在すれば、FIFOキューの先頭に位置するIDと、待機しているパケットを処理していたパケット処理装置のIDを比較し(ステップ308)、同じであればパケットを送信する(ステップ305)。そして再びステップ306の処理を行う。もし、IDが異なれば、まだ先に到着しているパケットが処理中であるため、再び待機する(ステップ309)。   Next, a process in which the cache device 1 arranges the packets in the order of arrival after the packet processing is completed will be described with reference to FIG. When packet information is received from the packet processing device 2 (step 301), the flow ID of the packet and the ID of the packet processing device 2 that has processed the packet are confirmed (step 302). Then, it is compared with the ID of the packet processing device at the head of the FIFO queue for each flow ID in the order database 19 to confirm whether the packet is to be transmitted next (step 303). If the IDs do not match, the packet that has arrived first is still being processed, and the process waits (step 304). If they match, the packet that is currently being processed has arrived first, so it is transmitted next (step 305). At this time, the ID of the packet processing device that was processing the transmitted packet at the head of the FIFO queue is deleted, and the ID of the packet processing device that is processing the packet to be transmitted next is viewed (step 306). Thereafter, the processing is completed before the transmitted packet, and it is confirmed whether there is any waiting packet (step 307). If it exists, the ID located at the head of the FIFO queue is compared with the ID of the packet processing device that was processing the waiting packet (step 308), and if they are the same, the packet is transmitted (step 305). . Then, the process of step 306 is performed again. If the IDs are different, since the packet that has arrived earlier is still being processed, the process waits again (step 309).

なお、パケット処理装置2間でキャッシュを共有できる場合の具体例としては、1プロセッサ内でマルチスレッディングを行っており、各スレッドがコアのキャッシュを互いに使用する場合などがある。その具体的な動作については後ほど述べる。   A specific example of a case where the cache can be shared between the packet processing apparatuses 2 is a case where multi-threading is performed within one processor and the threads use the core cache. The specific operation will be described later.

次に、具体的なパケット処理例を、図9以降の各図を用いて説明する。図9では、キャッシュ装置1がいかなるエントリももっていない状況下でフローIDとしてAをもつフローAのパケットが到着した時の状況を示す。キャッシュ装置1はエントリがないため、キャッシュ対象データの処理を指示する情報を、パケット処理に使用するパケット情報に記載し、パケット処理装置2にアルゴリズムにしたがって送信する。ここではアルゴリズムにより、パケット処理装置23にパケットを処理させることにしたとする。キャッシュ装置1はフローAのパケットがパケット処理装置23で処理されていることを順序データベース19で管理する。このため、順序データベース19におけるフローIDがAのエントリとなるFIFOキューにパケット処理装置23のIDである3を入れる。 Next, specific packet processing examples will be described with reference to FIGS. FIG. 9 shows a situation when a packet of a flow A having A as a flow ID arrives in a situation where the cache device 1 has no entry. Since the cache device 1 does not have an entry, information for instructing processing of the cache target data is described in the packet information used for packet processing, and is transmitted to the packet processing device 2 according to an algorithm. The algorithm is here, and it was decided to process the packet to the packet processing device 2 3. Cache apparatus 1 manages the packet of flow A is processed in the packet processing device 2 3 in the order database 19. Therefore, 3 which is the ID of the packet processing device 23 is put in the FIFO queue in which the flow ID in the order database 19 is an entry of A.

図10はその後、フローIDがBのパケットとフローAのパケットの2つめが到着したときを示す。フローIDがBのパケットは図9におけるフローAのパケットと同じ処理を行う。そして、フローIDがAの2つめのパケットが到着すると、キャッシュ装置1はフローIDがAに対するキャッシュ情報を有するかどうか確認する。キャッシュ情報がまだなく、順序データベース19にパケットを処理しているパケット処理装置のIDが存在することを確認すると、キャッシュ装置1は現在フローAのパケットがパケット処理装置2でデータ処理中であると判断し、2つめのパケットを待機させる。   FIG. 10 shows a time when the second packet of flow ID B and flow A arrives. The packet with flow ID B performs the same processing as the packet with flow A in FIG. When the second packet with the flow ID A arrives, the cache device 1 checks whether the flow ID has cache information for A. When it is confirmed that there is no cache information yet and the ID of the packet processing device that processes the packet exists in the order database 19, the cache device 1 determines that the packet of the flow A is currently being processed by the packet processing device 2. Judge and wait for the second packet.

図11で、パケット処理装置23でのフローAの1つめのパケットに対するキャッシュ対象データの処理が終了したときの様子を説明する。パケット処理装置23はデータ処理が終了すると、キャッシュ装置1に処理結果を送信する。これを受け、キャッシュ装置1は処理結果をキャッシュする。これと同時に待機していたフローAの2つめのパケットのパケット処理装置を決定し、そこにパケット情報を送る。このとき、アップデートされたキャッシュの情報をパケット情報の一部に加えて送信する。ここで、2つめのパケットをパケット処理装置22で処理すると考える。キャッシュ装置1はパケットをパケット処理装置22に送るときに、順序データベース19内のフローAに対するFIFOキューの後ろにパケット処理装置22のIDである2を挿入する。 In Figure 11, illustrating a state where the processing of the cached data for the first one packet of flow A in the packet processing device 2 3 is finished. When the packet processing device 2 3 is the data processing is completed, and transmits the processing result to the cache device 1. In response to this, the cache device 1 caches the processing result. At the same time, a packet processing apparatus for the second packet of the flow A that has been waiting is determined, and packet information is sent thereto. At this time, the updated cache information is transmitted in addition to a part of the packet information. Now consider the process the second packet in the packet processing device 2 2. When sending the packet to the packet processing device 2 2 , the cache device 1 inserts 2 which is the ID of the packet processing device 2 2 after the FIFO queue for the flow A in the order database 19.

図12にフローAの1つめのパケットの処理が終了し、情報がキャッシュ装置1に戻されるときの動作が記載されている。キャッシュ装置1はパケット処理装置23からパケット情報を受信すると、順序データベース19を参照し、フローAにおける次に送信するパケットがどこで処理されていたかを確認する。この場合、パケット処理装置23で処理されているパケットが次に送信するものであることを示されており、到着したパケットが次に送信するパケットであることがわかる。これを受けてキャッシュ装置1は次の処理を行うパケット処理装置にパケットを送る。そして、順序データベース19の先頭にあった、パケット処理装置22を示すIDを削除する。これにより、次に送信するパケットがパケット処理装置22で処理されていることがわかる。そして、現在フローAのパケットがキャッシュ装置1で待機させられているかどうかを確認する。この場合、パケットは待機させられていないので、処理は終了する。もし待機させられていたら、FIFOキューの先頭のIDと待機しているパケットが処理されていたパケット処理装置2のIDを比較し、送信するかどうかを判定するという処理が走る。 FIG. 12 shows the operation when the processing of the first packet of the flow A is completed and the information is returned to the cache device 1. When the cache apparatus 1 receives the packet information from the packet processing unit 2 3, with reference to the sequence database 19 to confirm whether or not treated with where the packet to be transmitted to the next in the flow A. In this case, been shown that the packet being processed by the packet processing device 2 3 is intended to be transmitted next, it can be seen that packets arriving are next packet to be transmitted. In response to this, the cache device 1 sends the packet to the packet processing device that performs the next processing. Then, there was the beginning of the sequence database 19, deletes the ID indicating the packet processing unit 2 2. Thus, it is understood that the packet to be next transmitted is processed in the packet processing device 2 2. Then, it is confirmed whether or not the packet of the flow A is currently waiting in the cache device 1. In this case, since the packet is not kept waiting, the process ends. If it is waiting, the process of comparing the head ID of the FIFO queue with the ID of the packet processing device 2 that has processed the waiting packet and determining whether or not to transmit is performed.

図13で、フローIDがAの3番目のパケットが新たに到着し、パケット処理装置22で処理されている2番目のパケットより先に処理が終了したときの動作の説明を行う。キャッシュ装置1は順序データベース19から次に送信するパケットは現在処理装置22で処理されていることがわかるため、到着した3番目のパケットを待機させる。その後、2番目のパケットを送信した後に、順序データベース19が3番目のパケットを送信することを示すため、そのときに3番目のパケットを送信する。 In Figure 13, the flow ID is the third packet of A newly arrived, a description of the operation when the packet processing device 2 2 in the second earlier treatment than packet being processed is finished. Cache device 1 since it is understood that the packet to be transmitted next from the sequence database 19 being processed in the current processing unit 2 2, to wait a third packet that arrived. After that, after transmitting the second packet, the order database 19 indicates that the third packet is to be transmitted, so that the third packet is transmitted at that time.

最後に、パケット処理装置2の一部でキャッシュを共有できるときの動作例を図14に示す。この例では、パケット処理装置2として、複数のタスクを1つのプロセッサリソースを用いて実行するマルチスレッディング可能なプロセッサ(パケット処理装置を複数収容した装置)を利用する。この中では、前回までの説明におけるパケット処理装置2が1つのスレッドに相当する。同一のプロセッサで走るスレッド同士では、プロセッサ内に存在するキャッシュを共有することが可能となる。この場合、フローAの1番目のパケットがプロセッサ3のスレッド1番で処理されているとすると、2番目のパケットが到着したとき、キャッシュ装置1は2番目のパケットの処理をプロセッサ3のいずれかのスレッドに行わせる。1番目のパケットのキャッシュ対象データ処理が終了すると(図15)、キャッシュ結果はキャッシュ装置1と1番目のパケットを処理したプロセッサのキャッシュに書き込まれる。2番目のパケットにおけるキャッシュ対象のデータを使用した処理はプロセッサのキャッシュに書き込まれたデータを用いて行われる。2番目のパケットを行う際、キャッシュにデータがある場合はそれを利用して処理を行い、ない場合は先にキャッシュ対象のデータを使用しない処理を行う。そして、キャッシュ対象データ処理結果を使用する処理は、処理結果がキャッシュに書き込まれるまで待つ。そのほかの処理は前述の説明と同じ動作を行う。   Finally, FIG. 14 shows an operation example when the cache can be shared by a part of the packet processing device 2. In this example, as the packet processing device 2, a multi-threadable processor (a device containing a plurality of packet processing devices) that executes a plurality of tasks by using one processor resource is used. Among these, the packet processing device 2 in the description up to the previous time corresponds to one thread. Threads running on the same processor can share a cache existing in the processors. In this case, assuming that the first packet of the flow A is processed by the thread 1 of the processor 3, when the second packet arrives, the cache device 1 processes the second packet to one of the processors 3. Let this thread do it. When the cache target data processing for the first packet is completed (FIG. 15), the cache result is written to the cache of the cache device 1 and the processor that processed the first packet. The processing using the data to be cached in the second packet is performed using the data written in the processor cache. When performing the second packet, if there is data in the cache, processing is performed using the data, and if not, processing not using the data to be cached is performed first. Then, the process using the cache target data processing result waits until the processing result is written in the cache. Other processes perform the same operations as described above.

なお、キャッシュ装置およびパケット処理装置の機能は、その機能を実現するためのプログラムを、コンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータに読み込ませ、実行するものであってもよい。コンピュータ読み取り可能な記録媒体とは、フレキシブルディスク、光磁気ディスク、CD−ROM等の記録媒体、コンピュータシステムに内蔵されるハードディスク装置等の記憶装置を指す。さらに、コンピュータ読み取り可能な記録媒体は、インターネットを介してプログラムを送信する場合のように、短時間、動的にプログラムを保持するもの(伝送媒体もしくは伝送波)、その場合のサーバとなるコンピュータ内の揮発性メモリのように、一定時間プログラムを保持しているものを含む。   The functions of the cache device and the packet processing device are executed by recording a program for realizing the function on a computer-readable recording medium, causing the computer to read the program recorded on the recording medium, and executing the program. It may be. The computer-readable recording medium refers to a recording medium such as a flexible disk, a magneto-optical disk, and a CD-ROM, and a storage device such as a hard disk device built in a computer system. Further, the computer-readable recording medium is a medium that dynamically holds the program for a short time (transmission medium or transmission wave) as in the case of transmitting the program via the Internet, and in the computer serving as a server in that case Such as a volatile memory that holds a program for a certain period of time.

本発明の一実施形態のキャッシュシステムの構成図である。It is a block diagram of the cache system of one Embodiment of this invention. キャッシュ装置のブロック図である。It is a block diagram of a cache device. パケット処理装置のブロック図である。It is a block diagram of a packet processing apparatus. パケット分配時(マルチスレッド不可)のキャッシュ装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of the cache apparatus at the time of packet distribution (multithread impossible). パケット分配時(パケット処理装置キャッシュ共有可)のキャッシュ装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of the cache apparatus at the time of packet distribution (packet processing apparatus cache sharing is possible). パケット処理装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a packet processing apparatus. パケット処理装置(キャッシュ共有可)の動作を示すフローチャートである。It is a flowchart which shows operation | movement of a packet processing apparatus (cache sharing is possible). ソート時のキャッシュ装置の動作を示すフローチャートである。It is a flowchart which shows operation | movement of the cache apparatus at the time of a sort. 具体的なパケット処理例(その1)を示す図である。It is a figure which shows the specific packet processing example (the 1). 具体的なパケット処理例(その2)を示す図である。It is a figure which shows the specific packet processing example (the 2). 具体的なパケット処理例(その3)を示す図である。It is a figure which shows the specific packet processing example (the 3). 具体的なパケット処理例(その4)を示す図である。It is a figure which shows the specific packet processing example (the 4). 具体的なパケット処理例(その5)を示す図である。It is a figure which shows the specific packet processing example (the 5). 具体的なパケット処理例(その6)を示す図である。It is a figure which shows the specific packet processing example (the 6). 具体的なパケット処理例(その7)を示す図である。It is a figure which shows the specific packet processing example (the 7).

符号の説明Explanation of symbols

1 キャッシュ装置
2,21〜24 パケット処理装置
11 プロセッサ
12 キャッシュアップデート部
13 キャッシュ検索部
14 パケット分配部
15 ソーター
16 記憶媒体
17 キャッシュ
18 分配アルゴリズム
19 順序データベース
21 キャッシュ有無判定部
22 キャッシュ対象データ処理部
23 キャッシュアップデート部
24 パケット処理部
25 記憶媒体
101〜113,201〜208,301〜308 ステップ
DESCRIPTION OF SYMBOLS 1 Cache apparatus 2,2 1 to 2 4 Packet processing apparatus 11 Processor 12 Cache update part 13 Cache search part 14 Packet distribution part 15 Sorter 16 Storage medium 17 Cache 18 Distribution algorithm 19 Order database 21 Cache existence determination part 22 Cache target data processing Unit 23 cache update unit 24 packet processing unit 25 storage medium 101 to 113, 201 to 208, 301 to 308 steps

Claims (11)

キャッシュを提供するキャッシュ装置と、複数のパケット処理装置からなり、
前記キャッシュ装置は、受信したパケットのフロー識別子からキャッシュデータを検索し、前記フロー識別子に対応するキャッシュデータが存在する場合、データとパケット処理用の情報を前記パケット処理装置に渡し、前記フロー識別子に対応するキャッシュデータが存在しなければ前記パケット処理装置にデータの処理を依頼して、処理データをもらった後キャッシュし、フローごとにパケットの到着順序を管理して、前記パケット処理装置で処理してもらったデータを転送装置への到着順にソートし、
前記パケット処理装置は、前記キャッシュ装置からパケット処理用の情報を受け取り、前記キャッシュ装置からデータを処理する指示を受けるとデータを処理した後、結果を前記キャッシュ装置に渡し、前記指示がない場合、一緒に受け取ったキャッシュデータを用いてパケット処理を行い、処理が終わると前記キャッシュ装置にパケット処理用の情報を送る
キャッシュシステム。
A cache device that provides a cache and a plurality of packet processing devices,
The cache device retrieves cache data from the flow identifier of the received packet, and when there is cache data corresponding to the flow identifier, passes the data and information for packet processing to the packet processing device, If there is no corresponding cache data, request the packet processing device to process the data, receive the processing data, cache it, manage the arrival order of the packets for each flow, and process the packet processing device. Sort the received data in the order of arrival at the transfer device,
The packet processing device receives information for packet processing from the cache device, processes data when receiving an instruction to process data from the cache device, passes the result to the cache device, and if there is no instruction, A cache system that performs packet processing using the cache data received together and sends packet processing information to the cache device when the processing is completed.
パケットの処理データを格納するキャッシュと、フローごとの転送装置への到着順序をFIFOのキューで記録する順序データベースと、パケットを処理させるパケット処理装置を決定するアルゴリズムを記録したアルゴリズムテーブルと、パケットのフロー識別子から前記キャッシュのエントリを探すためのキャッシュ検索手段と、パケットを処理してもらうパケット処理装置を決定するパケット分配手段と、前記パケット処理装置から受信したキャッシュデータを前記キャッシュに記録するキャッシュアップデート手段と、前記パケット処理装置での処理が終了したパケットを転送装置の到着順にソートするソート手段と、を備え、
前記キャッシュ検索手段は、パケットからフロー識別子を調べ、前記キャッシュの中に該フロー識別子に対応するキャッシュのデータが存在するか否か調べ、存在するならば該キャッシュデータをパケット処理用の情報に追加し、存在しなければ、前記順序データベースに該フロー識別子に対するエントリが存在するか否か調べ、存在するならば対応するキャッシュデータが到着するまで待機し、存在しなければ前記キャッシュに書き込まれるデータの処理を前記パケット処理装置に指示する情報をパケット処理用の情報に追記し、
前記パケット分配手段は、パケットを処理させるパケット処理装置を前記アルゴリズムテーブルに存在するアルゴリズムに従って決定し、決定したパケット処理装置の識別子を前記順序データベースに存在するフロー識別子に対するFIFOのキューに入力し、
前記キャッシュアップデート手段は、前記パケット処理装置から送られてきたキャッシュデータを前記キャッシュに追記し、データが前記キャッシュの容量を超えると前記キャッシュからデータを削除し、
前記ソート手段は、前記パケット処理装置からパケット処理用の情報が送られてくると、パケット処理装置の識別子と、パケットのフロー識別子を確認し、前記順序データベースにおけるフロー識別子に対応するFIFOキューの先頭の識別子とパケット処理装置の識別子を比較し、異なればパケットをバッファに格納し、同じであればパケットを送信し、前記FIFOキューの先頭の識別子を削除し、バッファに格納しているパケットの存在を確認し、もし存在すれば、FIFOキューの先頭に存在する識別子と比較する、前記の動作と同様の動作を繰り返す
キャッシュ装置。
A cache that stores packet processing data, an order database that records the arrival order of each flow in a transfer device in a FIFO queue, an algorithm table that records an algorithm that determines a packet processing device that processes a packet, Cache search means for searching for an entry in the cache from a flow identifier, packet distribution means for determining a packet processing apparatus to process a packet, and cache update for recording cache data received from the packet processing apparatus in the cache And sorting means for sorting the packets that have been processed by the packet processing device in the order of arrival of the transfer device,
The cache search means checks a flow identifier from a packet, checks whether or not cache data corresponding to the flow identifier exists in the cache, and adds the cache data to packet processing information if it exists. If it does not exist, it is checked whether or not an entry for the flow identifier exists in the order database. If it does exist, the process waits until the corresponding cache data arrives. Add information instructing the packet processing device to the packet processing information,
The packet distribution means determines a packet processing device for processing a packet according to an algorithm existing in the algorithm table, and inputs the determined packet processing device identifier to a FIFO queue for a flow identifier existing in the order database,
The cache update means appends cache data sent from the packet processing device to the cache, and deletes data from the cache when the data exceeds the capacity of the cache,
When the packet processing information is sent from the packet processing device, the sorting unit confirms the identifier of the packet processing device and the flow identifier of the packet, and starts the FIFO queue corresponding to the flow identifier in the order database. The packet identifier is compared with the identifier of the packet processing apparatus. If they are different, the packet is stored in the buffer. If they are the same, the packet is transmitted. The identifier at the head of the FIFO queue is deleted and the packet stored in the buffer exists. A cache device that repeats an operation similar to the above-described operation that compares the identifier with the identifier that exists at the head of the FIFO queue.
前記パケット分配手段は、前記キャッシュの中に受信パケットが属するフローに対応するデータが存在せず、かつ該フローに対応する前記順序データベースのFIFOキューにパケット処理装置の識別子が存在するときに、パケットを待機させずに、処理を行っているパケット処理装置とキャッシュを共有できるパケット処理装置を、受信パケットを処理する装置として決定する、請求項2に記載のキャッシュ装置。   The packet distribution means is configured such that when there is no data corresponding to the flow to which the received packet belongs in the cache and the identifier of the packet processing device exists in the FIFO queue of the sequence database corresponding to the flow. The cache device according to claim 2, wherein a packet processing device that can share a cache with a packet processing device that performs processing without waiting for a packet is determined as a device that processes received packets. キャッシュ装置から送られてきたパケット処理用の情報における、キャッシュ対象データの処理を指示する情報の有無を確認するキャッシュ有無判定手段と、前記指示があった場合、キャッシュ対象データの処理を行うキャッシュ対象データ処理手段と、前記キャッシュ対象データ以外のパケット処理行うパケット処理手段と、キャッシュ対象データの処理が終了したとき、データを前記キャッシュ装置に送るキャッシュアップデート手段と
を有し、
前記キャッシュ有無判定手段は、前記指示の情報が存在する場合、前記キャッシュ対象データ処理手段を用いてキャッシュ対象データの処理を行い、存在しなければ一緒に送られてきたキャッシュデータを用いて、前記パケット処理手段によりキャッシュ対象のデータと関連のない、もしくはキャッシュ対象のデータを使用する処理を行い、
前記キャッシュ対象データ処理手段は、前記キャッシュ対象データの処理が終了すると、前記キャッシュアップデート手段に処理結果を送り、データを前記キャッシュ装置に送る動作を行う
パケット処理装置。
In the packet processing information sent from the cache device, a cache presence / absence determining means for confirming presence / absence of information for instructing processing of the cache target data, and a cache target for processing the cache target data when the instruction is given Data processing means, packet processing means for performing packet processing other than the cache target data, and cache update means for sending data to the cache device when processing of the cache target data is completed,
The cache presence / absence determining means performs processing of the cache target data using the cache target data processing means when the instruction information exists, and if not, using the cache data sent together, Performs processing that uses data that is not related to the cache target data or that is cache target by the packet processing means,
The cache target data processing means, when the processing of the cache target data is completed, sends a processing result to the cache update means and performs an operation of sending data to the cache apparatus.
前記キャッシュ対象データ処理手段は、パケットを処理する際に請求項2に記載のキャッシュ装置から送られてきたパケット処理用の情報の中にキャッシュ対象処理を実行する指示が存在せず、かつキャッシュデータが存在しない場合に、情報を受信したパケットに対してはキャッシュ対象データを利用しない処理を行い、処理終了後はパケット処理装置のキャッシュに対象データが書き込まれるまで待機し、受信したパケットと同じフロー識別子を持つキャッシュ対象データの処理を行っているパケットについてはデータ処理終了後、データをキャッシュ装置に送るだけでなく、パケット処理装置のキャッシュにも書き込む、請求項4に記載のパケット処理装置。   The cache target data processing means does not include an instruction to execute cache target processing in the packet processing information sent from the cache device according to claim 2 when processing a packet, and cache data If the packet does not exist, a process that does not use the cache target data is performed on the packet that received the information, and after the process is completed, the process waits until the target data is written to the cache of the packet processing device, and the same flow as the received packet The packet processing device according to claim 4, wherein for a packet that is processing cache target data having an identifier, the data is not only sent to the cache device but also written to the cache of the packet processing device after the data processing ends. パケットの処理データを格納するキャッシュと、フローごとの転送装置への到着順序をFIFOのキューで記録する順序データベースと、パケットを処理させるパケット処理装置を決定するアルゴリズムを記録したアルゴリズムテーブルと、パケットのフロー識別子から前記キャッシュのエントリを探すためのキャッシュ検索手段と、パケットを処理してもらうパケット処理装置を決定するパケット分配手段と、前記パケット処理装置から受信したキャッシュデータを前記キャッシュに記録するキャッシュアップデート手段と、前記パケット処理装置での処理が終了したパケットを転送装置の到着順にソートするソート手段と、を備えたキャッシュ装置で行われるキャッシュ方法であって、
前記キャッシュ検索手段が、パケットからフロー識別子を調べ、前記キャッシュの中に該フロー識別子に対応するキャッシュのデータが存在するか否か調べ、存在するならば該キャッシュデータをパケット処理用の情報に追加し、存在しなければ、前記順序データベースに該フロー識別子に対するエントリが存在するか否か調べ、存在するならば対応するキャッシュデータが到着するまで待機し、存在しなければ前記キャッシュに書き込まれるデータの処理を前記パケット処理装置に指示する情報をパケット処理用の情報に追記するステップと、
前記パケット分配手段が、パケットを処理させるパケット処理装置を前記アルゴリズムテーブルに存在するアルゴリズムに従って決定し、決定したパケット処理装置の識別子を前記順序データベースに存在するフロー識別子に対するFIFOのキューに入力するステップと、
前記キャッシュアップデート手段が、前記パケット処理装置から送られてきたキャッシュデータを前記キャッシュに追記し、データが前記キャッシュの容量を超えると前記キャッシュからデータを削除するステップと、
前記ソート手段が、前記パケット処理装置からパケット処理用の情報が送られてくると、パケット処理装置の識別子と、パケットのフロー識別子を確認し、前記順序データベースにおけるフロー識別子に対応するFIFOキューの先頭の識別子とパケット処理装置の識別子を比較し、異なればパケットをバッファに格納し、同じであればパケットを送信し、前記FIFOキューの先頭の識別子を削除し、バッファに格納しているパケットの存在を確認し、もし存在すれば、FIFOキューの先頭に存在する識別子と比較する、前記の動作と同様の動作を繰り返すステップと、
を有するキャッシュ方法。
A cache that stores packet processing data, an order database that records the arrival order of each flow in a transfer device in a FIFO queue, an algorithm table that records an algorithm that determines a packet processing device that processes a packet, Cache search means for searching for an entry in the cache from a flow identifier, packet distribution means for determining a packet processing apparatus to process a packet, and cache update for recording cache data received from the packet processing apparatus in the cache A cache method performed by a cache device comprising: and a sorting unit that sorts packets that have been processed by the packet processing device in the order of arrival of the transfer device,
The cache search means checks the flow identifier from the packet, checks whether or not the cache data corresponding to the flow identifier exists in the cache, and adds the cache data to the packet processing information if it exists. If it does not exist, it is checked whether or not an entry for the flow identifier exists in the order database. If it does exist, the process waits until the corresponding cache data arrives. Adding information instructing processing to the packet processing device to information for packet processing;
The packet distribution means determining a packet processing device for processing a packet according to an algorithm existing in the algorithm table, and inputting the determined identifier of the packet processing device to a FIFO queue for a flow identifier existing in the sequence database; ,
The cache update means appends cache data sent from the packet processing device to the cache, and deletes data from the cache when the data exceeds the capacity of the cache;
When information for packet processing is sent from the packet processing device, the sorting means confirms the identifier of the packet processing device and the flow identifier of the packet, and starts the FIFO queue corresponding to the flow identifier in the order database. The packet identifier is compared with the identifier of the packet processing apparatus. If they are different, the packet is stored in the buffer. If they are the same, the packet is transmitted. The identifier at the head of the FIFO queue is deleted and the packet stored in the buffer exists. Repeating the same operation as described above, comparing with the identifier present at the head of the FIFO queue if present,
A cache method comprising:
前記パケット分配手段が、前記キャッシュの中に受信パケットが属するフローに対応するデータが存在せず、かつ該フローに対応する前記順序データベースのFIFOキューにパケット処理装置の識別子が存在するときに、パケットを待機させずに、処理を行っているパケット処理装置とキャッシュを共有できるパケット処理装置を、受信パケットを処理する装置として決定するステップをさらに有する、請求項6に記載のキャッシュ方法。   When the packet distribution means has no data corresponding to the flow to which the received packet belongs in the cache, and the identifier of the packet processing device exists in the FIFO queue of the sequence database corresponding to the flow. The cache method according to claim 6, further comprising: determining a packet processing device that can share a cache with a packet processing device that is processing without waiting as a device that processes a received packet. キャッシュ装置から送られてきたパケット処理用の情報における、キャッシュ対象データの処理を指示する情報の有無を確認するキャッシュ有無判定手段と、前記指示があった場合、キャッシュ対象データの処理を行うキャッシュ対象データ処理手段と、前記キャッシュ対象データ以外のパケット処理行うパケット処理手段と、キャッシュ対象データの処理が終了したとき、データを前記キャッシュ装置に送るキャッシュアップデート手段とを有するパケット処理装置で行われるパケット処理方法であって、
前記キャッシュ有無判定手段が、前記指示の情報が存在する場合、前記キャッシュ対象データ処理手段を用いてキャッシュ対象データの処理を行い、存在しなければ一緒に送られてきたキャッシュデータを用いて、前記パケット処理手段によりキャッシュ対象のデータと関連のない、もしくはキャッシュ対象のデータを使用する処理を行うステップと、
前記キャッシュ対象データ処理手段が、前記キャッシュ対象データの処理が終了すると、前記キャッシュアップデート手段に処理結果を送り、データを前記キャッシュ装置に送る動作を行うステップと
を有する、パケット処理方法。
In the packet processing information sent from the cache device, a cache presence / absence determining means for confirming presence / absence of information for instructing processing of the cache target data, and a cache target for processing the cache target data when the instruction is given Packet processing performed in a packet processing device having data processing means, packet processing means for performing packet processing other than the cache target data, and cache update means for sending data to the cache device when processing of the cache target data is completed A method,
If the instruction information is present, the cache presence / absence determining means performs processing of the cache target data using the cache target data processing means, and if not, using the cache data sent together, A step of performing processing that uses the data to be cached or not related to the data to be cached by the packet processing means;
A packet processing method comprising: a step in which the cache target data processing unit sends a processing result to the cache update unit and sends data to the cache device when the processing of the cache target data is completed.
前記キャッシュ対象データ処理手段が、パケットを処理する際に請求項6に記載のキャッシュ装置から送られてきたパケット処理用の情報の中にキャッシュ対象処理を実行する指示が存在せず、かつキャッシュデータが存在しない場合に、情報を受信したパケットに対してはキャッシュ対象データを利用しない処理を行い、処理終了後はパケット処理装置のキャッシュに対象データが書き込まれるまで待機し、受信したパケットと同じフロー識別子を持つキャッシュ対象データの処理を行っているパケットについてはデータ処理終了後、データをキャッシュ装置に送るだけでなく、パケット処理装置のキャッシュにも書き込む、請求項8に記載のパケット処理方法。   When the cache target data processing means processes a packet, there is no instruction for executing the cache target processing in the packet processing information sent from the cache device according to claim 6, and the cache data If the packet does not exist, a process that does not use the cache target data is performed on the packet that received the information, and after the process is completed, the process waits until the target data is written to the cache of the packet processing device, and the same flow as the received packet The packet processing method according to claim 8, wherein for a packet that is processing cache target data having an identifier, after the data processing is completed, the data is not only sent to the cache device but also written to the cache of the packet processing device. 請求項2または3に記載のキャッシュ装置をコンピュータとして機能させるためのキャッシュプログラム。   A cache program for causing the cache device according to claim 2 or 3 to function as a computer. 請求項4または5に記載のパケット処理装置をコンピュータとして機能させるためのパケット処理プログラム。   A packet processing program for causing the packet processing device according to claim 4 or 5 to function as a computer.
JP2006314237A 2006-11-21 2006-11-21 Cache system, cache device, packet processing device, cache method, packet processing method, cache program, and packet processing program Expired - Fee Related JP4630262B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006314237A JP4630262B2 (en) 2006-11-21 2006-11-21 Cache system, cache device, packet processing device, cache method, packet processing method, cache program, and packet processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006314237A JP4630262B2 (en) 2006-11-21 2006-11-21 Cache system, cache device, packet processing device, cache method, packet processing method, cache program, and packet processing program

Publications (2)

Publication Number Publication Date
JP2008131351A true JP2008131351A (en) 2008-06-05
JP4630262B2 JP4630262B2 (en) 2011-02-09

Family

ID=39556767

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006314237A Expired - Fee Related JP4630262B2 (en) 2006-11-21 2006-11-21 Cache system, cache device, packet processing device, cache method, packet processing method, cache program, and packet processing program

Country Status (1)

Country Link
JP (1) JP4630262B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9124540B2 (en) 2013-01-14 2015-09-01 Lenovo Enterprise Solutions (Singapore) Pte. Ltd. Caching of look-up rules based on flow heuristics to enable high speed look-up

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004158903A (en) * 2002-11-01 2004-06-03 Fujitsu Ltd Packet processing apparatus
JP2004260532A (en) * 2003-02-26 2004-09-16 Hitachi Ltd Network processor
JP2005117206A (en) * 2003-10-06 2005-04-28 Hitachi Ltd Network processor accelerator
JP2005519530A (en) * 2002-03-05 2005-06-30 インターナショナル・ビジネス・マシーンズ・コーポレーション Method and system for ordered dynamic distribution of packet flows by network processing means
JP2006135572A (en) * 2004-11-05 2006-05-25 Hitachi Ltd Traffic control in network device and its method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005519530A (en) * 2002-03-05 2005-06-30 インターナショナル・ビジネス・マシーンズ・コーポレーション Method and system for ordered dynamic distribution of packet flows by network processing means
JP2004158903A (en) * 2002-11-01 2004-06-03 Fujitsu Ltd Packet processing apparatus
JP2004260532A (en) * 2003-02-26 2004-09-16 Hitachi Ltd Network processor
JP2005117206A (en) * 2003-10-06 2005-04-28 Hitachi Ltd Network processor accelerator
JP2006135572A (en) * 2004-11-05 2006-05-25 Hitachi Ltd Traffic control in network device and its method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
JPN6010046565, W.Shi, et al., "Load Balancing for Parallel Forwarding", IEEE/ACM TRANSACTIONS ON NETWORKING, 200508, VOL. 13, NO. 4, pp.790−801 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9124540B2 (en) 2013-01-14 2015-09-01 Lenovo Enterprise Solutions (Singapore) Pte. Ltd. Caching of look-up rules based on flow heuristics to enable high speed look-up
US9477604B2 (en) 2013-01-14 2016-10-25 Lenovo Enterprise Solutions (Singapore) Pte. Ltd. Caching of look-up rules based on flow heuristics to enable high speed look-up

Also Published As

Publication number Publication date
JP4630262B2 (en) 2011-02-09

Similar Documents

Publication Publication Date Title
US7715428B2 (en) Multicore communication processing
US6854117B1 (en) Parallel network processor array
US20130304926A1 (en) Concurrent linked-list traversal for real-time hash processing in multi-core, multi-thread network processors
US9571417B2 (en) Processing resource access request in network
US9015303B2 (en) Message queue behavior optimizations
CN107135268B (en) Distributed task computing method based on information center network
US8295292B2 (en) High performance hardware linked list processors
JP2004172917A (en) Packet retrieving device, packet process retrieving method, and program
JP5672199B2 (en) Information processing apparatus, information processing method, and information processing program
US20160241482A1 (en) Packet communication apparatus and packet communication method
US11502967B2 (en) Methods and apparatuses for packet scheduling for software-defined networking in edge computing environment
US20140222900A1 (en) Method and system for processing resource requests
Islam et al. SOR-HDFS: a SEDA-based approach to maximize overlapping in RDMA-enhanced HDFS
US20160150010A1 (en) Information processing apparatus, data save method, and information processing system
JP4630262B2 (en) Cache system, cache device, packet processing device, cache method, packet processing method, cache program, and packet processing program
CN110445580A (en) Data transmission method for uplink and device, storage medium, electronic device
US20150317193A1 (en) Distributed processing apparatus, distributed processing system, and storage medium
US9736080B2 (en) Determination method, device and storage medium
US9811467B2 (en) Method and an apparatus for pre-fetching and processing work for procesor cores in a network processor
JP2009009592A (en) Congestion control method
CN111324438A (en) Request scheduling method and device, storage medium and electronic equipment
JP7335216B2 (en) TRANSFER DEVICE AND PROGRAM FOR CONTENT DISTRIBUTION SYSTEM
US20130227066A1 (en) Data transfer apparatus and data transfer method
JP5359357B2 (en) Packet processing apparatus, packet processing order control method and packet processing order control program used in the processing apparatus
JP6718397B2 (en) Router device, control method thereof, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20081225

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20100806

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20100818

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20100921

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: 20101020

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20101112

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20131119

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

LAPS Cancellation because of no payment of annual fees