Storage device and storage method thereof
By designing a storage device that contains the CXL interface and memory control unit, it can compress the memory data of the server, solve the problem of restricted memory expansion of the server, and realize memory compression and performance improvement.
Patent Information
- Application Number
- CN202411930949.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-26
- Publication Date
- 2025-01-24
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing servers are limited in terms of memory expansion and cannot implement memory compression, resulting in the program's requested memory space exceeding the available memory of the server, which cannot meet the program's requirements and reduces the program's running speed.
Design a storage device, including a CXL interface, a memory control unit, a first storage unit and a second storage unit. The memory control unit is connected to the server through the CXL interface and can compress part of the memory data in the first storage unit, and Store the compressed data in the second storage unit.
The memory compression function is implemented, which increases the memory space of the server, improves the running speed of the program, and saves the memory space of the storage device, further improving the performance of the server.
Smart Images

Figure CN119357090A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of storage technology, and in particular to a storage device and a storage method thereof. Background Art
[0002] The server's memory expansion is mainly limited by the number of memory slots on the server motherboard and the capacity of a single DDR (Double Data Rate SDRAM) of the server. When the memory slots on the server motherboard are used up, the server cannot implement memory expansion.
[0003] The server of the prior art does not implement the memory compression function. The memory capacity that the server can access is equal to the actual memory capacity of the server. When the memory space requested by the program running on the server exceeds the maximum available memory space of the server, the program's requirements cannot be met and only part of the memory can be allocated for use by the program, reducing the running speed of the program. Summary of the invention
[0004] The present application provides a storage device and a storage method thereof, which can realize the function of memory compression.
[0005] The present application provides a storage device, which is connected to a server. The storage device includes a CXL interface, a memory control unit, a first storage unit, and a second storage unit. The memory control unit is connected to the server via the CXL interface. The memory control unit is connected to the first storage unit and the second storage unit, respectively. The first storage unit is used to store first memory data, and the second storage unit is used to store second memory data. The memory control unit is used to compress part of the first memory data in the first storage unit, and store the compressed first memory data in the second storage unit.
[0006] The memory control unit is used to predict the first memory data and the second memory data to obtain the memory data required by the server, and predict that part of the first memory data is not the memory data required by the server.
[0007] Among them, the memory control unit is used to predict that the memory data required by the server is stored in the second storage unit, obtain the corresponding second memory data from the second storage unit, and decompress the second memory data to store the decompressed second memory data in the first storage unit.
[0008] The memory control unit is used to predict that the memory data required by the server is stored in the first storage unit, and obtain the corresponding first memory data from the first storage unit.
[0009] The memory control unit encodes the part of the first memory data using a preset encoding table to obtain the compressed first memory data.
[0010] Among them, the preset coding table includes a first code and a second code, the character string of the first code is longer than the character string of the second code, the part of the first memory data includes a first source symbol and a second source symbol, the probability of occurrence of the first source symbol is higher than the probability of occurrence of the second source symbol, and the memory control unit uses the second code to encode the first source symbol, and uses the first code to encode the second source symbol.
[0011] The memory control unit includes a memory controller and an arbiter / multiplexer circuit, the memory controller is connected to the server via the CXL interface, and the memory controller is connected to the first storage unit and the second storage unit respectively via the arbiter / multiplexer circuit.
[0012] The storage device further includes a processor, which is connected to the CXL interface and the memory controller respectively and is used to configure the storage device.
[0013] Wherein, the storage device further includes a plurality of matrix calculation units, and the plurality of matrix calculation units are respectively connected to the processor and the memory controller.
[0014] The present application also provides a storage method, which is applied to the above-mentioned storage device, and the storage method includes: Predicting the first memory data of the first storage unit and the second memory data of the second storage unit to obtain the memory data required by the server; In response to predicting that part of the first memory data of the first storage unit is not the memory data required by the server; compressing the part of the first memory data, and storing the compressed first memory data in the second storage unit; In response to predicting that the memory data required by the server is stored in the second storage unit, obtaining corresponding second memory data from the second storage unit, and decompressing the second memory data to store the decompressed second memory data in the first storage unit; In response to predicting that the memory data required by the server is stored in the first storage unit, the corresponding first memory data is obtained from the first storage unit.
[0015] The beneficial effects of the present application are as follows: the storage device of the present application includes a CXL interface, a memory control unit, a first storage unit and a second storage unit, the memory control unit is connected to the server through the CXL interface, the memory control unit is connected to the first storage unit and the second storage unit respectively, the first storage unit is used to store first memory data, the second storage unit is used to store second memory data, and the memory control unit is used to compress part of the first memory data in the first storage unit, and store the compressed first memory data in the second storage unit. The server is connected to the memory control unit through the CXL interface, so that the server can access the first storage unit and the second storage unit of the storage device, thereby increasing the memory space of the server and improving the running speed of the server program; in addition, by compressing part of the first memory data through the memory control unit, and storing the compressed first memory data in the second storage unit, the storage device can realize the compression function, can save the memory space of the storage device, and because the memory space of the storage device is equivalent to the memory space of the server, the memory space of the server is further increased, and the performance of the server is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. Among them: Figure 1 It is a schematic diagram of the framework of a storage device and a server according to an embodiment of the present application; Figure 2 is a schematic diagram of a framework of another embodiment of a storage device and a server of the present application; Figure 3 It is a flowchart of an embodiment of the storage method of the present application; Figure 4 It is a schematic diagram of a framework of an embodiment of a computer-readable storage medium of the present application. DETAILED DESCRIPTION
[0017] The following embodiments of the technical solution of the present application will be described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present application, and are therefore only used as examples, and cannot be used to limit the scope of protection of the present application.
[0018] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by technicians in the technical field to which this application belongs; the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the terms "including" and "having" in the specification and claims of this application and the above-mentioned figure descriptions and any variations thereof are intended to cover non-exclusive inclusions.
[0019] In the description of the embodiments of the present application, the technical terms "first", "second", etc. are only used to distinguish different objects, and cannot be understood as indicating or implying relative importance or implicitly indicating the number, specific order or primary and secondary relationship of the indicated technical features. In the description of the embodiments of the present application, the meaning of "multiple" is more than two, unless otherwise clearly and specifically defined.
[0020] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0021] In the description of the embodiments of the present application, the term "and / or" is only a description of the association relationship of the associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0022] In the description of the embodiments of the present application, the term "multiple" refers to more than two (including two). Similarly, "multiple groups" refers to more than two groups (including two groups), and "multiple pieces" refers to more than two pieces (including two pieces).
[0023] In the description of the embodiments of the present application, unless otherwise clearly specified and limited, technical terms such as "installed", "connected", "connected", "fixed" and the like should be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be connected between, or indirectly connected through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the embodiments of the present application can be understood according to the specific circumstances.
[0024] See also Figure 1 As shown, Figure 1The storage device 100 of this embodiment is connected to the server 200, wherein the storage device 100 includes but is not limited to an expansion card, an on-chip memory or a matrix operation acceleration board.
[0025] In some embodiments, the server 200 includes a central processing unit 21, a DDR memory 22 and a server CXL interface 23. The central processing unit 21 is connected to the DDR memory 22 and the server CXL interface 23 respectively. The central processing unit 21 is used to run the program. The central processing unit 21 is used to allocate memory space of the DDR memory 22 for use by the program. The central processing unit 21 is connected to the storage device 100 through the server CXL interface 23.
[0026] The storage device 100 includes a CXL interface 11 (Compute Express Link, which is an open standard protocol for high-bandwidth and low-latency device interconnection), a memory control unit 12, a first storage unit 13, and a second storage unit 14. The memory control unit 12 is connected to the server 200 via the CXL interface 11, that is, the CXL interface 11 is connected to the server CXL interface 23, so as to realize the connection between the storage device 100 and the server 200.
[0027] The memory control unit 12 is connected to the first storage unit 13 and the second storage unit 14 respectively. The first storage unit 13 is used to store first memory data, and the second storage unit 14 is used to store second memory data.
[0028] Optionally, both the first storage unit 13 and the second storage unit 14 may be non-volatile memories, so the first storage unit 13 and the second storage unit 14 will not lose the first memory data and the second memory data when the storage device 100 loses power. In other embodiments, the first storage unit 13 and the second storage unit 14 may be other types of memories, which will not be described in detail herein.
[0029] The memory control unit 12 is used to compress part of the first memory data in the first storage unit 13 and store the compressed first memory data in the second storage unit 14 . At this time, the compressed first memory data serves as the second memory data of the second storage unit 14 .
[0030] For example, the first memory data stored in the first storage unit 13 is uncompressed memory data, and the second memory data stored in the second storage unit 14 is compressed memory data. The first memory data, second memory data, and memory data of this application refer to data that can meet the program running requirements of the server 200.
[0031] The server 200 of this embodiment is connected to the memory control unit 12 via the CXL interface 11, so that the server 200 can access the first storage unit 13 and the second storage unit 14 of the storage device 100, thereby increasing the memory space of the server 200 and improving the running speed of the program of the server 200. In addition, the memory control unit 12 compresses part of the first memory data and stores the compressed first memory data in the second storage unit 14, so that the storage device 100 can realize the compression function and save the memory space of the storage device 100. Since the memory space of the storage device 100 is equivalent to the memory space of the server 200, the memory space of the server 200 is further increased, and the performance of the server 200 is improved.
[0032] According to some embodiments of the present application, the memory control unit 12 of this embodiment is used to predict the first memory data and the second memory data to obtain the memory data required by the server 200, and predicts that part of the first memory data is not the memory data required by the server 200.
[0033] The memory control unit 12 predicts the first memory data and the second memory data in advance through a prediction algorithm to obtain the memory data required by the server 200. The prediction algorithm may be a prediction algorithm in the prior art, which will not be described in detail here.
[0034] In some embodiments, the memory control unit 12 predicts the memory data required by the server 200 through a prediction algorithm. The memory data required by the server 200 is the memory data required by the program of the server 200. The memory data required by the program may be the first memory data and / or the second memory data.
[0035] The memory control unit 12 predicts that part of the first memory data is not memory data required by the server 200, that is, part of the first memory data is memory data that the central processor 21 of the server 200 will not access within a preset time. The memory control unit 12 compresses part of the first memory data and stores the compressed first memory data in the second storage unit 14.
[0036] The memory control unit 12 of this embodiment is used to predict the first memory data and the second memory data to obtain the memory data required by the server 200, and predict that part of the first memory data is not the memory data required by the server 200; when the memory control unit 12 predicts that part of the first memory data is not the memory data required by the server 200, it compresses part of the first memory data and stores the compressed first memory data in the second storage unit 14, which can reduce the occupancy rate of part of the first memory data on the first storage unit 13, and can store more memory data when the memory space of the first storage unit 13 and the second storage unit 14 remains unchanged, thereby realizing memory expansion. In addition, the memory control unit 12 compresses part of the first memory data in advance through prediction, so as to avoid the compression process occupying the time of the central processor 21 accessing the memory data, thereby improving the performance of the storage device 100.
[0037] According to some embodiments of the present application, the memory control unit 12 of this embodiment is used to predict that the memory data required by the server 200 is stored in the second storage unit 14, obtain the corresponding second memory data from the second storage unit 14, and decompress the second memory data to store the decompressed second memory data in the first storage unit 13.
[0038] In some embodiments, the memory control unit 12 is used to predict that the memory data required by the server 200 is stored in the second storage unit 14, that is, the memory data required by the server 200 is not stored in the first storage unit 13, and the memory control unit 12 obtains the corresponding second memory data from the second storage unit 14 in advance, and the corresponding second memory data is the memory data required by the server 200. The memory control unit 12 decompresses the corresponding second memory data to store the decompressed second memory data in the first storage unit 13, and the decompressed second memory data is used as the first memory data of the first storage unit 13.
[0039] The memory control unit 12 of this embodiment is used to predict that the memory data required by the server 200 is stored in the second storage unit 14, obtain the corresponding second memory data from the second storage unit 14, and decompress the second memory data to store the decompressed second memory data in the first storage unit 13. The memory control unit 12 decompresses the corresponding second memory data in advance through the prediction mechanism, so as to avoid the decompression process occupying the time of the central processor 21 accessing the memory data, thereby improving the performance of the storage device 100.
[0040] According to some embodiments of the present application, the memory control unit 12 of this embodiment is used to predict that the memory data required by the server 200 is stored in the first storage unit 13, and obtain the corresponding first memory data from the first storage unit 13.
[0041] In some embodiments, the memory control unit 12 is used to predict that the memory data required by the server 200 is stored in the first storage unit 13, that is, the memory data required by the server 200 is not stored in the second storage unit 14, and the memory control unit 12 obtains the corresponding first memory data from the first storage unit 13, and the corresponding first memory data is the memory data required by the server 200.
[0042] The memory control unit 12 of this embodiment is used to predict that the memory data required by the server 200 is stored in the first storage unit 13, obtain the corresponding first memory data from the first storage unit 13, and implement memory expansion of the server 200 by predicting the memory data required by the server 200.
[0043] According to some embodiments of the present application, the memory control unit 12 of this embodiment encodes part of the first memory data through a preset encoding table to obtain compressed first memory data.
[0044] In some embodiments, the memory control unit 12 can compress part of the first memory data through the Huffman compression algorithm, that is, the preset coding table can be a Huffman variable-length coding table, and the memory control unit 12 encodes part of the first memory data through the Huffman variable-length coding table to obtain compressed first memory data.
[0045] The memory control unit 12 of this embodiment encodes part of the first memory data through the Huffman variable length coding table to obtain compressed first memory data, and can perform lossless data compression on part of the first memory data. In addition, the second memory data can also be decompressed through the Huffman compression algorithm.
[0046] According to some embodiments of the present application, the preset coding table of the present embodiment includes a first coding and a second coding, and the character string of the first coding is longer than the character string of the second coding. Wherein, the preset coding table is not limited to the first coding and the second coding, and only the first coding and the second coding are taken as examples, which does not limit the scope of the present application.
[0047] The first memory data includes a first source symbol and a second source symbol, and the first source symbol has a higher probability of occurrence than the second source symbol. The first memory data is not limited to the first source symbol and the second source symbol. The first source symbol and the second source symbol are used as examples only, and the scope of the present application is not limited.
[0048] The memory control unit 12 encodes the first source symbol using the second code, and encodes the second source symbol using the first code. That is, the memory control unit 12 encodes the source symbol with a high probability of occurrence using the second code with a short character string, and encodes the source symbol with a low probability of occurrence using the first code with a long character string.
[0049] The memory control unit 12 of this embodiment encodes the first source symbol using the second encoding, and encodes the second source symbol using the first encoding, so that the length of the string of the compressed first memory data is shorter than the string of part of the first memory data, thereby achieving lossless compression.
[0050] According to some embodiments of this application, see Figure 2 As shown, Figure 2 1 is a schematic diagram of another embodiment of the storage device and server of the present application. The memory control unit 12 of the present embodiment includes a memory controller 121 and an arbiter / multiplexer circuit 122. The memory controller 121 is connected to the server 200 via the CXL interface 11, and is connected to the first storage unit 13 and the second storage unit 14 via the arbiter / multiplexer circuit 122.
[0051] In some embodiments, the memory controller 121 is used to compress part of the first memory data in the first storage unit 13, and store the compressed first memory data in the second storage unit 14. The memory controller 121 is used to predict the first memory data and the second memory data to obtain the memory data required by the server 200, and predict that part of the first memory data is not the memory data required by the server 200. The memory controller 121 is used to predict that the memory data required by the server 200 is stored in the second storage unit 14, obtain the corresponding second memory data from the second storage unit 14, and decompress the second memory data to store the decompressed second memory data in the first storage unit 13. The memory controller 121 is used to predict that the memory data required by the server 200 is stored in the first storage unit 13, and obtain the corresponding first memory data from the first storage unit 13. The memory controller 121 is used to encode part of the first memory data through a preset encoding table to obtain compressed first memory data.
[0052] In some embodiments, the arbiter / multiplexer circuit 122 may be an ARB / MUX circuit for arbitrating or selecting a data path of the first storage unit 13 and a data path of the second storage unit 14. The central processor 21 of the server 200 accesses the first storage unit 13 and the second storage unit 14 through the arbiter / multiplexer circuit 122.
[0053] The CXL interface 11 transmits memory data required by the server 200 to the server 200 through the CXL protocol. Optionally, the CXL interface 11 is connected to the server CXL interface 23 through the CXL protocol.
[0054] The CXL interface 11 of this embodiment transmits memory data required by the server 200 with the server 200 through the CXL protocol. The storage device 100 opens the first storage unit 13 and the second storage unit 14 to the central processor 21 of the server 200 through the CXL protocol, so that the central processor 21 of the server 200 directly accesses the first storage unit 13 and the second storage unit 14, and realizes that the first storage unit 13 and the second storage unit 14 are equivalent to the DDR memory 22, thereby ensuring the consistency of the central processor 21 in accessing the DDR memory 22, the first storage unit 13 and the second storage unit 14, and realizing the memory expansion of the server 200.
[0055] According to some embodiments of the present application, Figure 2 As shown, the storage device 100 of this embodiment further includes a processor 15 and a plurality of matrix calculation units 16 .
[0056] The processor 15 may be an instruction processor of the storage device 100, and is connected to the CXL interface 11 and the memory controller 121 respectively, for configuring the storage device 100. In addition, the processor 15 may also interrupt the CPU 21 accessing the first storage unit 13 and the second storage unit 14.
[0057] The multiple matrix computing units 16 form an MCU (Matrix Computation Unit) cluster. The multiple matrix computing units 16 may be multiple MCUs. The multiple matrix computing units 16 are respectively connected to the processor 15 and the memory controller 121 .
[0058] Optionally, multiple matrix calculation units 16 can implement high-throughput matrix operations. The matrix calculation units include but are not limited to matrix multiplication units (not shown) and accumulation units (not shown), etc. The matrix multiplication units and accumulation units work together to complete the matrix operation instructions of the processor 15.
[0059] Optionally, the memory controller 121 is also used to implement storage control logic of matrix operation data of multiple matrix calculation units 16, analysis logic of matrix operation commands, and deployment logic of matrix operation processing units. For example, the memory controller 121 stores the operation data of multiple matrix calculation units 16 in the first storage unit 13 and the second storage unit 14.
[0060] The multiple matrix calculation units 16 of this embodiment are respectively connected to the processor 15 and the memory controller 121. The memory controller 121 stores the operation data of the multiple matrix calculation units 16 to the first storage unit 13 and the second storage unit 14, which can release the load of the central processing unit 21 during the matrix operation process, improve the response speed of the central processing unit 21, and improve the efficiency of the server 200.
[0061] This application also provides a storage method, see Figure 3 As shown, Figure 3 1 is a flow chart of an embodiment of the storage method of the present application. The storage method of this embodiment is applied to the storage device 100 of the above embodiment, and the storage method includes the following steps: S101: Predicting the first memory data of the first storage unit 13 and the second memory data of the second storage unit to obtain the memory data required by the server 200.
[0062] The memory control unit 12 is used to predict the first memory data and the second memory data to obtain the memory data required by the server 200, wherein the memory control unit 12 predicts the first memory data and the second memory data in advance through a prediction algorithm, and determines whether the memory data required by the server 200 is stored in the first storage unit 13 and / or the second storage unit 14.
[0063] S102 : In response to predicting that part of the first memory data of the first storage unit 13 is not the memory data required by the server 200 , compress the part of the first memory data and store the compressed first memory data in the second storage unit 14 .
[0064] The memory control unit 12 predicts that part of the first memory data is not memory data required by the server 200, that is, part of the first memory data is memory data that the central processor 21 of the server 200 will not access within a preset time. The memory control unit 12 compresses part of the first memory data and stores the compressed first memory data in the second storage unit 14.
[0065] S103 : In response to predicting that the memory data required by the server 200 is stored in the second storage unit 14 , the corresponding second memory data is obtained from the second storage unit 14 , and the second memory data is decompressed to store the decompressed second memory data in the first storage unit 13 .
[0066] The memory control unit 12 is used to predict that the memory data required by the server 200 is stored in the second storage unit 14, that is, the memory data required by the server 200 is not stored in the first storage unit 13. The memory control unit 12 obtains the corresponding second memory data from the second storage unit 14 in advance, and the corresponding second memory data is the memory data required by the server 200.
[0067] The memory control unit 12 decompresses the corresponding second memory data to store the decompressed second memory data in the first storage unit 13 . At this time, the decompressed second memory data serves as the first memory data of the first storage unit 13 .
[0068] S104 : in response to predicting that the memory data required by the server 200 is stored in the first storage unit 13 , obtaining corresponding first memory data from the first storage unit 13 .
[0069] The memory control unit 12 is used to predict that the memory data required by the server 200 is stored in the first storage unit 13, that is, the memory data required by the server 200 is not stored in the second storage unit 14. The memory control unit 12 obtains the corresponding first memory data from the first storage unit 13, and the corresponding first memory data is the memory data required by the server 200.
[0070] This application also provides a computer-readable storage medium, see Figure 4 , Figure 4 Schematic diagram of a computer-readable storage medium according to an embodiment of the present invention. Figure 4 As shown, the computer-readable storage medium 70 stores program instructions 71 that can be executed by a processor, and the program instructions 71 are used to implement the steps in any of the above storage method embodiments.
[0071] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0072] The above description of various embodiments tends to emphasize the differences between the various embodiments. The same or similar aspects can be referenced to each other, and for the sake of brevity, they will not be repeated herein.
[0073] In the several embodiments provided in the present application, it should be understood that the disclosed methods and devices can be implemented in other ways. For example, the device implementation described above is only schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation, such as units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.
[0074] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0075] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of each implementation method of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program code.
[0076] The above description is only an implementation method of the present application, and does not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made using the contents of the present application specification and drawings, or directly or indirectly used in other related technical fields, are also included in the patent protection scope of the present application.
Claims
1. A storage device, characterized in that: The storage device is connected to the server, and includes a CXL interface, a memory control unit, a first storage unit and a second storage unit. The memory control unit is connected to the server via the CXL interface, and the memory control unit is connected to the first storage unit and the second storage unit respectively. The first storage unit is used to store first memory data, and the second storage unit is used to store second memory data. The memory control unit is used to compress part of the first memory data in the first storage unit, and store the compressed first memory data in the second storage unit.
2. The storage device according to claim 1, characterized in that The memory control unit is used to predict the first memory data and the second memory data to obtain the memory data required by the server, and predict that part of the first memory data is not the memory data required by the server.
3. The storage device according to claim 2, characterized in that: The memory control unit is used to predict that the memory data required by the server is stored in the second storage unit, obtain the corresponding second memory data from the second storage unit, and decompress the second memory data to store the decompressed second memory data in the first storage unit.
4. The storage device according to claim 2, characterized in that: The memory control unit is used to predict that the memory data required by the server is stored in the first storage unit, and obtain the corresponding first memory data from the first storage unit.
5. The storage device according to claim 1, characterized in that: The memory control unit encodes the portion of the first memory data using a preset encoding table to obtain the compressed first memory data.
6. The storage device according to claim 5, characterized in that: The preset coding table includes a first code and a second code, the character string of the first code is longer than the character string of the second code, the part of the first memory data includes a first source symbol and a second source symbol, the probability of occurrence of the first source symbol is higher than the probability of occurrence of the second source symbol, and the memory control unit uses the second code to encode the first source symbol, and uses the first code to encode the second source symbol.
7. The storage device according to any one of claims 1 to 6, characterized in that: The memory control unit includes a memory controller and an arbiter / multiplexer circuit. The memory controller is connected to the server through the CXL interface. The memory controller is connected to the first storage unit and the second storage unit respectively through the arbiter / multiplexer circuit.
8. The storage device according to claim 7, characterized in that: The storage device further includes a processor, which is connected to the CXL interface and the memory controller respectively and is used to configure the storage device.
9. The storage device according to claim 8, characterized in that: The storage device further includes a plurality of matrix calculation units, and the plurality of matrix calculation units are respectively connected to the processor and the memory controller.
10. A storage method, characterized in that: The storage method is applied to the storage device according to any one of claims 1 to 9, and the storage method includes: Predicting the first memory data of the first storage unit and the second memory data of the second storage unit to obtain the memory data required by the server; In response to predicting that part of the first memory data of the first storage unit is not the memory data required by the server; compressing the part of the first memory data, and storing the compressed first memory data in the second storage unit; In response to predicting that the memory data required by the server is stored in the second storage unit, obtaining corresponding second memory data from the second storage unit, and decompressing the second memory data to store the decompressed second memory data in the first storage unit; In response to predicting that the memory data required by the server is stored in the first storage unit, the corresponding first memory data is obtained from the first storage unit.
Citation Information
Patent Citations
Data arrangement method, storage apparatus, storage controller and storage array
CN105723320A
System and method for managing memory resources
CN113742259A
Data stream processing method, storage control node and readable storage medium
CN114201421A
Server structure and server cluster architecture
CN115407839A
Memory control chip, memory module of server and server
CN116737604A