WO2020169065A1 - 基于内存受限 ssd 的预读取方法、装置和计算机设备 - Google Patents

基于内存受限 ssd 的预读取方法、装置和计算机设备 Download PDF

Info

Publication number
WO2020169065A1
WO2020169065A1 PCT/CN2020/076017 CN2020076017W WO2020169065A1 WO 2020169065 A1 WO2020169065 A1 WO 2020169065A1 CN 2020076017 W CN2020076017 W CN 2020076017W WO 2020169065 A1 WO2020169065 A1 WO 2020169065A1
Authority
WO
WIPO (PCT)
Prior art keywords
read
host
read command
module
command
Prior art date
Application number
PCT/CN2020/076017
Other languages
English (en)
French (fr)
Inventor
王猛
徐伟华
Original Assignee
深圳忆联信息系统有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳忆联信息系统有限公司 filed Critical 深圳忆联信息系统有限公司
Publication of WO2020169065A1 publication Critical patent/WO2020169065A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0862Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches with prefetch
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers

Definitions

  • This application relates to the technical field of solid state hard disks, and in particular to a pre-reading method, device and computer equipment based on a memory-constrained SSD.
  • SSD Solid State Disk
  • NAND With the evolution of the host interface, it has evolved from traditional SATA to PCIe, and the corresponding performance has also increased from 500MB/s to 3GB/s (PCIe Gen 3x4). With such high performance requirements, NAND must work in full-speed mode without idle time. In the actual operation of the host, it may not be able to issue enough requests in time. Take reading as an example. In order to achieve a rate of 3GB/s, it is generally necessary to start the pre-reading function based on the characteristics of sequential reading, and set the host in advance. The data is loaded into memory.
  • the read data will pass through the DRAM first, which is feasible.
  • the data read from NAND in order to reduce the data delay, generally no longer passes through the DRAM but is directly transmitted to the host through the high-speed SRAM inside the chip. Due to the small SRAM space, the previous strategy of pre-reading into memory is no longer effective.
  • One of the objectives of the embodiments of the present application is to provide a pre-reading method, device, and computer equipment based on a memory-limited SSD, which aims to solve the problem of low SSD read performance.
  • a pre-read method based on a memory-constrained SSD includes:
  • a pre-reading device based on a memory-constrained SSD includes:
  • An obtaining module is used to obtain a read command request submitted by the host, and the read command request includes a read command submitted by the host;
  • a judging module configured to judge whether the host is in a sequential read mode according to the read command information in the read command request;
  • Inserting a module the inserting module being used for notifying the pre-reading module to insert a pre-reading command when the host has no command input if the host is in the sequential read mode;
  • a loading module configured to preload data into a NAND cache register according to the pre-read command
  • the transmission module is used to directly initiate a data transmission operation when the subsequent host command is issued and hits.
  • a computer device including a memory, a processor, and a computer program stored in the memory and capable of being run on the processor. Steps of the pre-reading method for restricted SSDs.
  • a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, the steps of the memory-constrained SSD-based pre-reading method described in the first aspect are implemented.
  • this application predicts the sequential read sequence of the host by identifying sequential read requests, and triggers NAND when the host command is not issued in time
  • the initiation of the read command loads the data into the NAND cache register, and then directly transmits the data when the subsequent read command comes, ensuring the read performance bandwidth.
  • Figure 1 is a schematic diagram of a typical NAND composition
  • FIG. 2 is a schematic flowchart of a pre-read method based on a memory-constrained SSD in an embodiment of the application
  • FIG. 3 is a schematic flowchart of a pre-read method based on a memory-constrained SSD in another embodiment of the application
  • FIG. 4 is a schematic flowchart of a pre-read method based on a memory-constrained SSD in another embodiment of the application
  • FIG. 5 is a schematic flowchart of a pre-reading method based on a memory-constrained SSD in another embodiment of the application
  • Figure 6 is a schematic diagram of a typical read command SSD internal processing flow diagram
  • FIG. 7 is a schematic diagram of the internal processing flow of the read command SSD in an embodiment of the application.
  • Figure 8 is a typical NAND end command operation timing diagram
  • FIG. 9 is a sequence diagram of a command operation on the NAND side in an embodiment of the application.
  • FIG. 10 is a structural block diagram of a pre-reading device based on a memory-constrained SSD in an embodiment of the application
  • FIG. 11 is a structural block diagram of a pre-reading device based on a memory-constrained SSD in another embodiment of the application.
  • Fig. 12 is an internal structure diagram of a computer device in an embodiment of the application.
  • the typical NAND composition is as follows: DIE, a unit that can be operated independently and concurrently; Block, a unit that can be independently erased, the data in each physical location within it must be erased before the next write. ; Page, read-write unit, Page in the same physical block must be programmed in order: 0->1->2->3... There is a Cache Register in each DIE. When data is read, the data will be loaded from the internal Cell to this area first, and then transferred to the controller through the NAND interface.
  • the read performance requirements are very high.
  • the NAND side When the host command is insufficient, the NAND side will appear in a waiting idle state.
  • the SSD In order to avoid this idle state, for the sequential read scenario, the SSD will initiate an internal read request according to the sequence of sequential read when the host command is insufficient, and load the data into the memory in advance.
  • the read path In the latest PCIe interface SSD, in order to improve the read performance, the read path does not pass through the DRAM, so there is no memory space for buffering the pre-read data, so the performance will be reduced due to the interruption of the host command.
  • This application proposes a pre-reading method for memory-constrained SSDs.
  • the sequential read request is recognized to predict the sequential read sequence of the host, and the initiation of the NAND read command is triggered when the host command is not issued in time , Load the data into the NAND Cache Register, and then directly transmit the data when the subsequent read command comes, ensuring the read performance bandwidth.
  • a pre-reading method based on a memory-constrained SSD includes:
  • Step 202 Obtain a read command request submitted by the host, where the read command request includes the read command submitted by the host;
  • Step 204 Determine whether the host is in a sequential read mode according to the read command information in the read command request;
  • Step 206 If the host is in the sequential read mode, notify the pre-read module to insert the pre-read command when there is no command input from the host;
  • Step 208 pre-load data into the NAND cache register according to the pre-read command
  • Step 210 Directly initiate a data transmission operation when a subsequent host command is issued and hits.
  • a typical read command SSD internal processing flow includes: the host submits the read command to the front-end module of the SSD.
  • the SSD front-end module divides the command into mapping units (typically 4KB). Submit the operation request to the mapping table management module.
  • the mapping table management module is responsible for converting logical addresses into NAND physical addresses. Submit the operation request to the back-end module, and the back-end module initiates a NAND read request based on the physical address. Wait for the NAND read operation request to complete, at this time the data will be loaded into the NAND Cache Register. After the data is Ready, start the data transfer from the NAND Cache Register to the host.
  • FIG 7 shows the SSD internal module introduced in this embodiment. New processes of "Sequence Recognition” and “Pre-reading” are added: “Sequence Recognition” is used to determine whether the host is performing sequential reading. When the sequential read mode is recognized and the command pressure on the host side is insufficient, some special internal read operations are added in advance to ensure that the NAND side loads data into the Cache Register in advance.
  • a pre-reading method based on a memory-constrained SSD obtains a read command request submitted by the host, and the read command request includes the read command submitted by the host. Also includes:
  • Step 302 divide the read command into mapping units
  • Step 304 Submit a read command operation request to the mapping table management module, and convert the logical address into a NAND physical address through the mapping table management module;
  • Step 306 Submit a read command operation request to the back-end module, and initiate a NAND read request according to the NAND physical address through the back-end module;
  • Step 308 load data into the NAND cache register according to the NAND read request
  • Step 310 After the data preparation is completed, start the data transfer from the NAND cache register to the host.
  • the read command processing flow in this embodiment is as follows: the host submits the read command to the front-end module of the SSD.
  • the front-end module transmits the command information to the sequence recognition module, and according to the recent command information, the LBA accesses the space to determine whether it is in the sequence read mode.
  • the front-end module divides the command into mapping units (typically 4KB). Submit the operation request to the mapping table management module.
  • the mapping table management module is responsible for converting logical addresses into NAND physical addresses. Submit the operation request to the back-end module, and the back-end module initiates a NAND read request based on the physical address. Wait for the NAND read operation request to complete, at this time the data will be loaded into the NAND Cache Register.
  • the sequence recognition module determines that it is currently in the sequence read mode, it will notify the pre-reading module.
  • the pre-reading module identifies the module information (the LBA address space read by subsequent commands) according to the sequence, inserts a newly-added pre-read command, and loads the data into the NAND Cache Register.
  • the subsequent host sends a real read command and hits the pre-read data, the data transmission is directly initiated without waiting for the NAND read.
  • the read command request includes the read command submitted by the host; according to the read command information in the read command request, it is determined whether the host is in sequential read mode; if the host is in sequential read mode, When the host has no command input, the pre-read module is notified to insert the pre-read command; the data is pre-loaded into the NAND cache register according to the pre-read command; when the subsequent host command is issued, the data transmission operation is directly initiated.
  • This embodiment predicts the sequential read sequence of the host by identifying the sequential read request, triggers the initiation of the NAND read command when the host command is not issued in time, loads the data into the NAND cache register, and then directly performs the data when the subsequent read command comes. Transmission guarantees the read performance bandwidth.
  • a pre-read method based on a memory-limited SSD is provided.
  • the step of judging whether the host is in the sequential read mode according to the read command information in the read command request includes:
  • Step 402 Pass the read command to the sequence recognition module for recognition
  • Step 404 according to the recent read command information, judge whether the host is in the sequential read mode through the LBA access space.
  • a pre-reading method based on a memory-constrained SSD is provided, and the method further includes:
  • Step 502 When the host has no command input, if the sequence recognition module determines that it is currently in the sequence read mode, it notifies the pre-reading module;
  • Step 504 The pre-reading module inserts a newly-added pre-read command according to the sequence identification module information, and loads the pre-read data into the NAND cache register;
  • Step 506 When the subsequent host sends a real read command and hits the pre-read data, the data transmission is directly initiated.
  • FIG. 8 is a typical NAND-side command operation sequence diagram, which includes: the SSD issues a host read request to each DIE. Each DIE triggers the internal cell read, and the data is loaded into the Cache Register. The data is transferred to the host. At this time, if no further read commands are issued to the NAND, the NAND end is in an idle state. After the host issues a new command, the NAND Cell read and data transfer sequence will continue.
  • FIG. 9 shows a timing diagram of the NAND end command operation introduced in this embodiment.
  • the host does not issue a command, there is no longer waiting time on the NAND side, but the data is loaded into the Cache Register in advance.
  • the data transfer operation is directly initiated; compared with the SSD solution with DRAM, in the SSD with limited memory, the data is no longer transmitted to the DRAM in advance, but only loaded to the NAND itself In the Cache Register, there is no additional memory overhead.
  • this pre-reading mechanism the saturation of read operations on the NAND side under memory-constrained conditions can be guaranteed, thereby satisfying the read performance of the SSD.
  • a pre-reading device 1000 based on a memory-limited SSD including:
  • the obtaining module 1001 is used to obtain the read command request submitted by the host, and the read command request includes the read command submitted by the host;
  • the judging module 1002 is used to judge whether the host is in sequential read mode according to the read command information in the read command request;
  • Insert module 1003 for notifying the pre-reading module to insert a pre-reading command when the host has no command input if the host is in the sequential read mode;
  • the loading module 1004 is used to preload data into the NAND cache register according to the pre-read command
  • the transmission module 1005 is used to directly initiate a data transmission operation when a subsequent host command is issued and hits.
  • a pre-reading device 1000 based on a memory-constrained SSD is provided, and the device further includes a command processing module 1006 for:
  • the judging module 1002 is also used to:
  • the recent read command information it is judged whether the host is in the sequential read mode through the LBA access space.
  • the judging module 1002 is also used to:
  • the sequence recognition module determines that it is currently in the sequence read mode, it will notify the pre-reading module;
  • the pre-read module inserts a newly-added pre-read command according to the sequence identification module information, and loads the pre-read data into the NAND cache register;
  • pre-reading device based on the memory-constrained SSD please refer to the above limitation on the pre-reading method based on the memory-constrained SSD, which will not be repeated here.
  • a computer device is provided, and its internal structure diagram may be as shown in FIG. 12.
  • the computer equipment includes a processor, a memory, and a network interface connected through a system bus.
  • the processor of the computer device is used to provide calculation and control capabilities.
  • the memory of the computer device includes a non-volatile storage medium and an internal memory.
  • the non-volatile storage medium stores an operating system, a computer program, and a database.
  • the internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium.
  • the network interface of the computer device is used to communicate with an external terminal through a network connection.
  • the computer program is executed by the processor to realize a pre-reading method based on the memory-limited SSD.
  • FIG. 12 is only a block diagram of part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied.
  • the specific computer device may Including more or fewer parts than shown in the figure, or combining some parts, or having a different arrangement of parts.
  • a computer device which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor.
  • the processor implements the steps in the above method embodiments when the computer program is executed.
  • a computer-readable storage medium on which a computer program is stored, and the computer program is executed by a processor to implement the steps in the above method embodiments.
  • Non-volatile memory may include read only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory.
  • Volatile memory may include random access memory (RAM) or external cache memory.
  • RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous chain Channel (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Memory System Of A Hierarchy Structure (AREA)

Abstract

一种基于内存受限SSD的预读取方法、装置、计算机设备和存储介质,其中该方法包括:获取主机提交的读命令请求,读命令请求包括主机提交的读命令(S202);根据读命令请求中的读命令信息判断主机是否处于顺序读模式(S204);若主机处于顺序读模式,则当主机无命令输入时通知预读取模块插入预读取命令(S206);根据预读取命令将数据预先加载到NAND缓存寄存器中(S208);当后续所述主机命令下发命中时直接发起数据传输操作(S210)。该方法通过识别顺序读请求,预测主机顺序读序列,在主机命令下发不及时时触发NAND读命令的发起,将数据加载到NAND缓存寄存器中,进而在后续的读命令来时直接进行数据传输,保障了读性能带宽。

Description

基于内存受限SSD的预读取方法、装置和计算机设备
本申请要求于2019年2月22日在中国专利局提交的、申请号为201910133823.4、发明名称为“基于内存受限SSD的预读取方法、装置和计算机设备”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及固态硬盘技术领域,具体涉及一种基于内存受限SSD的预读取方法、装置和计算机设备。
背景技术
目前,SSD(Solid State Disk,固态硬盘)已经被广泛应用于各种场合,由于其在性能、功耗、环境适应性等方面的优秀指标,正逐步替换传统的硬盘。
随着主机接口的演进,已经从传统的SATA发展到PCIe,相应的性能也从500MB/s提升到3GB/s(PCIe Gen 3x4)。如此高的性能需求,对于NAND来说必须工作在全速模式,不能有闲置时间。而主机实际运作过程中,可能会不能及时下发足够多的请求,以读为例,为达到3GB/s的速率,一般要基于顺序读的特征,启动预读取功能,提前将主机所需数据加载到内存中。
这在传统的SSD中,因为有较大的DRAM缓冲区存在,读数据会先经过DRAM,是可行的。但随着性能需求的提升,为降低数据延迟,NAND读出来的数据一般不再经过DRAM而是直接经由芯片内部高速SRAM传输到主机。由于SRAM空间很小,既往的预读取到内存中的策略不再有效。
发明概述
技术问题
本申请实施例的目的之一在于:提供一种基于内存受限SSD的预读取方法、装置和计算机设备,旨在解决SSD读性能较低的问题。
问题的解决方案
技术解决方案
为解决上述技术问题,本申请实施例采用的技术方案是:
第一方面,提供了一种基于内存受限SSD的预读取方法,所述方法包括:
获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
若所述主机处于顺序读模式,则当所述主机无命令输入时通知预读取模块插入预读取命令;
根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
当后续所述主机命令下发命中时直接发起数据传输操作。
第二方面,提供了一种基于内存受限SSD的预读取装置,所述基于内存受限SSD的预读取装置包括:
获取模块,所述获取模块用于获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
判断模块,所述判断模块用于根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
插入模块,所述插入模块用于若所述主机处于顺序读模式,则当所述主机无命令输入时通知预读取模块插入预读取命令;
加载模块,所述加载模块用于根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
传输模块,所述传输模块用于当后续所述主机命令下发命中时直接发起数据传输操作。
第三方面,提供一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现第一方面所述的基于内存受限SSD的预读取方法的步骤。
第四方面,提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现第一方面所述的基于内存受限SSD的预读取方法的步骤。
本申请实施例提供的基于内存受限SSD的预读取方法、装置和计算机设备的有益效果在于:本申请通过识别顺序读请求,预测主机顺序读序列,在主机命令下发不及时时触发NAND读命令的发起,将数据加载到NAND缓存寄存器中,进 而在后续的读命令来时直接进行数据传输,保障了读性能带宽。
发明的有益效果
对附图的简要说明
附图说明
图1为典型的NAND的组成示意图;
图2为本申请一实施例中基于内存受限SSD的预读取方法的流程示意图;
图3为本申请另一实施例中基于内存受限SSD的预读取方法的流程示意图;
图4为本申请再一实施例中基于内存受限SSD的预读取方法的流程示意图;
图5为本申请又一实施例中基于内存受限SSD的预读取方法的流程示意图;
图6为典型的读命令SSD内部处理的流程示意图;
图7为本申请一实施例中的读命令SSD内部处理的流程示意图;
图8为典型的NAND端的命令操作时序图;
图9为本申请一实施例中的NAND端的命令操作时序图;
图10为本申请一实施例中基于内存受限SSD的预读取装置的结构框图;
图11为本申请另一实施例中基于内存受限SSD的预读取装置的结构框图;
图12为本申请一实施例中计算机设备的内部结构图。
发明实施例
本发明的实施方式
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定本申请。
如图1所示典型的NAND组成如下:DIE,可独立并发操作的单元;Block,可独立擦除的单元,其内各个物理位置的数据写入后在下一次写之前必须要将整个Block擦除;Page,读写单元,同一物理块内的Page必需按顺序编程:0->1->2->3...。每个DIE内有一个Cache Register,当读取数据时,数据会从内部Cell先加载到该区域,然后通过NAND接口传输给控制器。
在SSD产品中,读性能要求很高,当出现主机命令不足时候,NAND端则会出 现等待空闲状态。为避免出现该空闲状态,对于顺序读的场景,SSD内部会根据顺序读的序列,在主机命令不足时,发起内部读请求,预先把数据加载到内存中。而在最新的PCIe接口的SSD中,为了读性能的提升,其读通路不会经过DRAM,故而没有缓冲预读取数据的内存空间,所以会因为主机命令中断而导致性能下降。
本申请提出一种内存受限SSD的预读取方法,通过引入本申请中所提方案,通过识别顺序读请求,预测主机顺序读序列,在主机命令下发不及时时触发NAND读命令的发起,将数据加载到NAND Cache Register中,进而在后续的读命令来时直接进行数据传输,保障了读性能带宽。
在一个实施例中,如图2所示,提供了一种基于内存受限SSD的预读取方法,该方法包括:
步骤202,获取主机提交的读命令请求,读命令请求包括主机提交的读命令;
步骤204,根据读命令请求中的读命令信息判断主机是否处于顺序读模式;
步骤206,若主机处于顺序读模式,则当主机无命令输入时通知预读取模块插入预读取命令;
步骤208,根据预读取命令将数据预先加载到NAND缓存寄存器中;
步骤210,当后续主机命令下发命中时直接发起数据传输操作。
具体地,如图6所示为一个典型的读命令SSD内部处理流程包括:主机提交读命令到SSD的前端模块。SSD前端模块将命令分割成映射单元(典型如4KB)。提交操作请求到映射表管理模块。映射表管理模块负责把逻辑地址转换成NAND物理地址。提交操作请求到后端模块,后端模块根据物理地址发起对NAND读请求。等待NAND读操作请求完成,此时数据会加载到NAND Cache Register中。数据Ready后,启动数据从NAND Cache Register到主机的传输。
如图7所示为本实施例引入后的SSD内部模块。新增了“顺序识别”、“预读取”的流程:“顺序识别”用来判断主机是否在进行顺序读,若是则意味着工作在高性能模式;“预读取”的流程则包括当识别为顺序读模式,且主机端命令压力不足时,提前补充一些特殊的内部读操作,用以保障NAND端提前把数据加载到Cache Register中。
在一个实施例中,如图3所示,提供了一种基于内存受限SSD的预读取方法,该方法在获取主机提交的读命令请求,读命令请求包括主机提交的读命令的步骤之后还包括:
步骤302,将读命令分割成映射单元;
步骤304,提交读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
步骤306,提交读命令操作请求到后端模块,并通过后端模块根据NAND物理地址发起对NAND读请求;
步骤308,根据NAND读请求将数据加载到NAND缓存寄存器中;
步骤310,数据准备完成之后,启动数据从NAND缓存寄存器到主机的传输。
具体地,结合参考图7,本实施例中的读命令处理流程如下:主机提交读命令到SSD的前端模块。前端模块将命令信息传递给顺序识别模块,根据近期的命令信息,LBA访问空间,判断是否处于顺序读模式。前端模块将命令分割成映射单元(典型如4KB)。提交操作请求到映射表管理模块。映射表管理模块负责把逻辑地址转换成NAND物理地址。提交操作请求到后端模块,后端模块根据物理地址发起对NAND读请求。等待NAND读操作请求完成,此时数据会加载到NAND Cache Register中。数据Ready后,启动数据从NAND Cache Register到主机的传输。当主机无命令输入时,若顺序识别模块判断当前处于顺序读模式,则通知预读取模块。预读取模块根据顺序识别模块信息(后续命令读的LBA地址空间),插入新增的预读取命令,将数据加载到NAND Cache Register中。当后续主机下发真正的读取命令时,命中该预读取数据,则直接发起数据传输,而不用再等待NAND读。
在本实施例中,通过获取主机提交的读命令请求,读命令请求包括主机提交的读命令;根据读命令请求中的读命令信息判断主机是否处于顺序读模式;若主机处于顺序读模式,则当主机无命令输入时通知预读取模块插入预读取命令;根据预读取命令将数据预先加载到NAND缓存寄存器中;当后续主机命令下发命中时直接发起数据传输操作。本实施例通过识别顺序读请求,预测主机顺序读序列,在主机命令下发不及时时触发NAND读命令的发起,将数据加载到NAND 缓存寄存器中,进而在后续的读命令来时直接进行数据传输,保障了读性能带宽。
在一个实施例中,如图4所示,提供了一种基于内存受限SSD的预读取方法,该方法中根据读命令请求中的读命令信息判断主机是否处于顺序读模式的步骤包括:
步骤402,将读命令传递给顺序识别模块进行识别;
步骤404,根据近期的读命令信息,通过LBA访问空间判断主机是否处于顺序读模式。
在一个实施例中,如图5所示,提供了一种基于内存受限SSD的预读取方法,该方法还包括:
步骤502,当主机无命令输入时,若顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
步骤504,预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
步骤506,当后续主机下发真正的读取命令命中预读取数据时,则直接发起数据传输。
具体地,如图8所示为典型的NAND端的命令操作时序图,包括:SSD对每个DIE下发主机读请求。各个DIE触发内部Cell读,数据加载到Cache Register中。数据传输给主机。此时若无进一步的读命令下发到NAND上,则NAND端处于空闲状态。主机下发新的命令后,再继续NAND Cell读取以及数据传输序列。
在本实施例中,如图9所示为本实施例引入后的NAND端命令操作时序图。与传统的SSD相比,由于引入了在特定模式下的内部预读取,所以在主机无命令下发时,NAND端不存在较长的等待时间,而是提前将数据加载到Cache Register中。当后续主机命令下发命中时,直接发起数据传输操作;而相比于带DRAM的SSD方案,在内存受限的SSD中,不再提前将数据传输到DRAM中,而是仅加载到NAND自身的Cache Register中,所以无额外的内存开销。通过该预读取机制,可以保障内存受限情形下的NAND端读操作的饱和,进而满足了SSD的读性能。
应该理解的是,虽然图2-5的流程图中的各个步骤按照箭头的指示依次显示, 但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,这些步骤可以以其它的顺序执行。而且,图2-5中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,这些子步骤或者阶段的执行顺序也不必然是依次进行,而是可以与其它步骤或者其它步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。
在一个实施例中,如图10所示,提供了一种基于内存受限SSD的预读取装置1000,包括:
获取模块1001,用于获取主机提交的读命令请求,读命令请求包括主机提交的读命令;
判断模块1002,用于根据读命令请求中的读命令信息判断主机是否处于顺序读模式;
插入模块1003,用于若主机处于顺序读模式,则当主机无命令输入时通知预读取模块插入预读取命令;
加载模块1004,用于根据预读取命令将数据预先加载到NAND缓存寄存器中;
传输模块1005,用于当后续主机命令下发命中时直接发起数据传输操作。
在一个实施例中,如图11所示,提供了一种基于内存受限SSD的预读取装置1000,该装置还包括命令处理模块1006,用于:
将读命令分割成映射单元;
提交读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
提交读命令操作请求到后端模块,并通过后端模块根据所述NAND物理地址发起对NAND读请求;
根据NAND读请求将数据加载到NAND缓存寄存器中;
数据准备完成之后,启动数据从NAND缓存寄存器到所述主机的传输。
在一个实施例中,判断模块1002还用于:
将读命令传递给顺序识别模块进行识别;
根据近期的读命令信息,通过LBA访问空间判断主机是否处于顺序读模式。
在一个实施例中,判断模块1002还用于:
当主机无命令输入时,若顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
当后续主机下发真正的读取命令命中所述预读取数据时,则直接发起数据传输。
关于基于内存受限SSD的预读取装置的具体限定可以参见上文中对于基于内存受限SSD的预读取方法的限定,在此不再赘述。
在一个实施例中,提供了一种计算机设备,其内部结构图可以如图12所示。该计算机设备包括通过系统总线连接的处理器、存储器以及网络接口。其中,该计算机设备的处理器用于提供计算和控制能力。该计算机设备的存储器包括非易失性存储介质、内存储器。该非易失性存储介质存储有操作系统、计算机程序和数据库。该内存储器为非易失性存储介质中的操作系统和计算机程序的运行提供环境。该计算机设备的网络接口用于与外部的终端通过网络连接通信。该计算机程序被处理器执行时以实现一种基于内存受限SSD的预读取方法。
本领域技术人员可以理解,图12中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。
在一个实施例中,提供了一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行计算机程序时实现以上各个方法实施例中的步骤。
在一个实施例中,提供了一种计算机可读存储介质,其上存储有计算机程序,计算机程序被处理器执行时实现以上各个方法实施例中的步骤。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一非易失性计算机可读取存储介质中,该计算机程序在执行时,可包括如上述各方 法的实施例的流程。其中,本申请所提供的各实施例中所使用的对存储器、存储、数据库或其它介质的任何引用,均可包括非易失性和/或易失性存储器。非易失性存储器可包括只读存储器(ROM)、可编程ROM(PROM)、电可编程ROM(EPROM)、电可擦除可编程ROM(EEPROM)或闪存。易失性存储器可包括随机存取存储器(RAM)或者外部高速缓冲存储器。作为说明而非局限,RAM以多种形式可得,诸如静态RAM(SRAM)、动态RAM(DRAM)、同步DRAM(SDRAM)、双数据率SDRAM(DDRSDRAM)、增强型SDRAM(ESDRAM)、同步链路(Synchlink)DRAM(SLDRAM)、存储器总线(Rambus)直接RAM(RDRAM)、直接存储器总线动态RAM(DRDRAM)、以及存储器总线动态RAM(RDRAM)等。
以上所述实施例仅表达了本申请的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本申请构思的前提下,还可以做出若干变形和改进,这些都属于本申请的保护范围。因此,本申请专利的保护范围应以所附权利要求为准。

Claims (16)

  1. 一种基于内存受限SSD的预读取方法,其特征在于,所述方法包括:
    获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
    根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
    若所述主机处于顺序读模式,则当所述主机无命令输入时通知预读取模块插入预读取命令;
    根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
    当后续所述主机命令下发命中时直接发起数据传输操作。
  2. 根据权利要求1所述的基于内存受限SSD的预读取方法,其特征在于,在所述获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令的步骤之后,还包括:
    将所述读命令分割成映射单元;
    提交所述读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
    提交所述读命令操作请求到后端模块,并通过后端模块根据所述NAND物理地址发起对NAND读请求;
    根据所述NAND读请求将数据加载到NAND缓存寄存器中;
    数据准备完成之后;启动数据从所述NAND缓存寄存器到所述主机的传输。
  3. 根据权利要求1或2所述的基于内存受限SSD的预读取方法,其特征在于,所述根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式的步骤包括:
    将所述读命令传递给顺序识别模块进行识别;
    根据近期的读命令信息,通过LBA访问空间判断所述主机是否处于顺序读模式。
  4. 根据权利要求3所述的基于内存受限SSD的预读取方法,其特征在于,所述方法还包括:
    当所述主机无命令输入时,若所述顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
    所述预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
    当后续主机下发真正的读取命令命中所述预读取数据时,则直接发起数据传输。
  5. 一种基于内存受限SSD的预读取装置,其特征在于,所述基于内存受限SSD的预读取装置包括:
    获取模块,所述获取模块用于获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
    判断模块,所述判断模块用于根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
    插入模块,所述插入模块用于若所述主机处于顺序读模式,则当所述主机无命令输入时通知预读取模块插入预读取命令;
    加载模块,所述加载模块用于根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
    传输模块,所述传输模块用于当后续所述主机命令下发命中时直接发起数据传输操作。
  6. 根据权利要求5所述的基于内存受限SSD的预读取装置,其特征在于,所述装置还包括命令处理模块,所述命令处理模块用于:
    将所述读命令分割成映射单元;
    提交所述读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
    提交所述读命令操作请求到后端模块,并通过后端模块根据所述NAND物理地址发起对NAND读请求;
    根据所述NAND读请求将数据加载到NAND缓存寄存器中;
    数据准备完成之后,启动数据从所述NAND缓存寄存器到所述主机的传输。
  7. 根据权利要求5或6所述的基于内存受限SSD的预读取装置,其特征在于,所述判断模块还用于:
    将所述读命令传递给顺序识别模块进行识别;
    根据近期的读命令信息,通过LBA访问空间判断所述主机是否处于顺序读模式。
  8. 根据权利要求7所述的基于内存受限SSD的预读取装置,其特征在于,所述判断模块还用于:
    当所述主机无命令输入时,若所述顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
    所述预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
    当后续主机下发真正的读取命令命中所述预读取数据时,则直接发起数据传输。
  9. 一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时实现如下步骤:
    获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
    根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
    若所述主机处于顺序读模式,则当所述主机无命令输入时通知预读取模块插入预读取命令;
    根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
    当后续所述主机命令下发命中时直接发起数据传输操作。
  10. 根据权利要求9所述的计算机设备,其特征在于,所述处理器执行所述计算机程序时还实现如下步骤:
    将所述读命令分割成映射单元;
    提交所述读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
    提交所述读命令操作请求到后端模块,并通过后端模块根据所述NAND物理地址发起对NAND读请求;
    根据所述NAND读请求将数据加载到NAND缓存寄存器中;
    数据准备完成之后;启动数据从所述NAND缓存寄存器到所述主机的传输。
  11. 根据权利要求9或10所述的计算机设备,其特征在于,所述处理器执行所述计算机程序时还实现如下步骤:
    将所述读命令传递给顺序识别模块进行识别;
    根据近期的读命令信息,通过LBA访问空间判断所述主机是否处于顺序读模式。
  12. 根据权利要求11所述的计算机设备,其特征在于,所述处理器执行所述计算机程序时还实现如下步骤:
    当所述主机无命令输入时,若所述顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
    所述预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
    当后续主机下发真正的读取命令命中所述预读取数据时,则直接发起数据传输。
  13. 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如下步骤:
    获取主机提交的读命令请求,所述读命令请求包括主机提交的读命令;
    根据所述读命令请求中的读命令信息判断所述主机是否处于顺序读模式;
    若所述主机处于顺序读模式,则当所述主机无命令输入时通知预 读取模块插入预读取命令;
    根据所述预读取命令将数据预先加载到NAND缓存寄存器中;
    当后续所述主机命令下发命中时直接发起数据传输操作。
  14. 根据权利要求13所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行时还实现如下步骤:
    将所述读命令分割成映射单元;
    提交所述读命令操作请求到映射表管理模块,并通过映射表管理模块将逻辑地址转换成NAND物理地址;
    提交所述读命令操作请求到后端模块,并通过后端模块根据所述NAND物理地址发起对NAND读请求;
    根据所述NAND读请求将数据加载到NAND缓存寄存器中;
    数据准备完成之后;启动数据从所述NAND缓存寄存器到所述主机的传输。
  15. 根据权利要求13或14所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行时还实现如下步骤:
    将所述读命令传递给顺序识别模块进行识别;
    根据近期的读命令信息,通过LBA访问空间判断所述主机是否处于顺序读模式。
  16. 根据权利要求15所述的计算机可读存储介质,其特征在于,所述计算机程序被处理器执行时还实现如下步骤:
    当所述主机无命令输入时,若所述顺序识别模块判断当前处于顺序读模式,则通知预读取模块;
    所述预读取模块根据顺序识别模块信息插入新增的预读取命令,将预读取数据加载到NAND缓存寄存器中;
    当后续主机下发真正的读取命令命中所述预读取数据时,则直接发起数据传输。
PCT/CN2020/076017 2019-02-22 2020-02-20 基于内存受限 ssd 的预读取方法、装置和计算机设备 WO2020169065A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910133823.4 2019-02-22
CN201910133823.4A CN109918023A (zh) 2019-02-22 2019-02-22 基于内存受限ssd的预读取方法、装置和计算机设备

Publications (1)

Publication Number Publication Date
WO2020169065A1 true WO2020169065A1 (zh) 2020-08-27

Family

ID=66962046

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/076017 WO2020169065A1 (zh) 2019-02-22 2020-02-20 基于内存受限 ssd 的预读取方法、装置和计算机设备

Country Status (2)

Country Link
CN (1) CN109918023A (zh)
WO (1) WO2020169065A1 (zh)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109918023A (zh) * 2019-02-22 2019-06-21 深圳忆联信息系统有限公司 基于内存受限ssd的预读取方法、装置和计算机设备
CN112214157B (zh) * 2019-07-10 2023-11-03 慧荣科技股份有限公司 主机输出输入命令的执行装置及方法及存储介质
WO2021184141A1 (en) 2020-03-15 2021-09-23 Micron Technology, Inc. Pre-load techniques for improved sequential read
CN112084121A (zh) * 2020-09-11 2020-12-15 深圳佰维存储科技股份有限公司 硬盘预读方法、装置、计算机可读存储介质及电子设备
CN112256338B (zh) * 2020-10-27 2023-12-05 记忆科技(深圳)有限公司 Soc启动方法、装置、计算机设备及存储介质
CN112799589B (zh) * 2021-01-14 2023-07-14 新华三大数据技术有限公司 一种数据读取方法及装置
CN113835640A (zh) * 2021-09-27 2021-12-24 深圳忆联信息系统有限公司 闪存缓存清空的实现方法、装置、计算机设备及存储介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1287311A (zh) * 1999-01-29 2001-03-14 国际商业机器公司 一种用组预测来降低在组相关高速缓存器中的执行时间的方法及设备
US6397292B1 (en) * 1999-08-19 2002-05-28 Emc Corporation Asymmetrical striping of mirrored storage device arrays and concurrent access to even tracks in the first array and odd tracks in the second array to improve data access performance
CN1890637A (zh) * 2003-12-19 2007-01-03 英特尔公司 基于垃圾收集器分析与对象的布局动态插入预取指令的方法和装置
CN101976182A (zh) * 2010-11-15 2011-02-16 记忆科技(深圳)有限公司 一种固态硬盘预读取的方法及其装置
CN107273053A (zh) * 2017-06-22 2017-10-20 郑州云海信息技术有限公司 一种数据读取的方法与装置
CN108733583A (zh) * 2018-05-28 2018-11-02 至誉科技(武汉)有限公司 提高NVMe SSD顺序数据读取性能的预读方法及系统
CN109918023A (zh) * 2019-02-22 2019-06-21 深圳忆联信息系统有限公司 基于内存受限ssd的预读取方法、装置和计算机设备

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102298508B (zh) * 2011-09-07 2014-08-06 记忆科技(深圳)有限公司 基于流的固态硬盘预读取的方法及装置
CN108595110B (zh) * 2018-03-07 2021-12-14 深圳忆联信息系统有限公司 一种利用Nand特性提高读性能的方法及固态硬盘

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1287311A (zh) * 1999-01-29 2001-03-14 国际商业机器公司 一种用组预测来降低在组相关高速缓存器中的执行时间的方法及设备
US6397292B1 (en) * 1999-08-19 2002-05-28 Emc Corporation Asymmetrical striping of mirrored storage device arrays and concurrent access to even tracks in the first array and odd tracks in the second array to improve data access performance
CN1890637A (zh) * 2003-12-19 2007-01-03 英特尔公司 基于垃圾收集器分析与对象的布局动态插入预取指令的方法和装置
CN101976182A (zh) * 2010-11-15 2011-02-16 记忆科技(深圳)有限公司 一种固态硬盘预读取的方法及其装置
CN107273053A (zh) * 2017-06-22 2017-10-20 郑州云海信息技术有限公司 一种数据读取的方法与装置
CN108733583A (zh) * 2018-05-28 2018-11-02 至誉科技(武汉)有限公司 提高NVMe SSD顺序数据读取性能的预读方法及系统
CN109918023A (zh) * 2019-02-22 2019-06-21 深圳忆联信息系统有限公司 基于内存受限ssd的预读取方法、装置和计算机设备

Also Published As

Publication number Publication date
CN109918023A (zh) 2019-06-21

Similar Documents

Publication Publication Date Title
WO2020169065A1 (zh) 基于内存受限 ssd 的预读取方法、装置和计算机设备
US10884661B2 (en) Command queuing
JP6224253B2 (ja) フラッシュメモリ内に記憶されたデータの推測的プリフェッチ
US9141549B2 (en) Memory system with read and write caches and method of controlling memory system with read and write caches
US9696934B2 (en) Hybrid solid state drive (SSD) using PCM or other high performance solid-state memory
US20130326113A1 (en) Usage of a flag bit to suppress data transfer in a mass storage system having non-volatile memory
US11360705B2 (en) Method and device for queuing and executing operation commands on a hard disk
US9348747B2 (en) Solid state memory command queue in hybrid device
US20200379684A1 (en) Predictive Data Transfer based on Availability of Media Units in Memory Sub-Systems
KR20090032821A (ko) 하드디스크 드라이브의 선반입 방법, 이에 적합한 기록매체 그리고 이에 적합한 장치
CN108139994B (zh) 内存访问方法及内存控制器
US11188256B2 (en) Enhanced read-ahead capability for storage devices
US11132145B2 (en) Techniques for reducing write amplification on solid state storage devices (SSDs)
US20100169550A1 (en) Semiconductor memory device, data transfer device, and method of controlling semiconductor memory device
WO2023124571A1 (zh) 一种存储介质失效的处理方法、装置和固态硬盘
CN114253483B (zh) 基于命令的写缓存管理方法、装置、计算机设备及存储介质
CN111026678B (zh) 基于固态硬盘的缓存设计方法、装置及计算机设备
TWI474254B (zh) 用於在一記憶體系統中執行命令的方法與裝置及資料儲存系統
TWI747660B (zh) 多閃存晶片的資料讀取方法及裝置以及電腦程式產品
WO2023103495A1 (zh) 固态硬盘映射表延迟更新方法、装置、计算机设备及存储介质
US11449428B2 (en) Enhanced read-ahead capability for storage devices
US20220197548A1 (en) Memory controller and storage device including the same
CN116126239B (zh) 一种提高zns固态硬盘nor flash写入性能的方法
US20240143512A1 (en) Write buffer linking for easy cache reads
JP6844895B1 (ja) ストレージ装置およびストレージ方法

Legal Events

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

Ref document number: 20759555

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20759555

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 20759555

Country of ref document: EP

Kind code of ref document: A1

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 20.04.2022)

122 Ep: pct application non-entry in european phase

Ref document number: 20759555

Country of ref document: EP

Kind code of ref document: A1