Data caching apparatus, system and data processing method

By optimizing the data path through a remote data exchange device, the complexity of wiring and resource waste in the data cache of the network chip are solved, and the expansion and efficiency improvement of the data cache device are realized.

CN114741331BActive Publication Date: 2025-11-04SHENZHEN JAGUAR MICROSYSTEMS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210338140.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-01
Publication Date
2025-11-04
Estimated Expiration
2042-04-01

AI Technical Summary

Technical Problem

In existing technologies, the data cache design of network chips suffers from problems such as complex wiring, waste of resources, and excessively long data paths. This is especially true when the number of SRAMs and ports is large, leading to localized wiring congestion and timing mismatches.

Method used

A remote data exchange device is adopted, including a remote exchange controller, a write controller, a read controller, and a storage unit. The remote exchange controller determines the relationship between the ID number of the target data cache device and the ID number of the current data cache device, generates a data frame, and sends it to the adjacent or read/write controller to optimize the data path.

Benefits of technology

It reduces the physical implementation difficulty of data caching devices, reduces wiring complexity, supports multi-port and large-scale SRAM expansion, and improves data processing efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114741331B_ABST
    Figure CN114741331B_ABST
Patent Text Reader

Abstract

The application provides a data cache device, system and data processing method. The device comprises a remote exchange controller for receiving and analyzing a remote exchange command data frame, obtaining a remote exchange command and a first target address corresponding to the remote exchange command, the first target address comprising an ID number of a first target data cache device, the remote exchange controller further being configured to judge a size relationship between the ID number of the first target data cache device and an ID number of a current data cache device, generate a first data frame, and send the first data frame to a data cache device adjacent to the current data cache device or send the first data frame to a read controller or a write controller according to the judgment result, the read controller or the write controller being configured to receive and analyze the first data frame to obtain a command and execute the command. The device solves the problem that when there are too many read-write ports and the SRAM is large in size, all the ports need to be connected to the SRAM, resulting in a too large and complex connection line which is difficult to realize.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data processing, in particular to a data cache device, system and data processing method. BACKGROUND

[0002] In the processing of network chips, data packets are generally received from one or more ports, stored in the on-chip cache for processing, and then read out from the cache and forwarded to the target port after processing. The on-chip data cache is usually implemented by one or more RAMs, and its structure includes a write controller and a read controller, as well as a multiplexer for selecting and sending the read data to the target port. For example, the design of an on-chip data cache with 2 input ports and 2 output ports is shown in Figure 1 , where WriteFrom Port0 represents a data cache write request generated after receiving data from port 0, including the write address and data, WriteFrom Port1 represents a data cache write request generated after receiving data from port 1, including the write address and data, Read CmdFrom Port0 represents a data readout sending request received from port 0, including the address of the read request, Read CmdFrom Port1 represents a data readout sending request received from port 0, including the address of the read request, Read Data To Port0 represents the data read out from a group of RAMs and sent to port 0 after selection, and Read Data To Port1 represents the data read out from a group of RAMs and sent to port 1 after selection.

[0003] The design in Figure 1 has the following defects: 1. All port read and write requests need to be connected to all the SRAMs, when the number of SRAMs and ports is large, the data bus connection is too many and concentrated, which can cause local connection congestion and make back-end implementation difficult; 2. Since the timing of different port read and write to the same group of SRAMs is the same, when the data cache is large and the number of SRAMs is large, the connection to all SRAMs cannot be completed in one cycle, so D-type flip-flops need to be inserted in the read and write path to ensure that the timing can meet the requirements, at this time all read and write commands and data paths need to be aligned according to the longest path, which will waste additional resources; 3. When two ports are in different locations on the chip, the data cache with this structure can only be placed in a fixed location and cannot be close to all data ports at the same time, all port data needs to be aggregated and written into the data cache, and then read out from the centralized data cache for sending, which will introduce additional data cache and control complexity. SUMMARY

[0004] In view of the problems in the prior art, the application provides a data processing circuit, system and method to solve the congestion caused by complex implementation of data bit processing and the large number of MUX resources required in the prior art.

[0005] To solve the above problems, the application provides the following technical solutions:

[0006] The first aspect of the application provides a remote data exchange device, which comprises a remote exchange controller, a write controller, a read controller and a storage unit. The remote exchange controller is used to receive and analyze a remote exchange command data frame, and obtain at least a remote exchange command and a first target address corresponding to the remote exchange command. The remote exchange command is a first read command or a first write command, and the first target address at least comprises an ID number of a first target data cache device. The remote exchange controller is further used to judge the size relationship between the ID number of the first target data cache device and the ID number of a current data cache device, generate a first data frame according to the remote exchange command and the first target address, and send the first data frame to a data cache device adjacent to the current data cache device or to the read controller or the write controller according to the judgment result. The read controller is used to receive and analyze the first data frame, obtain the first read command and a first read address, and read data from a storage unit corresponding to the first read address. The write controller is used to receive and analyze the first data frame, obtain the first write command, first write data and a first write address, and write the first write data into a storage unit corresponding to the first write address.

[0007] Preferably, the remote exchange controller comprises a data frame parsing unit, a read-write command access address judging unit, a data frame generating unit and a path selection unit, wherein the data frame parsing unit is configured to receive and parse a remote exchange command data frame to obtain at least a remote exchange command and a first target address; the read-write command access address judging unit is configured to judge a size relationship between an ID number of the first target data cache device and an ID number of the current data cache device, output a first judging result if the ID number of the first target data cache device is equal to the ID number of the current data cache device, output a second judging result if the ID number of the first target data cache device is less than the ID number of the current data cache device, and output a third judging result if the ID number of the first target data cache device is greater than the ID number of the current data cache device; the data frame generating unit is configured to generate a first data frame according to the remote exchange command and the first target address; and the path selection unit is configured to send the first data frame to the write controller or the read controller according to the first judging result, send the first data frame to one adjacent data cache device of the current data cache device according to the second judging result, the ID number of the one adjacent data cache device being less than the ID number of the current data cache device, and send the first data frame to another adjacent data cache device according to the third judging result, the ID number of the another adjacent data cache device being greater than the ID number of the current data cache device.

[0008] Preferably, the data frame parsing unit is further configured to receive and parse a second data frame sent by the adjacent data cache device, to obtain a second command and a second target address, the second command being a second read command or a second write command, and the second target address including at least an ID number of a second target data cache device; the read / write command access address judging unit is configured to judge a size relationship between the ID number of the second target data cache device and the ID number of the current data cache device, and output a fourth judging result if the ID number of the second target data cache device is equal to the ID number of the current data cache device, a fifth judging result if the ID number of the second target data cache device is smaller than the ID number of the current data cache device, and a sixth judging result if the ID number of the second target data cache device is larger than the ID number of the current data cache device; the data frame generating unit is further configured to generate a third data frame according to the second command and the second address; and the path selecting unit is further configured to send the third data frame to the write controller or the read controller according to the fourth judging result, or to send the third data frame to the adjacent data cache device of the current data cache device according to the fifth judging result, the ID number of the adjacent data cache device being smaller than the ID number of the current data cache device, or to send the third data frame to another adjacent data cache device according to the sixth judging result, the ID number of the another adjacent data cache device being larger than the ID number of the current data cache device.

[0009] Preferably, the data frame parsing unit is further configured to receive and parse a fourth data frame sent by the another adjacent data cache device, and obtain at least a third command and a third target address, the third command being a third read command or a third write command, and the third target address comprising at least an ID number of a third target data cache device; the read-write command access address judging unit is configured to judge a size relationship between the ID number of the third target data cache device and the ID number of the current data cache device, output a seventh judging result if the ID number of the third target data cache device is equal to the ID number of the current data cache device, output an eighth judging result if the ID number of the third target data cache device is less than the ID number of the current data cache device, and output a ninth judging result if the ID number of the third target data cache device is greater than the ID number of the current data cache device; the data frame generating unit is configured to generate a fifth data frame according to the third command and the third target address; and the path selecting unit is further configured to send the fifth data frame to the write controller or the read controller according to the seventh judging result, or send the fifth data frame to an adjacent data cache device of the current data cache device according to the eighth judging result, the ID number of the adjacent data cache device being less than the ID number of the current data cache device, or send the fifth data frame to another adjacent data cache device according to the ninth judging result, the ID number of the another adjacent data cache device being greater than the ID number of the current data cache device.

[0010] Preferably, the write controller is further configured to receive and parse a sixth data frame input through a write data port of the current data cache device, obtain a fourth write command, fourth write data and a fourth write address, and send the fourth write command, fourth write data and fourth write address to the remote switch controller, wherein the fourth write address comprises at least an ID number of a fourth target data cache device; the read-write command access address judging unit is configured to judge a size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device, output a tenth judging result if the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, output an eleventh judging result if the ID number of the fourth target data cache device is less than the ID number of the current data cache device, and output a twelfth judging result if the ID number of the fourth target data cache device is greater than the ID number of the current data cache device; the data frame generating unit is further configured to generate a sixth data frame according to the fourth write command, fourth write data and fourth write address; and the path selecting unit is configured to send the sixth data frame to the write controller according to the tenth judging result, or send the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judging result, the ID number of the neighboring data cache device being less than the ID number of the current data cache device, or send the sixth data frame to another neighboring data cache device according to the twelfth judging result, the ID number of the another neighboring data cache device being greater than the ID number of the current data cache device.

[0011] Preferably, the read controller is further configured to receive and parse a seventh data frame input through a read data port of the current data cache device, obtain a fourth read command and a fourth read address, and send the fourth read command and the fourth read address to the remote switch controller, wherein the fourth read address comprises at least an ID number of a fifth target data cache device; the read-write command access address judging unit is further configured to judge a size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device, generate a thirteenth judging result if the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, generate a fourteenth judging result if the ID number of the fifth target data cache device is smaller than the ID number of the current data cache device, and generate a fifteenth judging result if the ID number of the fifth target data cache device is larger than the ID number of the current data cache device; the data frame generating unit is further configured to generate an eighth data frame according to the fourth read command and the fourth read address; and the path selecting unit is configured to send the eighth data frame to the read controller according to the thirteenth judging result, send the eighth data frame to one adjacent data cache device according to the fourteenth judging result, the ID number of the one adjacent data cache device being smaller than the ID number of the current data cache device, and send the eighth data frame to another adjacent data cache device according to the fifteenth judging result, the ID number of the another adjacent data cache device being larger than the ID number of the current data cache device.

[0012] Preferably, the path selection unit comprises a first multiplexer, a second multiplexer and a third multiplexer, a first input end of the first multiplexer is connected with the first data frame output end, a second input end of the first multiplexer is connected with the fifth data frame output end, a third input end of the first multiplexer is connected with the sixth data frame output end, a fourth input end of the first multiplexer is connected with the eighth data frame output end, a control signal input end of the first multiplexer is connected with the first judgment result output end, the fourth judgment result output end, the seventh judgment result output end, the tenth judgment result output end and the thirteenth judgment result output end of the read-write command access address judgment unit respectively, and an output end of the first multiplexer is connected with a data frame analysis unit input end of a neighboring data buffer device of the current data buffer device; a first input end of the second multiplexer is connected with the eighth data frame output end, a second input end of the second multiplexer is connected with the third data frame output end, a third input end of the second multiplexer is connected with the sixth data frame output end, a fourth input end of the second multiplexer is connected with the first data frame output end, a control signal input end of the second multiplexer is connected with the second judgment result output end, the fifth judgment result output end, the eighth judgment result output end, the eleventh judgment result output end and the fourteenth judgment result output end of the read-write command access address judgment unit respectively, and an output end of the second multiplexer is connected with a data frame analysis unit input end of another neighboring data buffer device; a first input end of the third multiplexer is connected with the eighth data frame output end, a second input end of the third multiplexer is connected with the sixth data frame output end, a third input end of the third multiplexer is connected with the third data frame output end, a fourth input end of the third multiplexer is connected with the first data frame output end, a control signal input end of the third multiplexer is connected with the third judgment result output end, the sixth judgment result output end, the ninth judgment result output end, the twelfth judgment result output end and the fifteenth judgment result output end of the read-write command access address judgment unit respectively, and a control signal output end of the third multiplexer is connected with input ends of the read controller and the write controller.

[0013] The second aspect of the present application provides a data buffer system, which comprises a D-type flip-flop and at least two data buffer devices as described above, and the D-type flip-flop is connected between two neighboring data buffer devices.

[0014] The third aspect of the present application provides a method for data processing using the data cache device, comprising the following steps: a remote exchange controller receives and parses a remote exchange command data frame to obtain at least a remote exchange command and a first target address corresponding to the remote exchange command, wherein the remote exchange command is a first read command or a first write command, and the first target address comprises at least an ID number of a first target data cache device; the remote exchange controller judges the size relationship between the ID number of the first target data cache device and the ID number of a current data cache device, generates a first data frame according to the remote exchange command and the first target address, and sends the first data frame to a data cache device adjacent to the current data cache device or to the read controller or the write controller according to the judgment result; if the remote exchange controller sends the first data frame to the write controller, the write controller receives and parses the first data frame to obtain the first write command, first write data and a first write address, and writes the first write data into a storage unit corresponding to the first write address; if the remote exchange controller sends the first data frame to the read controller, the read controller receives and parses the first data frame to obtain the first read command and a first read address, and reads data from a storage unit corresponding to the first read address.

[0015] Preferably, the remote exchange controller judges the size relation between the ID number of the first target data cache device and the ID number of the current data cache device, and generates a first data frame according to the remote exchange command and the first target address, and sends the first data frame to a data cache device adjacent to the current data cache device or to the read controller or the write controller according to the judging result: a data frame parsing unit receives and parses a remote exchange command data frame, and obtains at least a remote exchange command and a first target address; a read-write command access address judging unit judges the size relation between the ID number of the first target data cache device and the ID number of the current data cache device, and outputs a first judging result if the ID number of the first target data cache device is equal to the ID number of the current data cache device, a second judging result if the ID number of the first target data cache device is less than the ID number of the current data cache device, and a third judging result if the ID number of the first target data cache device is greater than the ID number of the current data cache device; and a data frame generating unit generates a first data frame according to the remote exchange command and the first target address; a path selecting unit sends the first data frame to the write controller or the read controller according to the first judging result, to a neighboring data cache device of the current data cache device according to the second judging result, the ID number of the neighboring data cache device being less than the ID number of the current data cache device, and to another data cache device according to the third judging result, the ID number of the another data cache device being greater than the ID number of the current data cache device.

[0016] Preferably, the method further comprises: the data frame parsing unit receiving and parsing a second data frame sent by the adjacent data cache device, obtaining a second command and a second target address, the second command being a second read command or a second write command, and the second target address comprising at least an ID number of a second target data cache device; the read-write command access address judging unit judging a size relationship between the ID number of the second target data cache device and the ID number of the current data cache device, outputting a fourth judging result if the ID number of the second target data cache device is equal to the ID number of the current data cache device, outputting a fifth judging result if the ID number of the second target data cache device is smaller than the ID number of the current data cache device, and outputting a sixth judging result if the ID number of the second target data cache device is larger than the ID number of the current data cache device; the data frame generating unit generating a third data frame according to the second command and the second address; and the path selecting unit sending the third data frame to the write controller or the read controller according to the fourth judging result, or sending the third data frame to the adjacent data cache device whose ID number is smaller than the ID number of the current data cache device according to the fifth judging result, or sending the third data frame to another adjacent data cache device whose ID number is larger than the ID number of the current data cache device according to the sixth judging result.

[0017] Preferably, the method further comprises: the data frame parsing unit receiving and parsing a fourth data frame sent by the another adjacent data cache device, and obtaining at least a third command and a third target address, the third command being a third read command or a third write command, and the third target address comprising at least an ID number of a third target data cache device; the read-write command access address judging unit judging a size relation between the ID number of the third target data cache device and the ID number of the current data cache device, outputting a seventh judging result if the ID number of the third target data cache device is equal to the ID number of the current data cache device, outputting an eighth judging result if the ID number of the third target data cache device is smaller than the ID number of the current data cache device, and outputting a ninth judging result if the ID number of the third target data cache device is larger than the ID number of the current data cache device; the data frame generating unit generating a fifth data frame according to the third command and the third target address; and the path selecting unit sending the fifth data frame to the write controller or the read controller according to the seventh judging result, or sending the fifth data frame to an adjacent data cache device of the current data cache device according to the eighth judging result, the ID number of the adjacent data cache device being smaller than the ID number of the current data cache device, or sending the fifth data frame to another adjacent data cache device according to the ninth judging result, the ID number of the another adjacent data cache device being larger than the ID number of the current data cache device.

[0018] Preferably, the method further comprises: the write controller receiving and parsing a sixth data frame input through a write data port of the current data cache device, obtaining a fourth write command, fourth write data and a fourth write address, and sending the fourth write command, fourth write data and fourth write address to the remote switching controller, wherein the fourth write address at least comprises an ID number of a fourth target data cache device; the read-write command access address judging unit judging a size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device, outputting a tenth judging result if the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, outputting an eleventh judging result if the ID number of the fourth target data cache device is less than the ID number of the current data cache device, and outputting a twelfth judging result if the ID number of the fourth target data cache device is greater than the ID number of the current data cache device; the data frame generating unit generating a sixth data frame according to the fourth write command, fourth write data and fourth write address; the path selecting unit sending the sixth data frame to the write controller according to the tenth judging result, or sending the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judging result, the ID number of the neighboring data cache device being less than the ID number of the current data cache device, or sending the sixth data frame to another neighboring data cache device according to the twelfth judging result, the ID number of the another neighboring data cache device being greater than the ID number of the current data cache device.

[0019] Preferably, the method further comprises: the read controller receiving and parsing a seventh data frame input through a read data port of the current data cache device, obtaining a fourth read command and a fourth read address, and sending the fourth read command and the fourth read address to the remote switching controller, wherein the fourth read address at least comprises an ID number of a fifth target data cache device; the read-write command access address judgment unit judging a size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device, generating a thirteenth judgment result if the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, generating a fourteenth judgment result if the ID number of the fifth target data cache device is less than the ID number of the current data cache device, and generating a fifteenth judgment result if the ID number of the fifth target cache device is greater than the ID number of the current data cache device; the data frame generation unit generating an eighth data frame according to the fourth read command and the fourth read address; the path selection unit sending the eighth data frame to the read controller according to the thirteenth judgment result, sending the eighth data frame to one adjacent data cache device according to the fourteenth judgment result, the ID number of the one adjacent data cache device being less than the ID number of the current data cache device, and sending the eighth data frame to another adjacent data cache device according to the fifteenth judgment result, the ID number of the another adjacent data cache device being greater than the ID number of the current data cache device.

[0020] The data cache device has the advantages that: the SRAM inside the data cache device is selected according to the process performance to have a proper size, and the difficulty of physical implementation is reduced; when the read-write port is too many or the SRAM size is large, all the data of the port needs to be connected to all the SRAM, which causes the connection to be too large and complex to be implemented; and the data cache device is suitable for expansion of the data cache capacity and the read-write port size, and when the read-write specification of multiple ports needs to be supported or the SRAM size is larger, the multiple data cache devices are directly interconnected to be implemented. BRIEF DESCRIPTION OF DRAWINGS

[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description are some embodiments of the present application, and for those skilled in the art, other drawings can also be obtained without creative labor,

[0022] Figure 1 It is a structural schematic diagram of the data cache device in the prior art;

[0023] Figure 2 This is a schematic diagram of the data caching device according to Embodiment 1 of the present invention;

[0024] Figure 3 This is a schematic diagram of the structure of the remote data exchange controller according to Embodiment 1 of the present invention;

[0025] Figure 4 This is a schematic diagram of the data caching system according to Embodiment 2 of the present invention;

[0026] Figure 5 This is a flowchart illustrating a data processing method according to Embodiment 3 of the present invention. Detailed Implementation

[0027] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0028] Embodiment 1 of the present invention provides a data caching device, such as... Figure 2 As shown, the data caching device includes a write controller, a read controller, a storage unit, and a remote switching controller. The remote switching controller is used to receive and parse remote switching command data frames, and obtain at least the remote switching command and the first target address corresponding to the remote switching command. The remote switching command is either a first read command or a first write command. The first target address includes at least the ID number of the first target data caching device. The remote switching controller is also used to determine the size relationship between the ID number of the first target data caching device and the ID number of the current data caching device, and generate a first data frame according to the remote switching command and the first target address. Based on the determination result, the first data frame is forwarded to the data caching device adjacent to the current data caching device or sent to the read controller or the write controller. The read controller is used to receive and parse the first data frame, obtain the first read command and the first read address, and read data from the storage unit corresponding to the first read address. The write controller is used to receive and parse the first data frame, obtain the first write command, the first write data, and the first write address, and write the first write data into the storage unit corresponding to the first write address.

[0029] In one embodiment, the first target address includes the ID number of the data cache device where the corresponding memory unit is located, the ID number of the memory unit SRAM, and the offset in the SRAM. For example, assuming the target address is {2, 2, 3}, it indicates that the target address is the address of the offset 3 in the SRAM unit with ID number 2 in the data cache device with ID number 2.

[0030] In one embodiment, the control command further includes a command sequence number, which indicates the number of the command currently processed by the read controller or the write controller, so as to avoid errors in reading data or writing data.

[0031] For example, five commands numbered 1, 2, 3, 4, and 5 are continuously sent, and the corresponding data are defined as A, B, C, D, and E. The data read by the continuously sent commands have a sequence requirement, and thus the command sequence number is required to ensure the sequence of the output data. Assuming that command 1 corresponds to the first data cache device, the data are read from the first data cache device, the data are output from the first data cache device, the path is the shortest, and the data A return in the shortest time. Commands 2 and 3 correspond to reading the third data cache device, the path is the longest, and the data BC return in the longest time. Commands 4 and 5 correspond to reading the second data cache device, the path is longer than that of command 1 and shorter than that of commands 2 and 3, and the data DE return in a time between reading the first data cache and the third data cache. Thus, the received data sequence is A (command number 1), D (command number 4), E (command number 5), B (command number 2), and C (command number 3). When the data are sent, the corresponding command numbers 1-5 are used to send the data in sequence, and the continuous A, B, C, D, and E five data outputs are obtained.

[0032] For example, five commands numbered 1, 2, 3, 4, and 5 are continuously sent, and the corresponding data are defined as A, B, C, D, and E. The data read by the continuously sent commands have a sequence requirement, and thus the command sequence number is required to ensure the sequence of the output data. Assuming that command 1 corresponds to the first data cache device, the data are read from the first data cache device, the data are output from the first data cache device, the path is the shortest, and the data A return in the shortest time. Commands 2 and 3 correspond to reading the third data cache device, the path is the longest, and the data BC return in the longest time. Commands 4 and 5 correspond to reading the second data cache device, the path is longer than that of command 1 and shorter than that of commands 2 and 3, and the data DE return in a time between reading the first data cache and the third data cache. Thus, the received data sequence is A (command number 1), D (command number 4), E (command number 5), B (command number 2), and C (command number 3). When the data are sent, the corresponding command numbers 1-5 are used to send the data in sequence, and the continuous A, B, C, D, and E five data outputs are obtained. Figure 3As shown, the remote exchange controller comprises a data frame parsing unit, a read-write command access address judging unit, a data frame generating unit and a path selecting unit. The data frame parsing unit is configured to receive and parse a remote exchange command data frame to obtain at least a remote exchange command and a first target address. The read-write command access address judging unit is configured to judge the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device. If the ID number of the first target data cache device is equal to the ID number of the current data cache device, a first judging result is outputted. If the ID number of the first target data cache device is less than the ID number of the current data cache device, a second judging result is outputted. If the ID number of the first target data cache device is greater than the ID number of the current data cache device, a third judging result is outputted. The data frame generating unit is configured to generate a first data frame according to the remote exchange command and the first target address. The path selecting unit is configured to send the first data frame to the read controller or the write controller according to the first judging result, to send the first data frame to one adjacent data cache device of the current data cache device according to the second judging result, the ID number of the one adjacent data cache device being one less than the ID number of the current data cache device, and to send the first data frame to another adjacent data cache device of the current data cache device according to the third judging result, the ID number of the another adjacent data cache device being one greater than the ID number of the current data cache device.

[0033] Specifically, when the read-write command access address judging unit outputs the first judging result, if the remote exchange command is a first read command, the first data frame is sent to the read controller, and if the remote exchange command is a first write command, the first data frame is sent to the write controller. When the read-write command access address judging unit outputs the second judging result, the first data frame is sent to the one adjacent data frame. When the read-write command access address judging unit outputs the third judging result, the first data frame is sent to the another adjacent data frame.

[0034] In one embodiment, the one adjacent data cache device is the left data cache device of the current data cache device, and the ID number of the one adjacent data cache device is one less than the ID number of the current data cache device. The another adjacent data cache device is the right data cache device of the current data cache device, and the ID number of the another adjacent data cache device is one greater than the ID number of the current data cache device.

[0035] Specifically, the first target address comprises the ID number of the first target data cache device, the ID number of a target SRAM in the first target data cache device, and the offset of the storage address in the target SRAM.

[0036] In an embodiment, the data frame parsing unit is further configured to receive and parse a second data frame sent by the adjacent data cache device, and obtain a second command and a second target address, wherein the second command is a second read command or a second write command, and the second target address comprises at least an ID number of a second target data cache device. The read / write command access address judging unit is configured to judge a size relationship between the ID number of the second target data cache device and the ID number of the current data cache device, and output a fourth judging result if the ID number of the second target data cache device is equal to the ID number of the current data cache device, a fifth judging result if the ID number of the second target data cache device is less than the ID number of the current data cache device, or a sixth judging result if the ID number of the second target data cache device is greater than the ID number of the current data cache device. The data frame generating unit is further configured to generate a third data frame according to the second command and the second address. The path selecting unit is configured to send the third data frame to the write controller or the read controller according to the fourth judging result, or send the third data frame to an adjacent data cache device of the current data cache device according to the fifth judging result, wherein the ID number of the adjacent data cache device is 1 different from the ID number of the current data cache device, or send the third data frame to another adjacent data cache device according to the sixth judging result, wherein the ID number of the another adjacent data cache device is greater than the ID number of the current data cache device.

[0037] In an embodiment, the data frame parsing unit is further configured to receive and parse a fourth data frame sent by the another adjacent data cache device, and obtain at least a third command and a third target address, wherein the third target address comprises at least an ID number of a third target data cache device. The read / write command access address judging unit is further configured to judge a size relationship between the ID number of the third target data cache device and the ID number of the current data cache device, and output a seventh judging result if the ID number of the third target data cache device is equal to the ID number of the current data cache device, an eighth judging result if the ID number of the third target data cache device is less than the ID number of the current data cache device, or a ninth judging result if the ID number of the third target data cache device is greater than the ID number of the current data cache device. The path selecting unit is configured to send a fifth data frame to the write controller or the read controller according to the seventh judging result, or send the fifth data frame to an adjacent data cache device of the current data cache device according to the eighth judging result, or send the fifth data frame to the another adjacent data cache device according to the ninth judging result, wherein the ID number of the another adjacent data cache device is greater than the ID number of the current data cache device.

[0038] In one embodiment, the write controller is further configured to receive and parse a sixth data frame input through a write data port of the current data cache device, obtain a fourth write command, fourth write data and a fourth write address, and send the fourth write command, fourth write data and fourth write address to the remote switch controller, wherein the write address comprises at least an ID number of a second data cache device in which a target memory unit is located, the read / write command access address judging unit is configured to judge a size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device, output a tenth judging result if the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, output an eleventh judging result if the ID number of the fourth target data cache device is smaller than the ID number of the current data cache device, and output a twelfth judging result if the ID number of the fourth target data cache device is larger than the ID number of the current data cache device, the data frame generating unit is further configured to generate a sixth data frame according to the fourth write command, fourth write data and fourth write address, and the path selecting unit is configured to send the sixth data frame to the write controller according to the tenth judging result, or send the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judging result, and send the sixth data frame to another neighboring data cache device according to the twelfth judging result, the ID number of the another neighboring data cache device being larger than the ID number of the current data cache device.

[0039] In one embodiment, the read controller is further configured to receive and parse a seventh data frame input through a read data port of the current data cache device, obtain a fourth read command and a fourth read address, and send the fourth read command and fourth read address to the remote switch controller, wherein the fourth read address comprises at least an ID number of a fifth target data cache device, the read / write command access address judging unit is configured to judge a size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device, generate a thirteenth judging result if the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, generate a fourteenth judging result if the ID number of the fifth target data cache device is smaller than the ID number of the current data cache device, and generate a fifteenth judging result if the ID number of the fifth target data cache device is larger than the ID number of the current data cache device, the data frame generating unit is further configured to generate an eighth data frame according to the fourth read command and fourth read address, and the path selecting unit is configured to send the eighth data frame to the read controller according to the thirteenth judging result, send the eighth data frame to the neighboring data cache device according to the fourteenth judging result, the ID number of the neighboring data cache device being smaller than the ID number of the current data cache device, and send the eighth data frame to the another neighboring data cache device according to the fifteenth judging result, the ID number of the another neighboring data cache device being larger than the ID number of the current data cache device.

[0040] In one embodiment, the path selection unit comprises a first multiplexer, a second multiplexer, and a third multiplexer. The first input terminal of the first multiplexer is connected to the first data frame output terminal. The second input terminal of the first multiplexer is connected to the fifth data frame output terminal. The third input terminal of the first multiplexer is connected to the sixth data frame output terminal. The fourth input terminal of the first multiplexer is connected to the eighth data frame output terminal. The control signal input terminal of the first multiplexer is connected to the first judgment result output terminal, the fourth judgment result output terminal, the seventh judgment result output terminal, the tenth judgment result output terminal, and the thirteenth judgment result output terminal of the read / write command access address judgment unit, respectively. The output terminal of the first multiplexer is connected to the data frame analysis unit input terminal of the adjacent data buffer device of the current data buffer device. The first input terminal of the second multiplexer is connected to the eighth data frame output terminal. The second input terminal of the second multiplexer is connected to the third data frame output terminal. The third input terminal of the second multiplexer is connected to the sixth data frame output terminal. The fourth input terminal of the second multiplexer is connected to the first data frame output terminal. The control signal input terminal of the second multiplexer is connected to the second judgment result output terminal, the fifth judgment result output terminal, the eighth judgment result output terminal, the eleventh judgment result output terminal, and the fourteenth judgment result output terminal of the read / write command access address judgment unit, respectively. The output terminal of the second multiplexer is connected to the data frame analysis unit input terminal of the other adjacent data buffer device. The first input terminal of the third multiplexer is connected to the eighth data frame output terminal. The second input terminal of the third multiplexer is connected to the sixth data frame output terminal. The third input terminal of the third multiplexer is connected to the third data frame output terminal. The fourth input terminal of the third multiplexer is connected to the first data frame output terminal. The control signal input terminal of the third multiplexer is connected to the third judgment result output terminal, the sixth judgment result output terminal, the ninth judgment result output terminal, the twelfth judgment result output terminal, and the fifteenth judgment result output terminal of the read / write command access address judgment unit, respectively. The control signal output terminal of the third multiplexer is connected to the input terminal of the read controller and the write controller.

[0041] The data caching device in Embodiment 1 of this invention supports only one external data exchange command interface and read / write operations on one port. The internal SRAM is selected to a suitable size based on process performance, reducing the difficulty of physical implementation. This data caching device solves the problem that when there are too many read / write ports or a large SRAM size, all port data needs to be connected to all SRAMs, resulting in excessively large and complex wiring. Furthermore, the data caching device of this embodiment is suitable for expanding the data cache capacity and read / write port size. When supporting multiple port read / write specifications or larger SRAM specifications is required, it can be achieved by directly interconnecting multiple such data caching devices. It reduces the distance between port data transmission and reception read / write caches, lowers write latency and read overshoot. By deploying the data caching device near the corresponding port, received data can be written quickly, and data to be sent can be read nearby. The amount of overshoot along the path is very small, eliminating the need for additional caching. It supports data exchange between different ports or processing units, allowing data to be processed locally, thereby improving the data processing efficiency of multi-processor unit systems.

[0042] Embodiment 2 of the present invention provides a data caching system, such as Figure 4 As shown, the data caching system includes at least two of the aforementioned data caching devices and a plurality of Class D triggers, wherein the at least two data caching devices are cascaded through the plurality of Class D triggers.

[0043] Specifically, the first command sending end of the current data cache device is connected to the second command receiving end of the previous data cache device through a Class D flip-flop; the second command sending end of the current data cache device is connected to the first receiving end of another adjacent data cache device through a Class D flip-flop; the first command receiving end of the current data cache device is connected to the second command sending end of the previous data cache device through a Class D flip-flop; and the second command receiving end of the current data cache device is connected to the first command sending end of another data cache device through a Class D flip-flop.

[0044] It should be noted that the data caching system is not limited to two data caching devices. When there are multiple data caching devices, adjacent data caching devices are connected through a Class D trigger.

[0045] The data cache system of the embodiment one of the application, the data cache device only supports 1-port read and write, and 1 external data exchange command interface, the internal SRAM selects a suitable scale according to the process performance, and the difficulty of physical implementation is reduced, the data cache device solves the problem that when the read and write ports are too many or the SRAM scale is large, all the ports need to be connected to all the SRAM, resulting in too large and complex connection lines and difficult to implement. In addition, the data cache device of the embodiment is suitable for expansion of the data cache capacity and the read and write port scale, when the read and write specifications of multiple ports need to be supported, or a larger SRAM specification is needed, the multiple data cache devices are directly interconnected to realize. The distance of the read and write cache of the port transceiver is reduced, the write delay and read overflow are reduced, by deploying the data cache device near the corresponding port, the received data can be quickly written, the data to be sent can be read nearby, the overflow quantity on the path is small, no additional cache is needed, the data exchange between different ports or processing units is supported, the data to be processed is exchanged to the local processing, and the data processing efficiency of the multi-processing unit system can be improved.

[0046] Based on the embodiment one of the application, the embodiment three of the application provides a method for data processing by using the data cache device, as shown in the method, the method comprises the following steps of: Figure 5

[0047] S1, a remote exchange controller receives and analyzes a remote exchange command data frame, and at least obtains a remote exchange command and a first target address corresponding to the remote exchange command, wherein the remote exchange command is a first read command or a first write command, and the first target address at least includes an ID number of a first target data cache device;

[0048] S2, a remote exchange controller receives and analyzes a remote exchange command data frame, and at least obtains a remote exchange command and a first target address corresponding to the remote exchange command, wherein the remote exchange command is a first read command or a first write command, and the first target address at least includes an ID number of a first target data cache device.

[0049] S3, the remote exchange controller judges the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device, generates a first data frame according to the remote exchange command and the first target address, and sends the first data frame to a data cache device adjacent to the current data cache device or sends the first data frame to the read controller or the write controller according to the judgment result.

[0050] ​S4, if the remote exchange controller sends the first data frame to the write controller, the write controller receives and parses the first data frame to obtain the first write command, first write data and first write address, and writes the first write data into the storage unit corresponding to the first write address; if the remote exchange controller sends the first data frame to the read controller, the read controller receives and parses the first data frame to obtain the first read command and first read address, and reads data from the storage unit corresponding to the first read address.

[0051] Specifically, the data frame parsing unit receives and parses the remote exchange command data frame to obtain at least the remote exchange command and first target address, the read-write command access address judging unit judges the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device, outputs a first judging result if the ID number of the first target data cache device is equal to the ID number of the current data cache device, outputs a second judging result if the ID number of the first target data cache device is less than the ID number of the current data cache device, and outputs a third judging result if the ID number of the first target data cache device is greater than the ID number of the current data cache device, the data frame generating unit generates a first data frame according to the remote exchange command and first target address, the path selecting unit sends the first data frame to the write controller according to the first judging result, sends the first data frame to one adjacent data cache device of the current data cache device according to the second judging result, the ID number of the adjacent data cache device being less than the ID number of the current data cache device, and sends the first data frame to another data cache device according to the third judging result, the ID number of the another data cache device being greater than the ID number of the current data cache device.

[0052] Specifically, the read-write command access address judging unit judges the size relation between the ID number of the second target data cache device and the ID number of the current data cache device, outputs a fourth judging result if the ID number of the second target data cache device is equal to the ID number of the current data cache device, outputs a fifth judging result if the ID number of the second target data cache device is less than the ID number of the current data cache device, and outputs a sixth judging result if the ID number of the second target data cache device is greater than the ID number of the current data cache device. The data frame generating unit generates a third data frame according to the second command and the second address. The path selecting unit sends the third data frame to the write controller or the read controller according to the fourth judging result, or sends the third data frame to one adjacent data cache device of the current data cache device according to the fifth judging result, the ID number of the one adjacent data cache device being less than the ID number of the current data cache device, or sends the third data frame to another adjacent data cache device according to the sixth judging result, the ID number of the another adjacent data cache device being greater than the ID number of the current data cache device.

[0053] Specifically, the data frame analyzing unit receives and analyzes a fourth data frame sent by the another adjacent data cache device, and obtains at least a third command and a third target address. The third command is a third read command or a third write command, and the third target address includes at least the ID number of a third target data cache device. The read-write command access address judging unit judges the size relation between the ID number of the third target data cache device and the ID number of the current data cache device, outputs a seventh judging result if the ID number of the third target data cache device is equal to the ID number of the current data cache device, outputs an eighth judging result if the ID number of the third target data cache device is less than the ID number of the current data cache device, and outputs a ninth judging result if the ID number of the third target data cache device is greater than the ID number of the current data cache device. The data frame generating unit generates a fifth data frame according to the third command and the third target address. The path selecting unit sends the fifth data frame to the write controller or the read controller according to the seventh judging result, or sends the fifth data frame to one adjacent data cache device of the current data cache device according to the eighth judging result, the ID number of the one adjacent data cache device being less than the ID number of the current data cache device, or sends the fifth data frame to another adjacent data cache device according to the ninth judging result, the ID number of the another adjacent data cache device being greater than the ID number of the current data cache device.

[0054] Specifically, the write controller receives and parses a sixth data frame input through a write data port of the current data cache device, obtains a fourth write command, fourth write data and a fourth write address, and sends the fourth write command, fourth write data and fourth write address to the remote switch controller, wherein the fourth write address at least includes an ID number of a fourth target data cache device, the read-write command access address judging unit judges a size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device, if the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, a tenth judging result is output, if the ID number of the fourth target data cache device is less than the ID number of the current data cache device, an eleventh judging result is output, if the ID number of the fourth target data cache device is greater than the ID number of the current data cache device, a twelfth judging result is output, the data frame generating unit generates a sixth data frame according to the fourth write command, fourth write data and fourth write address, the path selecting unit sends the sixth data frame to the write controller according to the tenth judging result, or sends the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judging result, the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or sends the sixth data frame to another neighboring data cache device according to the twelfth judging result, the ID number of the another neighboring data cache device is greater than the ID number of the current data cache device.

[0055] Specifically, the read controller receives and parses a seventh data frame input through a read data port of the current data cache device, obtains a fourth read command and a fourth read address, and sends the fourth read command and the fourth read address to the remote switch controller, wherein the fourth read address at least includes an ID number of a fifth target data cache device, the read-write command access address judging unit judges a size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device, if the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, a thirteenth judging result is generated, if the ID number of the fifth target data cache device is less than the ID number of the current data cache device, a fourteenth judging result is generated, if the ID number of the fifth target data cache device is greater than the ID number of the current data cache device, a fifteenth judging result is generated, the data frame generating unit generates an eighth data frame according to the fourth read command and the fourth read address, the path selecting unit sends the eighth data frame to the read controller according to the thirteenth judging result, and is further used for sending the eighth data frame to the one adjacent data cache device according to the fourteenth judging result, the ID number of the one adjacent data cache device is less than the ID number of the current data cache device, and is further used for sending the eighth data frame to the other adjacent data cache device according to the fifteenth judging result, the ID number of the other adjacent data cache device is greater than the ID number of the current data cache device.

[0056] For example, it is assumed that the remote switch command is to write data data1 into the second data cache device, the ID number of the current data cache device is 0, and the ID number of the first data cache device is 1, the ID number of the second data cache device is 2, and the ID number of the third data cache device is 3. Figure 4The remote exchange command is a write data data1, the command sequence number is 7, the remote exchange command address is {Dbuf 2Sram 2 offset 2}, wherein the remote exchange command address indicates that the write data is stored in the data buffer device with ID number 2, in the second Sram unit, at the position with offset 2, the current data buffer device with ID number 0 receives the remote exchange command and the remote exchange command address, since the ID number 2 of the first target data buffer device is greater than the ID number 0 of the current data buffer device, the data buffer device with ID number 0 forwards the remote exchange command to the data buffer device with ID number 1, the data buffer device with ID number 1 receives and analyzes the remote exchange command data frame, obtains the ID number 2 of the target data buffer device corresponding to the remote exchange command address, and thus sends the remote exchange command data frame to the data buffer device with ID number 2, the data buffer device with ID number 2 judges the data buffer device ID numbers of the target data buffer device and itself, since the two are equal, the data buffer device with ID number 2 sends the remote exchange command data frame to the write controller in the data buffer device with ID number 2, the write controller receives and analyzes the data frame to obtain the write data and the write address, and writes the write data into the corresponding write address.

[0057] For example, assuming that the command input through the read data port of the current data cache device is to read data, the corresponding command sequence number is 8, and the read address is {Dbuf 2Sram2 offset2}, that is, the ID number of the target data cache device is 2, and the ID number of the current data cache device is 0, the current data cache device receives the read command data frame, parses the read command data frame to obtain the read command and the read address, the read-write command access address judgment unit of the current data cache device judges that the ID number of the target data cache device is greater than the ID number of itself, and sends the read command data frame to the data cache device with the ID number of 1, the data cache device with the ID number of 1 receives and parses the read command data frame to obtain the ID number of the target data cache device, and judges the size of the ID number of itself and the ID number of the target data cache device, since the ID number of the target data cache device is greater than the ID number of itself, the read command data frame is sent to the data cache device with the ID number of 2, the data cache device with the ID number of 2 judges that the ID number of itself is equal to the ID number of the target data cache device, and thus sends the read data frame to the read controller of itself, the read controller receives and parses the data frame to obtain the target address, and reads data from the corresponding storage unit. After reading the data, the read data needs to be sent to the data cache device with the ID number of 0, and thus after returning the read data to the data cache device with the ID number of 0, in the returning process, the data cache device with the ID number of 0 is the target data cache device, when the data cache device with the ID number of 2 reads the data, since the ID number of the current target data cache device is 0, the data cache device with the ID number of 2 judges that the ID number of itself is greater than 0, and sends the read data and the write command to the data cache device with the ID number of 1, the data cache device with the ID number of 1 performs the same judgment, and sends the read data and the write address to the data cache device with the ID number of 0, the data cache device with the ID number of 0 judges after the read data and the write command are sent to the write controller of itself, and the write controller writes the write data into the corresponding write address.

[0058] The principles and implementation manners of the present application are described by using specific embodiments, and the above embodiment descriptions are only used to help understand the method and core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation manners and application ranges will be changed, and the above descriptions should not be understood as limitations of the present application.

Claims

1. A data caching device, characterized in that, The data caching device includes a remote switching controller, a write controller, a read controller, and a storage unit. The remote switching controller is used to receive and parse remote switching command data frames, and at least obtain the remote switching command and the first target address corresponding to the remote switching command, wherein the remote switching command is a first read command or a first write command, and the first target address includes at least the ID number of the first target data cache device. The remote switching controller is also used to determine the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device, and generate a first data frame according to the remote switching command and the first target address, and send the first data frame to the data cache device adjacent to the current data cache device or to the read controller or write controller according to the determination result. The read controller is used to receive and parse the first data frame, obtain the first read command and the first read address, and read data from the storage unit corresponding to the first read address according to the first read command; The write controller is used to receive and parse the first data frame to obtain the first write command, the first write data and the first write address, and write the first write data into the storage unit corresponding to the first write address according to the first write command; When the first data frame is sent to the data cache device adjacent to the current data cache device according to the judgment result, and the remote exchange command is the first read command, the remote exchange controller is also used to receive the read data sent by the adjacent data cache device.

2. The data caching device according to claim 1, characterized in that, The remote switching controller includes a data frame parsing unit, a read / write command access address determination unit, a data frame generation unit, and a path selection unit, wherein... The data frame parsing unit is used to receive and parse remote exchange command data frames, obtaining at least the remote exchange command and the first destination address. The read / write command access address determination unit is used to determine the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device. If the ID number of the first target data cache device is equal to the ID number of the current data cache device, a first determination result is output; if the ID number of the first target data cache device is less than the ID number of the current data cache device, a second determination result is output; and if the ID number of the first target data cache device is greater than the ID number of the current data cache device, a third determination result is output. A data frame generation unit is used to generate a first data frame based on the remote exchange command and the first target address; The path selection unit is used to send the first data frame to the write controller or read controller according to the first judgment result, and is also used to send the first data frame to a neighboring data cache device of the current data cache device according to the second judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, and is also used to send the first data frame to another neighboring data cache device according to the third judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

3. The data caching device according to claim 2, characterized in that: The data frame parsing unit is also used to receive and parse the second data frame sent by the adjacent data buffer device to obtain the second command and the second target address. The second command is a second read command or a second write command, and the second target address includes at least the ID number of the second target data buffer device. The read / write command access address determination unit is used to determine the size relationship between the ID number of the second target data cache device and the ID number of the current data cache device. If the ID number of the second target data cache device is equal to the ID number of the current data cache device, a fourth determination result is output; if the ID number of the second target data cache device is less than the ID number of the current data cache device, a fifth determination result is output; and if the ID number of the second target data cache device is greater than the ID number of the current data cache device, a sixth determination result is output. The data frame generation unit is also configured to generate a third data frame based on the second command and the second address; The path selection unit is further configured to send the third data frame to the write controller or read controller according to the fourth judgment result, or to send the third data frame to a neighboring data cache device of the current data cache device according to the fifth judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or to send the third data frame to another neighboring data cache device according to the sixth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

4. The data caching device according to claim 3, characterized in that: The data frame parsing unit is also used to receive and parse the fourth data frame sent by the other adjacent data buffer device, and to obtain at least the third command and the third target address. The third command is a third read command or a third write command, and the third target address includes at least the ID number of the third target data buffer device. The read / write command access address determination unit is used to determine the size relationship between the ID number of the third target data cache device and the ID number of the current data cache device. If the ID number of the third target data cache device is equal to the ID number of the current data cache device, the seventh determination result is output. If the ID number of the third target data cache device is less than the ID number of the current data cache device, the eighth determination result is output. If the ID number of the third target data cache device is greater than the ID number of the current data cache device, the ninth determination result is output. The data frame generation unit is used to generate a fifth data frame according to the third command and the third target address; The path selection unit is further configured to send the fifth data frame to the write controller or read controller according to the seventh judgment result, or to send the fifth data frame to a neighboring data cache device of the current data cache device according to the eighth judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or to send the fifth data frame to another neighboring data cache device according to the ninth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

5. The data caching device according to claim 4, characterized in that: The write controller is also configured to receive and parse the sixth data frame input through the write data port of the current data cache device, obtain the fourth write command, the fourth write data and the fourth write address, and send the fourth write command, the fourth write data and the fourth write address to the remote switching controller, wherein the fourth write address includes at least the ID number of the fourth target data cache device; The read / write command access address judgment unit is used to judge the size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device. If the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, the tenth judgment result is output. If the ID number of the fourth target data cache device is less than the ID number of the current data cache device, the eleventh judgment result is output. If the ID number of the fourth target data cache device is greater than the ID number of the current data cache device, the twelfth judgment result is output. The data frame generation unit is also used to generate a sixth data frame based on the fourth write command, the fourth write data and the fourth write address; The path selection unit is used to send the sixth data frame to the write controller according to the tenth judgment result, or to send the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or to send the sixth data frame to another neighboring data cache device according to the twelfth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

6. The data caching device according to claim 5, characterized in that: The read controller is also configured to receive and parse the seventh data frame input through the read data port of the current data buffer device, obtain the fourth read command and the fourth read address, and send the fourth read command and the fourth read address to the remote switching controller, wherein the fourth read address includes at least the ID number of the fifth target data buffer device; The read / write command access address determination unit is also used to determine the size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device. If the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, a thirteenth determination result is generated. If the ID number of the fifth target data cache device is less than the ID number of the current data cache device, a fourteenth determination result is generated. If the ID number of the fifth target data cache device is greater than the ID number of the current data cache device, a fifteenth determination result is generated. The data frame generation unit is also used to generate an eighth data frame according to the fourth read command and the fourth read address; The path selection unit is used to send the eighth data frame to the read controller according to the thirteenth judgment result, and is also used to send the eighth data frame to the adjacent data cache device according to the fourteenth judgment result, wherein the ID number of the adjacent data cache device is less than the ID number of the current data cache device, and is also used to send the eighth data frame to the other adjacent data cache device according to the fifteenth judgment result, wherein the ID number of the other adjacent data cache device is greater than the ID number of the current data cache device.

7. The data caching device according to claim 6, characterized in that, The path selection unit includes a first multiplexer, a second multiplexer, and a third multiplexer. The first input terminal of the first multiplexer is connected to the first data frame output terminal, the second input terminal of the first multiplexer is connected to the fifth data frame output terminal, the third input terminal of the first multiplexer is connected to the sixth data frame output terminal, the fourth input terminal of the first multiplexer is connected to the eighth data frame output terminal, the control signal input terminal of the first multiplexer is connected to the first judgment result output terminal, the fourth judgment result output terminal, the seventh judgment result output terminal, the tenth judgment result output terminal, and the thirteenth judgment result output terminal of the read / write command access address judgment unit, respectively, and the output terminal of the first multiplexer is connected to the input terminal of the data frame parsing unit of an adjacent data cache device of the current data cache device; The first input terminal of the second multiplexer is connected to the output terminal of the eighth data frame, the second input terminal of the second multiplexer is connected to the output terminal of the third data frame, the third input terminal of the second multiplexer is connected to the output terminal of the sixth data frame, the fourth input terminal of the second multiplexer is connected to the input terminal of the first data frame, the control signal input terminal of the second multiplexer is connected to the second judgment result output terminal, the fifth judgment result output terminal, the eighth judgment result output terminal, the eleventh judgment result output terminal and the fourteenth judgment result output terminal of the read / write command access address judgment unit, and the output terminal of the second multiplexer is connected to the input terminal of the data frame parsing unit of the other adjacent data buffer device. The first input terminal of the third multiplexer is connected to the output terminal of the eighth data frame, the second input terminal of the third multiplexer is connected to the output terminal of the sixth data frame, the third input terminal of the third multiplexer is connected to the output terminal of the third data frame, the fourth input terminal of the third multiplexer is connected to the output terminal of the first data frame, the control signal input terminal of the third multiplexer is connected to the third judgment result output terminal, the sixth judgment result output terminal, the ninth judgment result output terminal, the twelfth judgment result output terminal, and the fifteenth judgment result output terminal of the read / write command access address judgment unit, respectively, and the control signal output terminal of the third multiplexer is connected to the input terminals of the read controller and the write controller.

8. A data caching system, characterized in that, The data caching system includes a Class D trigger and at least two data caching devices as described in any one of claims 1-7. The two adjacent data cache devices are connected via the Class D trigger.

9. A method for data processing using the data caching device as described in any one of claims 1-7, characterized in that, Includes the following steps: The remote switching controller receives and parses the remote switching command data frame to obtain at least the remote switching command and the first target address corresponding to the remote switching command, wherein the remote switching command is a first read command or a first write command, and the first target address includes at least the ID number of the first target data cache device. The remote switching controller determines the size relationship between the ID number of the first target data cache device and the ID number of the current data cache device, and generates a first data frame according to the remote switching command and the first target address. Based on the determination result, the first data frame is sent to the data cache device adjacent to the current data cache device or to the read controller or write controller. If the remote switching controller sends the first data frame to the write controller, the write controller receives and parses the first data frame to obtain the first write command, the first write data and the first write address, and writes the first write data into the storage unit corresponding to the first write address; If the remote switching controller sends the first data frame to the read controller, the read controller receives and parses the first data frame to obtain the first read command and the first read address, and reads data from the storage unit corresponding to the first read address.

10. The method according to claim 9, characterized in that, The remote switching controller determines the relationship between the ID number of the first target data cache device and the ID number of the current data cache device, and generates a first data frame according to the remote switching command and the first target address. Based on the determination result, the first data frame is sent to the data cache device adjacent to the current data cache device or to the read controller or write controller. The data frame parsing unit receives and parses the remote exchange command data frame, obtaining at least the remote exchange command and the first target address. The read / write command access address judgment unit determines the relationship between the ID number of the first target data cache device and the ID number of the current data cache device. If the ID number of the first target data cache device is equal to the ID number of the current data cache device, a first judgment result is output; if the ID number of the first target data cache device is less than the ID number of the current data cache device, a second judgment result is output; if the ID number of the first target data cache device is greater than the ID number of the current data cache device, a third judgment result is output. The data frame generation unit generates a first data frame based on the remote exchange command and the first target address; The path selection unit sends the first data frame to the write controller or read controller according to the first judgment result, sends the first data frame to a neighboring data cache device of the current data cache device according to the second judgment result, the ID number of the neighboring data cache device is less than the ID number of the current data cache device, and sends the first data frame to another data cache device according to the third judgment result, the ID number of the other data cache device is greater than the ID number of the current data cache device.

11. The method according to claim 10, characterized in that, The method further includes: The data frame parsing unit receives and parses the second data frame sent by the adjacent data buffer device to obtain a second command and a second target address. The second command is a second read command or a second write command, and the second target address includes at least the ID number of the second target data buffer device. The read / write command access address determination unit determines the size relationship between the ID number of the second target data cache device and the ID number of the current data cache device. If the ID number of the second target data cache device is equal to the ID number of the current data cache device, a fourth determination result is output; if the ID number of the second target data cache device is less than the ID number of the current data cache device, a fifth determination result is output; and if the ID number of the second target data cache device is greater than the ID number of the current data cache device, a sixth determination result is output. The data frame generation unit generates a third data frame according to the second command and the second address; The path selection unit sends the third data frame to the write controller or read controller according to the fourth judgment result, or sends the third data frame to a neighboring data cache device of the current data cache device according to the fifth judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or sends the third data frame to another neighboring data cache device according to the sixth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

12. The method according to claim 11, characterized in that, The method further includes: The data frame parsing unit receives and parses the fourth data frame sent by the other adjacent data buffer device, and obtains at least a third command and a third target address. The third command is a third read command or a third write command, and the third target address includes at least the ID number of the third target data buffer device. The read / write command access address determination unit determines the size relationship between the ID number of the third target data cache device and the ID number of the current data cache device. If the ID number of the third target data cache device is equal to the ID number of the current data cache device, the seventh determination result is output. If the ID number of the third target data cache device is less than the ID number of the current data cache device, the eighth determination result is output. If the ID number of the third target data cache device is greater than the ID number of the current data cache device, the ninth determination result is output. The data frame generation unit generates a fifth data frame based on the third command and the third target address; The path selection unit sends the fifth data frame to the write controller or read controller according to the seventh judgment result, or sends the fifth data frame to a neighboring data cache device of the current data cache device according to the eighth judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or sends the fifth data frame to another neighboring data cache device according to the ninth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

13. The method according to claim 12, characterized in that, The method further includes: The write controller receives and parses the sixth data frame input through the write data port of the current data cache device to obtain the fourth write command, the fourth write data and the fourth write address, and sends the fourth write command, the fourth write data and the fourth write address to the remote switching controller, wherein the fourth write address includes at least the ID number of the fourth target data cache device; The read / write command access address judgment unit judges the size relationship between the ID number of the fourth target data cache device and the ID number of the current data cache device. If the ID number of the fourth target data cache device is equal to the ID number of the current data cache device, the tenth judgment result is output. If the ID number of the fourth target data cache device is less than the ID number of the current data cache device, the eleventh judgment result is output. If the ID number of the fourth target data cache device is greater than the ID number of the current data cache device, the twelfth judgment result is output. The data frame generation unit generates a sixth data frame based on the fourth write command, the fourth write data, and the fourth write address; The path selection unit sends the sixth data frame to the write controller according to the tenth judgment result, or sends the sixth data frame to a neighboring data cache device of the current data cache device according to the eleventh judgment result, wherein the ID number of the neighboring data cache device is less than the ID number of the current data cache device, or sends the sixth data frame to another neighboring data cache device according to the twelfth judgment result, wherein the ID number of the other neighboring data cache device is greater than the ID number of the current data cache device.

14. The method according to claim 13, characterized in that, The method further includes: The read controller receives and parses the seventh data frame input through the read data port of the current data cache device, obtains the fourth read command and the fourth read address, and sends the fourth read command and the fourth read address to the remote switching controller, wherein the fourth read address includes at least the ID number of the fifth target data cache device; The read / write command access address determination unit determines the size relationship between the ID number of the fifth target data cache device and the ID number of the current data cache device. If the ID number of the fifth target data cache device is equal to the ID number of the current data cache device, a thirteenth determination result is generated. If the ID number of the fifth target data cache device is less than the ID number of the current cache device, a fourteenth determination result is generated. If the ID number of the fifth target data cache device is greater than the ID number of the current data cache device, a fifteenth determination result is generated. The data frame generation unit generates the eighth data frame according to the fourth read command and the fourth read address; The path selection unit sends the eighth data frame to the read controller according to the thirteenth judgment result, and is also used to send the eighth data frame to the adjacent data cache device according to the fourteenth judgment result, wherein the ID number of the adjacent data cache device is less than the ID number of the current data cache device, and is also used to send the eighth data frame to the other adjacent data cache device according to the fifteenth judgment result, wherein the ID number of the other adjacent data cache device is greater than the ID number of the current data cache device.

Citation Information

Patent Citations

  • Memory device, memory controller and memory system

    CN101206908A

  • Data caching system and data caching method

    CN103780506A