Accelerated reading method and system for solid state disk
By setting the access frequency table in the solid-state drive and optimizing the preloading strategy using the AI data analysis module, the problems of data reading delay and cache utilization efficiency of traditional solid-state drives are solved, and the rapidity of high-frequency data for users is achieved Access and cache management significantly improves read performance and user experience.
Patent Information
- Application Number
- CN202411086422.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-08
- Publication Date
- 2024-12-03
AI Technical Summary
Traditional solid-state drives are difficult to further shorten the delay when reading data, cannot effectively optimize the waiting time at the second level, and lack distinction between the pre-reading strategies of user data, resulting in the inability to fully improve the reading performance.
By setting the frequency table of historical access data in the solid state hard disk, preloading high-frequency access data to the DDR cache, and dynamically update table entries, giving priority to the high-frequency data, and using the AI data analysis module to monitor access frequency and sort table entries. Automatically preload before issuing read commands on the host, and the cache is cleaned in time to make space.
Significantly reduces large file reading time, optimizes operating system and software startup time, maintains efficient utilization of DDR cache, and dynamically adjusts strategies according to user habits. It is suitable for consumer user scenarios, delays the performance attenuation of SSDs to the user experience The impact of
Smart Images

Figure CN119065604A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of solid-state storage devices, and in particular to a method and system for accelerating reading of a solid-state hard disk. Background Art
[0002] In the existing solid-state storage technology field, almost all of them have pre-reading algorithms for large file reading. The principle is that the read commands sent by the host are continuous. When a certain number of consecutive read commands reaches the trigger condition, the data will be moved to the cache before the host command is sent. This improves the reading performance.
[0003] Traditional solutions treat user data indiscriminately. Compared with HDD (mechanical hard disk), SSD (solid state drive) has achieved an order of magnitude improvement in speed overall. Compared with HDD, using SSD to start the computer can be several times faster. However, the seconds-level waiting is also noticeable to users.
[0004] However, users can accept a waiting time of tens of seconds or a few milliseconds, but cannot accept a delay of a few seconds. The traditional pre-reading concept still requires optimization after the user issues a command, which makes it difficult to further shorten the data reading time. Summary of the invention
[0005] In view of this, an embodiment of the present invention provides a method and system for accelerating reading of a solid state drive, so as to solve or partially solve the above problems.
[0006] In a first aspect, an embodiment of the present invention provides a method for accelerating reading of a solid state drive, comprising the following steps:
[0007] Set up a frequency table based on historical access data of the SSD;
[0008] Selecting an LBA range according to the frequency table and preloading data into DDR before the host issues a read command;
[0009] Recording the access frequency of each LBA and dynamically updating the frequency table;
[0010] When the DDR space is insufficient, data with fewer access times is removed from the DDR space according to the latest frequency table to make room for new preloaded data, so that high-frequency access data is always retained first.
[0011] According to a specific implementation of an embodiment of the present invention, the entries of the frequency table include LBA range, number of reads, whether the data will be read when the computer is powered on, and number of reads after the computer is powered on.
[0012] According to a specific implementation of the embodiment of the present invention, the frequency table update process is as follows:
[0013] The operation status of the SSD is monitored, and the access frequency of each LBA is recorded; based on the access frequency of the LBA and the LBA range, the table items in the frequency table are sorted and updated.
[0014] According to a specific implementation of an embodiment of the present invention, the table items in the frequency table are sorted as follows: LBAs that will definitely be read at startup are set to the highest priority; then they are sorted from most to least according to the number of reads after startup, and the LBA ranges with the same number of reads after startup are sorted from small to large. Through the above mechanism, the optimal LBA range is selected as the preload target to ensure that the data blocks most likely to be accessed by the user are stored in the DDR cache.
[0015] In a second aspect, an embodiment of the present invention further provides a system using the above-mentioned accelerated reading method, including:
[0016] An SSD body having a non-volatile memory and a DDR built therein;
[0017] An AI data analysis module, used to monitor the operating status of the SSD in real time, record the access frequency of each LBA, and update the maintenance frequency table;
[0018] A preloading control unit selects a corresponding LBA range according to the frequency table output by the AI data analysis module, and preloads data within the range into the DDR before the host issues a read command;
[0019] The replacement strategy execution unit is used to remove data with fewer access times from the DDR space according to the latest frequency table when the DDR space is insufficient.
[0020] According to a specific implementation of an embodiment of the present invention, the preloading control unit automatically performs a preloading operation when the SSD is idle, so as to reduce the impact on the normal operation of the host.
[0021] According to a specific implementation of an embodiment of the present invention, the replacement strategy execution unit also considers the remaining life and performance degradation of the SSD, and gives priority to replacing LBA range data that has a smaller impact on the overall performance.
[0022] The embodiments of the present invention have at least the following technical effects:
[0023] First, this method is suitable for consumer-level user scenarios, such as continuous large file reading scenarios when users turn on the computer and start large software (such as PS, MATLAB, PADS, Vivado, etc.). By loading the predicted data blocks to the DDR cache in advance, the time to read data from the NAND flash memory is significantly reduced, thereby optimizing the loading time of the operating system and the startup time of large software.
[0024] Second, the method regularly cleans and organizes data blocks in the DDR cache to maintain efficient use of the cache and dynamically adjusts the cache strategy according to user usage habits.
[0025] Third, as SSDs are used, this method continuously optimizes the AI data analysis module to make SSDs more in line with users' actual usage needs. Even if the SSD performance declines, it can compensate for the performance loss by specifically accelerating the content that users are concerned about. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following is a brief introduction to the drawings required for the specific embodiments or the description of the prior art. In all the drawings, similar elements or parts are generally identified by similar reference numerals. In the drawings, the elements or parts are not necessarily drawn according to the actual scale.
[0027] Figure 1 A flowchart showing a method for accelerating reading of a solid state hard disk provided by an embodiment of the present invention is shown;
[0028] Figure 2 A flowchart of the steps of SSD preloading in an embodiment of the present invention is shown;
[0029] Figure 3 The flowchart of updating the frequency table in the embodiment of the present invention is shown. DETAILED DESCRIPTION
[0030] The following embodiments of the technical solution of the present invention are 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 invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.
[0031] It should be noted that, unless otherwise specified, the technical terms or scientific terms used in this application should have the common meanings understood by those skilled in the art to which the invention belongs.
[0032] Figure 1 A flowchart of a method for accelerating reading of a solid state hard disk provided by an embodiment of the present invention is shown in FIG. Figure 1 , the method comprises the following steps:
[0033] S1: Setting the frequency table based on the historical access data of the SSD;
[0034] As shown in Table 1 below, the items in the frequency table include LBA range, read count, whether it will be read at power-on, read count after power-on, etc. The items in the frequency table are sorted as follows: LBAs that will be read at power-on will be set as the highest priority and marked as urgent. As soon as the host is powered on, the SSD needs to preload the urgent LBA range as much as possible; then sort by the number of reads after power-on from most to least, and those with the same number of reads after power-on will be sorted by LBA range from small to large. Through the above mechanism, the optimal LBA range is selected as the preload target to ensure that the data blocks that users are most likely to access are stored in the DDR cache.
[0035]
[0036] S2: Select the LBA range according to the frequency table, and preload the corresponding data into the DDR according to the capacity limit of the DDR before the host sends a read command;
[0037] Traditionally, DDR is used to store the L2P table. In the present invention, part of the capacity of DDR is reserved for advance reading.
[0038] like Figure 2 As shown, after the SSD is powered on and the back-end initialization is completed, the frequency table is read from the NAND, and the LBA range of the data to be preloaded is selected after arbitration and loaded into the DDR; when the host sends a read request, the pre-read data is searched in the frequency table. If the LBA range hits, the data is quickly read from the DDR. If the LBA range does not hit, it is read in the usual way.
[0039] S3: Record the access frequency of each LBA and dynamically update the frequency table;
[0040] The frequency table update process is as follows: monitor the operating status of the SSD and record the access frequency of each LBA; sort and update the entries in the frequency table based on the access frequency of the LBA and the LBA range.
[0041] S4: When the DDR space is insufficient, the data with less access times is removed from the DDR space according to the latest frequency table, making room for new preloaded data so that the high-frequency access data is always retained first.
[0042] The embodiment of the present invention further provides a system using the above-mentioned accelerated reading method, including:
[0043] A solid state drive (SSD) body having a non-volatile memory (such as NAND flash memory) and a dynamic random access memory (DDR) built in;
[0044] The AI data analysis module (AI Engine) is stored in the SSD and is used to monitor the operating status of the SSD in real time, record the access frequency of each LBA, and update the maintenance frequency table; the frequency table is stored in the non-volatile memory;
[0045] Figure 3 The frequency table update mechanism of the AI data analysis module is shown. As shown in the figure, when the LBA does not hit, the frequency table update is skipped and the regular read process is entered. When it hits, the corresponding content in the frequency table is updated. When the host is a write or trim command and the LBA hits an item in the frequency table, it means that the host has updated the content of this LBA, then the statistical information of this item will be invalid, and the entry of the table needs to be cleared.
[0046] The preload control unit is stored in the SSD. According to the frequency table output by the AI data analysis module, the corresponding LBA range is selected, and the data in the range is preloaded into the DDR before the host sends a read command.
[0047] The replacement strategy execution unit is stored in the SSD and is used to remove data with fewer access times from the DDR space according to the latest frequency table when the DDR space is insufficient.
[0048] Furthermore, the preloading control unit automatically performs a preloading operation when the SSD is idle to reduce the impact on the normal operation of the host.
[0049] Furthermore, the replacement strategy execution unit also considers the remaining life and performance degradation of the SSD, and gives priority to replacing LBA range data that has less impact on the overall performance.
[0050] The embodiments of the present invention have the following technical effects:
[0051] First, this method is suitable for consumer-level user scenarios, such as continuous large file reading scenarios when users turn on the computer and start large software (such as PS, MATLAB, PADS, Vivado, etc.). By loading the predicted data blocks to the DDR cache in advance, the time to read data from the NAND flash memory is significantly reduced, thereby optimizing the loading time of the operating system and the startup time of large software.
[0052] Second, the method regularly cleans and organizes data blocks in the DDR cache to maintain efficient use of the cache and dynamically adjusts the cache strategy according to user usage habits.
[0053] Third, as SSDs are used, this method continuously optimizes the AI data analysis module to make SSDs more in line with users' actual usage needs. Even if the SSD performance declines, it can compensate for the performance loss by specifically accelerating the content that users are concerned about.
[0054] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed by the present invention should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims
1. A method for accelerating reading of a solid state hard disk, characterized in that: The following steps are involved: Set up a frequency table based on historical access data of the SSD; Selecting an LBA range according to the frequency table and preloading data into DDR before the host issues a read command; Recording the access frequency of each LBA and dynamically updating the frequency table; When the DDR space is insufficient, data with fewer access times is removed from the DDR space according to the latest frequency table.
2. The accelerated reading method according to claim 1, characterized in that: The entries of the frequency table include LBA range, number of reads, whether the reading will be performed when the computer is powered on, and number of reads after the computer is powered on.
3. The accelerated reading method according to claim 2, characterized in that: The frequency table update process is as follows: The operating status of the SSD is monitored, and the access frequency of each LBA is recorded; based on the access frequency of the LBA and the LBA range, the table items in the frequency table are sorted and updated.
4. The accelerated reading method according to claim 3, characterized in that: The items in the frequency table are sorted as follows: the LBAs that will definitely be read at startup are set to the highest priority; then they are sorted from most to least according to the number of times they are read after startup, and the LBAs that have the same number of times of being read after startup are sorted from small to large according to the LBA range.
5. A system using the accelerated reading method according to any one of claims 1 to 4, comprising: An SSD body having a non-volatile memory and a DDR built therein; An AI data analysis module, used to monitor the operating status of the SSD in real time, record the access frequency of each LBA, and update the maintenance frequency table; A preloading control unit selects a corresponding LBA range according to the frequency table output by the AI data analysis module, and preloads data within the range into the DDR before the host issues a read command; The replacement strategy execution unit is used to remove data with fewer access times from the DDR space according to the latest frequency table when the DDR space is insufficient.
6. The system according to claim 5, characterized in that: The preloading control unit automatically performs a preloading operation when the SSD is idle.
7. The system according to claim 5, characterized in that: The replacement strategy execution unit also considers the remaining life and performance degradation of the SSD, and gives priority to replacing LBA range data that has a smaller impact on the overall performance.
