WO2023045407A1 - 一种i/o请求处理方法、装置、设备及可读存储介质 - Google Patents
一种i/o请求处理方法、装置、设备及可读存储介质 Download PDFInfo
- Publication number
- WO2023045407A1 WO2023045407A1 PCT/CN2022/097619 CN2022097619W WO2023045407A1 WO 2023045407 A1 WO2023045407 A1 WO 2023045407A1 CN 2022097619 W CN2022097619 W CN 2022097619W WO 2023045407 A1 WO2023045407 A1 WO 2023045407A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- mapping
- sub
- mapping table
- target
- unaligned
- Prior art date
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 19
- 238000013507 mapping Methods 0.000 claims abstract description 647
- 238000004590 computer program Methods 0.000 claims description 12
- 230000003321 amplification Effects 0.000 abstract description 21
- 238000003199 nucleic acid amplification method Methods 0.000 abstract description 21
- 230000000694 effects Effects 0.000 abstract description 2
- 230000002035 prolonged effect Effects 0.000 abstract 1
- 239000013589 supplement Substances 0.000 abstract 1
- 235000019580 granularity Nutrition 0.000 description 90
- 238000000034 method Methods 0.000 description 27
- 230000000295 complement effect Effects 0.000 description 4
- 238000010586 diagram Methods 0.000 description 4
- 230000008676 import Effects 0.000 description 2
- 239000007787 solid Substances 0.000 description 2
- 238000004364 calculation method Methods 0.000 description 1
- 230000008094 contradictory effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000004064 recycling Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/0614—Improving the reliability of storage systems
- G06F3/0616—Improving the reliability of storage systems in relation to life time, e.g. increasing Mean Time Between Failures [MTBF]
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0638—Organizing or formatting or addressing of data
- G06F3/064—Management of blocks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0646—Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
- G06F3/0652—Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0668—Interfaces specially adapted for storage systems adopting a particular infrastructure
- G06F3/0671—In-line storage system
- G06F3/0673—Single storage device
- G06F3/0679—Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]
Definitions
- the present application relates to the field of computer technology, and in particular to an I/O request processing method, device, device and readable storage medium.
- the mapping table in the hard disk writes data with a fixed-size mapping granularity. For example, if the mapping granularity of the mapping table is 4K, then it is required to write data with a size of 4K. When you want to write data smaller than 4K (such as 1K data), you need to read 4K data from the hard disk first, then merge the 1K data to be written at this time into the read 4K data, and then write The merged 4K data is sent to the hard disk to complete the writing of 1K data.
- 4K such as 1K data
- the purpose of the present application is to provide an I/O request processing method, device, device and readable storage medium, so as to reduce the read amplification and write amplification of the hard disk.
- the specific plan is as follows:
- the present application provides a method for processing an I/O request, which is applied to a solid-state hard disk, including:
- the main mapping The table is the upper-level mapping table of the highest-level sub-mapping table, and any mapping item in the main mapping table and any sub-mapping table has a mapping relationship with the physical address or all mapping items in the next-level mapping table; N is a positive integer not less than 1;
- the target sub-mapping table whose sub-mapping granularity is not greater than the size of the non-aligned I/O is queried for the first time, it is determined whether the size of the non-aligned I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table;
- it also includes:
- the target sub-mapping table is queried for the first time, but the size of the unaligned I/O is not an integer multiple of the sub-mapping granularity, then determine the target I/O from the unaligned I/O; the target The size of the I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table;
- it also includes:
- next-level sub-mapping table for the lowest-level sub-mapping table; the sub-mapping granularity of the created next-level sub-mapping table can be divisible by the size of the unaligned I/O;
- the creating a next-level sub-mapping table for the lowest-level sub-mapping table includes:
- the target table is determined as the created next-level sub-mapping table.
- the determining the number of mapping items in the target table includes:
- it also includes:
- the non-aligned I/O is split from the I/O request based on the main mapping granularity, and there is a sub-mapping granularity in the sub-mapping tables of N levels that can be controlled by the size of the non-aligned I/O
- the object sub-mapping table that is divisible then write the non-aligned I/O to the corresponding physical address, and record the mapping between the logical address of the non-aligned I/O and the corresponding physical address in the object sub-mapping table relation.
- it also includes:
- mapping entry points to said other physical address.
- it also includes:
- the alignment I/O is split from the I/O request based on the main mapping granularity, write the alignment I/O to the corresponding physical address, and record the alignment I/O in the main mapping table The mapping relationship between the logical address of /O and the corresponding physical address.
- the present application provides an I/O request processing device applied to a solid-state hard disk, including:
- the receiving module is used to receive the I/O request sent by the host;
- the split module is used to query the preset sub-maps of N levels one by one from the high level to the low level if the unaligned I/O is split from the I/O request based on the main mapping granularity of the main mapping table table; wherein, the main mapping table is the upper-level mapping table of the highest-level sub-mapping table, and any mapping item in the main mapping table and any sub-mapping table is related to the physical address or all mappings in the next-level mapping table All items have a mapping relationship; N is a positive integer not less than 1;
- the non-aligned I/O processing module is used to determine whether the size of the non-aligned I/O is the target sub-map if the sub-mapping granularity is not greater than the size of the non-aligned I/O is queried for the first time. Integer multiples of the sub-mapping granularity of the table; if so, write the non-aligned I/O to the target physical address, and record the target logical address of the non-aligned I/O and the target sub-mapping table in the target sub-mapping table The mapping relationship between target physical addresses.
- the present application provides an electronic device, including:
- a processor configured to execute the computer program, so as to implement the aforementioned disclosed I/O request processing method.
- the present application provides a readable storage medium for storing a computer program, wherein when the computer program is executed by a processor, the aforementioned disclosed I/O request processing method is implemented.
- the present application provides a method for processing I/O requests, which is applied to solid-state hard drives, including: receiving the I/O request sent by the host; If the non-aligned I/O is split in the middle, then query the sub-mapping tables of N preset levels one by one from the high level to the low level; wherein, the main mapping table is the upper-level mapping table of the sub-mapping table of the highest level, and the Any mapping item in the main mapping table and any sub-mapping table has a mapping relationship with the physical address or all mapping items in the next-level mapping table; N is a positive integer not less than 1; if the sub-mapping granularity is not If the target sub-mapping table is greater than the size of the non-aligned I/O, it is judged whether the size of the non-aligned I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table; if so, then write the non-
- main mapping table and N sub-mapping tables in the solid-state hard disk provided by this application, and these mapping tables are arranged from high to low according to the level or mapping granularity (that is, the size of the mapping item): main mapping table-highest Level sub-mapping table-...---the lowest level sub-mapping table, and there is a mapping relationship between adjacent mapping tables (that is, mapping tables of upper and lower levels).
- the N levels of sub-mapping tables can be queried one by one to complete its write operation.
- the target sub-mapping table whose sub-mapping granularity is not larger than the size of the unaligned I/O is queried for the first time, it is judged whether the size of the unaligned I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table; if so, it indicates that the target
- the sub-mapping granularity of the sub-mapping table matches the size of the current unaligned I/O, and there is no need to read adjacent data from the hard disk to complement the unaligned I/O, and there is no need to write data larger than the size of the current unaligned I/O.
- Data directly write the current non-aligned I/O to the target physical address, and record the mapping relationship between the target logical address of the non-aligned I/O and the target physical address in the target sub-mapping table. That is to say: for non-aligned I/O, among the many sub-mapping tables provided by this application, a sub-mapping table that can directly complete non-aligned I/O can be found, thereby reducing the read-write amplification of the hard disk and improving the use of the hard disk. life.
- an I/O request processing device, device, and readable storage medium provided by the present application also have the above-mentioned technical effects.
- FIG. 1 is a flowchart of a method for processing an I/O request disclosed in the present application
- Fig. 2 is the mapping schematic diagram of the adjacent upper and lower two-level mapping tables disclosed in the present application;
- FIG. 3 is a schematic diagram of non-aligned I/O writing disclosed in the present application.
- FIG. 4 is a schematic diagram of an I/O request processing device disclosed in the present application.
- FIG. 5 is a schematic diagram of an electronic device disclosed in the present application.
- the present application provides an I/O request processing solution, which can reduce the read/write amplification of the hard disk and improve the service life of the hard disk.
- the embodiment of the present application discloses a method for processing an I/O request, which is applied to a solid-state hard disk, including:
- the size of the I/O to be written in the I/O request issued by the host may be greater than or smaller than the main mapping granularity of the main mapping table.
- the size of the I/O to be written is an integer multiple of the main mapping granularity of the main mapping table, it is considered that the current alignment I/O can be completed directly without reading adjacent data pairs from the hard disk. Unaligned I/O is complemented, and there is no need to write data larger than the current I/O size, thus reducing write amplification and read amplification.
- the size of the I/O to be written is smaller than the main mapping granularity of the main mapping table, it is considered that the currently written I/O is an unaligned I/O.
- N levels of sub-mapping tables can be used to treat the current I/O as It is processed as aligned I/O, so write amplification and read amplification are also reduced.
- the main mapping table is the upper level mapping table of the highest level sub-mapping table, and any mapping item in the main mapping table and any sub-mapping table has a mapping relationship with the physical address or all mapping items in the next-level mapping table ;
- main mapping table there is one main mapping table and N sub-mapping tables, and these mapping tables are arranged from high to low according to the level or mapping granularity (that is, the size of the mapping item): main mapping table- -The highest level sub-mapping table-...---the lowest level sub-mapping table, and there is a mapping relationship between adjacent mapping tables (ie: upper and lower level mapping tables).
- mapping table For any mapping table, the product of the mapping granularity and the number of mapping items in the table is the size of the overall physical address space mapped by the mapping table. Any mapping item in a mapping table is used to record the mapping relationship between logical addresses and physical addresses. Each mapping item in a mapping table can point to the next-level mapping table, so there are multiple sub-mapping tables at the same level, but there is only one main mapping table.
- mapping table in FIG. 2 is the main mapping table, then this mapping table does not have an upper-level mapping table. If the upper-level mapping table in FIG. 2 is not the main mapping table, then the mapping table has an upper-level mapping table. It can be seen from Figure 2 that a certain mapping item in the upper-level mapping table can point to all mapping items in the lower-level mapping table, that is, the physical address pointed to by this mapping item in the upper-level mapping table A finer-grained division is made in the next level of mapping table. In FIG. 2, the physical address p represents the writing position of a certain non-aligned I/O.
- the main mapping granularity of the main mapping table is 4K, which means that a mapping entry in the main mapping table points to a physical address space of 4K size.
- the sub-mapping granularity of sub-mapping table 1 (the highest-level sub-mapping table) is 2K, which means that a mapping entry in this sub-mapping table points to a physical address space of 2K size.
- the sub-mapping granularity of sub-mapping table 1 (the lowest level sub-mapping table) is 1K, which means that a mapping entry in the sub-mapping table points to a physical address space of 1K size.
- the levels of these three mapping tables from high to low are: main mapping table--sub-mapping table 1--sub-mapping table 2, and the size of the mapping items (that is, the size of the mapping granularity) of the mapping tables of these three levels are: 4K-2K-1K.
- mapping relationship between adjacent mapping tables is: a certain mapping item in the main mapping table points to the overall physical address space size of the sub-mapping table 1 at the next level, specifically: A 4K mapping entry in the mapping table is presented as two 2K mapping entries in sub-mapping table 1.
- a mapping item in sub-mapping table 1 points to the overall physical address space size of sub-mapping table 2 at the next level, specifically: a 2K mapping item in sub-mapping table 1 is in sub-mapping table 2 Rendered as 2 map entries of size 1K.
- mapping granularity of the main mapping table and sub-mapping table 2 are respectively: 4K-1K
- the two The mapping relationship between them is as follows: a 4K mapping item in the main mapping table is presented as four 1K mapping items in the sub-mapping table 2.
- sub-mapping table 1 is only used to determine the mapping items in the main mapping table and those in sub-mapping table 2 The mapping relationship between mapping items.
- the target sub-mapping table whose sub-mapping granularity is not greater than the size of the unaligned I/O is queried for the first time, write Import the unaligned I/O to the target physical address, and record the mapping relationship between the target logical address of the unaligned I/O and the target physical address in the target sub-mapping table.
- each sub-mapping table is queried in turn.
- the target sub-mapping table whose sub-mapping granularity is not larger than the size of unaligned I/O is queried for the first time, it indicates that the target sub-mapping table can be directly written All or part of the I/O in the current unaligned I/O, if the size of the unaligned I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table, it indicates that the target sub-mapping table can be directly written For all the I/Os in the current non-aligned I/O, then write the non-aligned I/O to the target physical address, and record the distance between the target logical address and the target physical address of the non-aligned I/O in the target sub-mapping table The mapping relationship reduces write amplification and read amplification.
- the size of the unaligned I/O split from the I/O request is 2K
- the size of the mapping items in the three levels of mapping tables are "4K (main mapping table) - 2K (sub-mapping table 1 )-1K (sub-mapping table 2)”
- the target sub-mapping table queried for the first time is sub-mapping table 1
- the sub-mapping granularity 2K of sub-mapping table 1 is not greater than the size of unaligned I/O 2K
- the size of unaligned I/O 2K is 1 times the sub-mapping granularity 2K of sub-mapping table 1, so the writing of non-aligned I/O can be completed directly based on sub-mapping table 1, and in sub-mapping table 1
- a mapping entry of (the mapping entry has a mapping relationship with a mapping entry in the main mapping table, and this mapping entry in the main mapping table indicates the target logical address of the current unaligned I/
- splitting the unaligned I/O from the I/O request includes: splitting the unaligned I/O from the I/O request according to the size of the main mapping granularity of the main mapping table. For example, if an I/O request needs to write 7K data, and the main mapping granularity is 4K, then the aligned I/O in the I/O request is 4K, and the unaligned I/O is 3K. Assuming that the I/O request is to write 35K data, and the main mapping granularity is 4K, then the aligned I/O in the I/O request is 32K, and the unaligned I/O is 1K.
- the I/O request needs to write 3K data, and the main mapping granularity is 4K, so the aligned I/O in the I/O request is 0K, and the unaligned I/O is 3K.
- the aligned I/O is an integer multiple of the main mapping granularity, that is, the current I/O to be written is aligned with the main mapping granularity.
- the size of the unaligned I/O is smaller than the size of the main mapping granularity, that is, the current I/O to be written is not aligned with the main mapping granularity.
- the sub-mapping tables of N levels may be queried one by one to complete the write operation. If the target sub-mapping table whose sub-mapping granularity is not larger than the size of the unaligned I/O is queried for the first time, it is judged whether the size of the unaligned I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table; if so, it indicates that the target The sub-mapping granularity of the sub-mapping table matches the size of the current unaligned I/O, and there is no need to read adjacent data from the hard disk to complement the unaligned I/O, and there is no need to write data larger than the size of the current unaligned I/O.
- Data directly write the current non-aligned I/O to the target physical address, and record the mapping relationship between the target logical address of the non-aligned I/O and the target physical address in the target sub-mapping table. That is to say: for non-aligned I/O, among the many sub-mapping tables provided by this application, a sub-mapping table that can directly complete non-aligned I/O can be found, thereby reducing the read-write amplification of the hard disk and improving the use of the hard disk. life.
- the sub-mapping granularity of the first query is not larger than that of the non-aligned I/O
- the remaining I/Os except the target I/O are regarded as unaligned I
- the size of the unaligned I/O split from the I/O request is 3K
- the size of the mapping items in the three levels of mapping tables is "4K (main mapping table)-2K (sub-mapping table 1 )-1K (sub-mapping table 2)”
- the target sub-mapping table queried for the first time is sub-mapping table 1
- the sub-mapping granularity 2K of sub-mapping table 1 is not greater than the size of unaligned I/O 3K
- the size 3K of unaligned I/O is not an integer multiple of the sub-mapping granularity 2K of sub-mapping table 1, so the target I/O is determined from the unaligned I/O of 3K size (that is, the I/O of 2K size ), so that the current I/O to be written is aligned with the sub-mapping granularity 2K of sub-mapping table 1, then write the target I/O of 2K size to the
- mapping table 2 the next-level mapping table (ie, sub-mapping table 2) of the target sub-mapping table is continued to be queried.
- the mapping granularity 1K is not greater than the size 1K of unaligned I/O, and the size 1K of unaligned I/O is 1 times the sub-mapping granularity 1K of sub-mapping table 2, so 1K non-aligning Align I/O writing, and a mapping entry in sub-mapping table 2 (this mapping entry has a mapping relationship with a certain mapping entry in sub-mapping table 1, and this mapping entry in sub-mapping table 1 indicates that the current non-
- the logical address of the aligned I/O records the mapping relationship between the write location (that is, the physical address) of the 1K unaligned I/O and the logical address of the unaligned I/O, thereby completing the writing of the unaligned
- the non-aligned I/O has been queried one by one from the high level to the low level of the sub-mapping tables of N levels, but the writing of the non-aligned I/O has not been completed, all Determine the lowest-level sub-mapping table in the sub-mapping table; create the next-level sub-mapping table for the lowest-level sub-mapping table; the sub-mapping granularity of the created next-level sub-mapping table can be divisible by the size of unaligned I/O; write Import the unaligned I/O to the corresponding physical address, and record the mapping relationship between the logical address of the unaligned I/O and the corresponding physical address in the created next-level sub-mapping table.
- creating the next-level sub-mapping table for the lowest-level sub-mapping table includes: determining in the lowest-level sub-mapping table the updatable mapping item corresponding to the non-aligned I/O (that is, indicating the logical address of the current non-aligned I/O mapping item); create a target table, and determine the number of mapping items in the target table; initialize all mapping items in the target table, and update the physical address pointed to by the updateable mapping item to all mapping items in the target table; The target table is determined as the created next-level sub-mapping table.
- the size of the mapping item of any mapping table (the size of the mapping granularity) is specified when designing the hard disk, and the number of all mapping tables is also specified when designing the hard disk.
- the size of the unaligned I/O split from the I/O request is 3K
- the size of the mapping items in the two levels of mapping tables is "4K (main mapping table)-2K (sub-mapping table 1 )”
- the target sub-mapping table queried for the first time is sub-mapping table 1.
- the sub-mapping granularity 2K of sub-mapping table 1 is not greater than the size of unaligned I/O 3K, and unaligned I/O
- the size of 3K is not an integer multiple of the sub-mapping granularity 2K of sub-mapping table 1, so the target I/O (that is, the I/O of 2K size) is determined from the unaligned I/O of 3K size, so that the current to-be-written
- the I/O is aligned with the sub-mapping granularity 2K of sub-mapping table 1, and then the target I/O of 2K size is written to the corresponding physical address, and the logical address of the target I/O and the corresponding physical address are recorded in the target sub-mapping table mapping relationship between them.
- next-level mapping table that is, after querying all the mapping tables, but the non-aligned I/O has not been written, at this time, all sub-mapping
- the lowest-level sub-mapping table ie, sub-mapping table 1 is determined in the table; the next level of sub-mapping table (ie, sub-mapping table 2) is created for sub-mapping table 1, and the sub-mapping granularity of the resulting next-level sub-mapping table is created It can be divisible by the size of unaligned I/O, so the sub-mapping granularity of sub-mapping table 2 is 1K, then based on sub-mapping table 2, 1K-sized unaligned I/O can be directly written to the corresponding physical address, and the resulting The mapping relationship between the logical address of the unaligned I/O and the corresponding physical address is
- This method can be called: for unaligned I/O written in batches and then create a new table for writing, that is: for unaligned I/O of 3K size, first use sub-mapping table 1 to write 2K of it, leaving 1K unused After the writing is completed and there is no mapping table with a mapping granularity of 1K, then a mapping table with a mapping granularity of 1K is created to complete the writing of the remaining 1K I/O.
- N levels of sub-mapping tables can be queried one by one from high level to low level, so as to select a sub-mapping granularity from all sub-mapping tables that can be unaligned
- An object sub-mapping table that is divisible by the size of the I/O, so that the writing of unaligned I/O can be directly completed without writing in batches.
- the non-aligned I/O is split from the I/O request based on the main mapping granularity, and there are object sub-mapping tables whose sub-mapping granularity can be divisible by the size of the non-aligned I/O in the sub-mapping tables of N levels, Write the unaligned I/O to the corresponding physical address, and record the mapping relationship between the logical address of the unaligned I/O and the corresponding physical address in the object sub-mapping table.
- the size of the unaligned I/O split from the I/O request is 3K
- the size of the mapping items in the three levels of mapping tables is "4K (main mapping table)-2K (sub-mapping table 1 )-1K (sub-mapping table 2)”
- sub-mapping table 2 is directly select sub-mapping table 2 as the object sub-mapping table, so that the current I/O to be written is aligned with the sub-mapping granularity 1K of sub-mapping table 2, and then Write 3K I/O to the corresponding physical address, and record the mapping relationship between the logical address of the I/O and the corresponding physical address in the sub-mapping table 2 .
- This method can be called: select the alignment table for unaligned I/O and write directly, that is: for unaligned I/O of 3K size, directly use sub-mapping table 2 to write three 1K to complete unaligned I/O of 3K size /O write.
- the sub-mapping tables of N levels exist dynamically, that is, the sub-mapping tables can be created in real time as needed, or can be deleted based on garbage collection.
- the memory resources occupied by the sub-mapping table are released, and the sub-mapping table The corresponding mapping entries in the upper level mapping table of the table point to other physical addresses.
- mapping entries in a certain sub-mapping table point to physical addresses (the lowest-level mapping table is more common), then the data stored in these physical addresses can be integrated, and then the integrated data can be stored in a certain consecutive physical addresses, then the data in these physical addresses pointed to by all the mapping items in the sub-mapping table can be deleted, so the sub-mapping table is useless, so release the memory resources occupied by the sub-mapping table, that is, delete The submap.
- the integrated data still needs to use the mapping table to record the mapping relationship between the logical address and the physical address.
- mapping item of the logical address records the mapping relationship (that is, the mapping relationship between the logical address of the integrated data and the new storage location of the integrated data).
- the scheme provided by this application will be described in detail below with a two-level mapping table.
- the main mapping table can not only be directly mapped to the physical address, but also can point to the sub-mapping table, so that the misalignment problem can be solved through the mapping of the sub-mapping table at a smaller granularity, and it is no longer necessary to complete the read, so as to achieve the purpose of improving performance, especially It is a scenario where there are a small amount of unaligned writes in the system, which can greatly improve system performance without greatly increasing system overhead.
- the unaligned I/O is 512 bytes, and the writing of the 512 bytes can be directly completed based on the sub-mapping table. There is no need to read adjacent data from the hard disk to complement the unaligned I/O. There is no need to write data larger than the size of the current non-aligned I/O, which reduces the read and write amplification of the hard disk and improves the service life of the disk.
- the specific I/O writing process in the solid state disk can be as follows:
- FW Flash Memory, flash memory
- the FW splits the non-aligned I/O according to the main mapping granularity (4K), and splits it into an aligned I/O part and a non-aligned I/O part.
- the FW directly completes writing to the aligned I/O part according to the aligned writing method.
- the FW queries the main mapping table for the non-aligned I/O part; if the mapping item indicating the non-aligned I/O in the main mapping table has pointed to the sub-mapping table, it indicates that the mapping item has been written unaligned; if the main mapping If the mapping entry indicating unaligned I/O in the table does not point to the sub-mapping table, it indicates that the mapping entry has not been unaligned write.
- mapping subtable needs to be created for mapping entries indicating unaligned I/O.
- 4b-b apply for a sub-mapping table, and initialize each entry in the sub-mapping table according to the granularity of 512 bytes, so as to obtain a sub-mapping table including 8 entries of 512 bytes.
- 4b-c Point the mapping entry indicating unaligned I/O in the main mapping table to the newly created sub-mapping table. That is, the mapping of the logical address of the corresponding mapping item in the main mapping table is pointed to the sub-mapping table.
- Dynamic release of the sub-mapping table When performing garbage collection on the mapping space of the sub-mapping table, the data stored in the mapping space of the sub-mapping table is reclaimed based on the main mapping table, and the sub-mapping table is deleted. After garbage collection, use the main mapping table to record the new Nand address of the recycled data, and release the DDR space occupied by the sub-mapping table.
- this scheme dynamically builds a sub-mapping table with a smaller granularity for the mapping space of unaligned writes.
- the mapping space of the corresponding sub-table can be released without greatly increasing the system.
- the purpose of improving system performance is achieved.
- the problem of a large drop in system performance due to padding of non-aligned I/Os in the system is solved without greatly increasing the occupation of system resources. If it is not possible to create a subtable due to insufficient resources, changing the traditional non-aligned foreground read completion method to the background read completion method (garbage collection) through the subtable can also greatly improve the system's non-aligned write performance.
- the following is an introduction to an I/O request processing device provided in the embodiment of the present application.
- the I/O request processing device described below and the I/O request processing method described above may refer to each other.
- an I/O request processing device which is applied to solid-state hard drives, including:
- a receiving module 401 configured to receive an I/O request sent by the host
- the splitting module 402 is used to split the non-aligned I/O from the I/O request based on the main mapping granularity of the main mapping table, and query the preset sub-mapping tables of N levels one by one from the high level to the low level ;
- the main mapping table is the upper-level mapping table of the highest-level sub-mapping table, and any mapping item in the main mapping table and any sub-mapping table and the physical address or all mapping items in the next-level mapping table exist Mapping relationship;
- N is a positive integer not less than 1;
- the non-aligned I/O processing module 403 is used to determine whether the size of the non-aligned I/O is a child of the target sub-mapping table if the sub-mapping granularity is not greater than the size of the non-aligned I/O inquired for the first time.
- An integer multiple of the mapping granularity if so, write the non-aligned I/O to the target physical address, and record the mapping relationship between the target logical address and the target physical address of the non-aligned I/O in the target sub-mapping table.
- it also includes:
- Another unaligned I/O processing module used to determine the target I/O from the unaligned I/O if the target sub-mapping table is queried for the first time, but the size of the unaligned I/O is not an integer multiple of the sub-mapping granularity ;
- the size of the target I/O is an integer multiple of the sub-mapping granularity of the target sub-mapping table; write the target I/O to the corresponding physical address, and record the logical address and the corresponding physical address of the target I/O in the target sub-mapping table
- the mapping relationship between; the remaining I/O in the unaligned I/O except the target I/O is regarded as unaligned I/O, and continue to query the next-level mapping table of the target sub-mapping table until the unalignment is completed I/O writes.
- it also includes:
- Another non-aligned I/O processing module is used to determine the lowest-level sub-mapping table in all sub-mapping tables if the non-aligned I/O has not been written after querying all sub-mapping tables; it is the lowest-level sub-mapping table Create the next-level sub-mapping table; the sub-mapping granularity of the created next-level sub-mapping table can be divisible by the size of the unaligned I/O; write unaligned I/O to the corresponding physical address, and create the resulting next-level sub-mapping table The mapping relationship between the logical address of the unaligned I/O and the corresponding physical address is recorded in the first-level sub-mapping table.
- another unaligned I/O processing module is specifically used for:
- the target table is determined to be the created next level sub-mapping table.
- another unaligned I/O processing module is specifically used for:
- it also includes:
- Another non-aligned I/O processing module is used to split the non-aligned I/O from the I/O request based on the main mapping granularity, and there are sub-mapping granularities in the sub-mapping tables of N levels that can be unaligned I
- the non-aligned I/O is written to the corresponding physical address, and the mapping relationship between the logical address of the non-aligned I/O and the corresponding physical address is recorded in the object sub-mapping table.
- it also includes:
- the sub-map recycling module is used to garbage-collect the data in the physical addresses pointed to by all the mapping items in any sub-map to other physical addresses, release the memory resources occupied by the sub-map, and recycle the memory resources of the sub-map
- the corresponding mapping entries in the upper-level mapping table point to other physical addresses.
- it also includes:
- the aligned I/O processing module is used to write the aligned I/O to the corresponding physical address if the aligned I/O is split from the I/O request based on the main mapping granularity, and record the aligned I/O in the main mapping table The mapping relationship between the logical address of O and the corresponding physical address.
- this embodiment provides a device for processing I/O requests.
- the device can find a sub-mapping table that can directly complete non-aligned I/O in many sub-mapping tables, thereby reducing the number of hard disks.
- Read and write amplification can improve the performance of unaligned I/O and the service life of hard disks.
- An electronic device provided by an embodiment of the present application is introduced below, and the electronic device described below and the I/O request processing method and device described above may refer to each other.
- an electronic device including:
- Memory 501 for storing computer programs
- the processor 502 is configured to execute the computer program, so as to implement the method disclosed in any of the foregoing embodiments.
- a readable storage medium provided by an embodiment of the present application is introduced below.
- the readable storage medium described below and the I/O request processing method, device, and device described above may refer to each other.
- a readable storage medium is used to store a computer program, wherein the computer program implements the I/O request processing method disclosed in the foregoing embodiments when executed by a processor.
- the computer program implements the I/O request processing method disclosed in the foregoing embodiments when executed by a processor.
- the specific steps of the method reference may be made to the corresponding content disclosed in the foregoing embodiments, and details are not repeated here.
- RAM random access memory
- ROM read-only memory
- EEPROM electrically programmable ROM
- EEPROM electrically erasable programmable ROM
- registers hard disk, removable disk, CD-ROM, or any other Any other known readable storage medium.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Human Computer Interaction (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Signal Processing For Digital Recording And Reproducing (AREA)
Abstract
一种I/O请求处理方法、装置、设备及可读存储介质。本申请提供了1个主映射表和N个子映射表,在这些映射表中,能够找到一个可以直接完成非对齐I/O的子映射表,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前非对齐I/O的大小的数据,从而降低硬盘的读写放大,能够提升非对齐I/O的性能和硬盘的使用寿命。相应地,本申请提供的一种I/O请求处理装置、设备及可读存储介质,也同样具有上述技术效果。
Description
本申请要求于2021年09月26日提交至中国专利局、申请号为202111131242.0、发明名称为“一种I/O请求处理方法、装置、设备及可读存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及计算机技术领域,特别涉及一种I/O请求处理方法、装置、设备及可读存储介质。
目前,硬盘中的映射表以固定大小的映射粒度写入数据,例如:映射表的映射粒度为4K,那么要求以4K大小写入数据。当要写入小于4K的数据(如1K数据)时,就需要先从硬盘读取4K大小的数据,然后将此时要写入的1K数据合并到所读取的4K数据中,之后写入合并后的4K数据至硬盘,以完成1K数据的写入。可见,原本仅需写入1K数据,但上述过程不仅先从硬盘中读取了4K数据,又写入了4K数据到硬盘,因此存在读放大和写放大,降低了盘的使用寿命。
因此,如何降低硬盘的读放大和写放大,是本领域技术人员需要解决的问题。
发明内容
有鉴于此,本申请的目的在于提供一种I/O请求处理方法、装置、设备及可读存储介质,以降低硬盘的读放大和写放大。其具体方案如下:
第一方面,本申请提供了一种I/O请求处理方法,应用于固态硬盘,包括:
接收主机发送的I/O请求;
若基于主映射表的主映射粒度从所述I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表 为最高级别子映射表的上一级别映射表,所述主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项存在映射关系;N为不小于1的正整数;
若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断所述非对齐I/O的大小是否为所述目标子映射表的子映射粒度的整数倍;
若是,则写入所述非对齐I/O至目标物理地址,并在所述目标子映射表中记录所述非对齐I/O的目标逻辑地址与所述目标物理地址之间的映射关系。
优选地,还包括:
若首次查询到所述目标子映射表,但所述非对齐I/O的大小不是所述子映射粒度的整数倍,则从所述非对齐I/O中确定目标I/O;所述目标I/O的大小为所述目标子映射表的子映射粒度的整数倍;
写入所述目标I/O至相应物理地址,并在所述目标子映射表中记录所述目标I/O的逻辑地址与相应物理地址之间的映射关系;
将所述非对齐I/O中除所述目标I/O之外的剩余I/O作为所述非对齐I/O,并继续查询所述目标子映射表的下一级别映射表,直至完成所述非对齐I/O的写入。
优选地,还包括:
若查询完所有子映射表后所述非对齐I/O未完成写入,则在所有子映射表中确定最低级别子映射表;
为所述最低级别子映射表创建下一级别子映射表;创建所得的下一级别子映射表的子映射粒度能够被所述非对齐I/O的大小整除;
写入所述非对齐I/O至相应物理地址,并在创建所得的下一级别子映射表中记录所述非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
优选地,所述为所述最低级别子映射表创建下一级别子映射表,包括:
在所述最低级别子映射表中确定所述非对齐I/O对应的可更新映射项;
创建目标表,并确定所述目标表中的映射项的个数;
初始化所述目标表中的所有映射项,并将所述可更新映射项指向的物 理地址更新为所述目标表中的所有映射项;
将所述目标表确定为创建所得的下一级别子映射表。
优选地,所述确定所述目标表中的映射项的个数,包括:
确定所述目标表的子映射粒度,并将所述可更新映射项的大小与所述目标表的子映射粒度的比值,确定为所述目标表中的映射项的个数。
优选地,还包括:
若基于所述主映射粒度从所述I/O请求中拆分出所述非对齐I/O,且N个级别的子映射表中存在子映射粒度能够被所述非对齐I/O的大小整除的对象子映射表,则写入所述非对齐I/O至相应物理地址,并在所述对象子映射表中记录所述非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
优选地,还包括:
将任意子映射表中的所有映射项指向的物理地址中的数据垃圾回收至其他物理地址后,释放该子映射表占用的内存资源,并将该子映射表的上一级别映射表中的相应映射项指向所述其他物理地址。
优选地,还包括:
若基于所述主映射粒度从所述I/O请求中拆分出对齐I/O,则写入所述对齐I/O至相应物理地址,并在所述主映射表中记录所述对齐I/O的逻辑地址与相应物理地址之间的映射关系。
第二方面,本申请提供了一种I/O请求处理装置,应用于固态硬盘,包括:
接收模块,用于接收主机发送的I/O请求;
拆分模块,用于若基于主映射表的主映射粒度从所述I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表为最高级别子映射表的上一级别映射表,所述主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项均存在映射关系;N为不小于1的正整数;
非对齐I/O处理模块,用于若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断所述非对齐I/O的大小是否为所述目标子映射表的子映射粒度的整数倍;若是,则写入所述非对齐I/O至目标物理 地址,并在所述目标子映射表中记录所述非对齐I/O的目标逻辑地址与所述目标物理地址之间的映射关系。
第三方面,本申请提供了一种电子设备,包括:
存储器,用于存储计算机程序;
处理器,用于执行所述计算机程序,以实现前述公开的I/O请求处理方法。
第四方面,本申请提供了一种可读存储介质,用于保存计算机程序,其中,所述计算机程序被处理器执行时实现前述公开的I/O请求处理方法。
通过以上方案可知,本申请提供了一种I/O请求处理方法,应用于固态硬盘,包括:接收主机发送的I/O请求;若基于主映射表的主映射粒度从所述I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表为最高级别子映射表的上一级别映射表,所述主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项存在映射关系;N为不小于1的正整数;若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断所述非对齐I/O的大小是否为所述目标子映射表的子映射粒度的整数倍;若是,则写入所述非对齐I/O至目标物理地址,并在所述目标子映射表中记录所述非对齐I/O的目标逻辑地址与所述目标物理地址之间的映射关系。
可见,本申请提供的固态硬盘中设有一个主映射表和N个子映射表,这些映射表按照级别或映射粒度大小(即映射项的大小)由高至低排列为:主映射表--最高级别子映射表--……--最低级别子映射表,且相邻映射表(即:上下两级映射表)之间存在映射关系。针对I/O请求中的非对齐I/O,可以逐一查询N个级别的子映射表来完成其写入操作。若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断非对齐I/O的大小是否为目标子映射表的子映射粒度的整数倍;若是,则表明目标子映射表的子映射粒度与当前非对齐I/O的大小匹配,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前非对齐I/O的大小的数据,直接将当前非对齐I/O写入至目标物理地址,并在目标子映射表中记录非对齐I/O的目标逻辑地址与目标物理地址之间的映射关系。也即:针对非对齐I/O,在本申请提供的众多子映射表中,能够找到一个可以直接完成 非对齐I/O的子映射表,从而降低硬盘的读写放大,能够提高硬盘的使用寿命。
相应地,本申请提供的一种I/O请求处理装置、设备及可读存储介质,也同样具有上述技术效果。
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。
图1为本申请公开的一种I/O请求处理方法流程图;
图2为本申请公开的相邻的上下两级映射表的映射示意图;
图3为本申请公开的一种非对齐I/O写入示意图;
图4为本申请公开的一种I/O请求处理装置示意图;
图5为本申请公开的一种电子设备示意图。
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
目前,非对齐I/O的写入存在读放大和写放大,降低了盘的使用寿命。为此,本申请提供了一种I/O请求处理方案,能够降低硬盘的读写放大,提高硬盘的使用寿命。
参见图1所示,本申请实施例公开了一种I/O请求处理方法,应用于固态硬盘,包括:
S101、接收主机发送的I/O请求。
S102、若基于主映射表的主映射粒度从I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表。
需要说明的是,主机下发的I/O请求所要写入的I/O大小可能大于主映射表的主映射粒度,也可能小于主映射表的主映射粒度。当要写入的I/O大小为主映射表的主映射粒度的整数倍时,认为当前是对齐I/O,此时可直接完成I/O写入,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前I/O大小的数据,因此降低了写放大和读放大。当要写入的I/O大小小于主映射表的主映射粒度时,认为当前写入的I/O是非对齐I/O,此时可以使用N个级别的子映射表将当前I/O当作对齐I/O进行处理,因此也降低了写放大和读放大。
其中,主映射表为最高级别子映射表的上一级别映射表,主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项存在映射关系;N为不小于1的正整数,也即:N=1、2、3、4……N。
在本实施例提供的固态硬盘中,设有1个主映射表和N个子映射表,这些映射表按照级别或映射粒度大小(即映射项的大小)由高至低排列为:主映射表--最高级别子映射表--……--最低级别子映射表,且相邻映射表(即:上下两级映射表)之间存在映射关系。
针对任一个映射表,映射粒度大小与表中的映射项个数的乘积,即为该映射表映射的整体物理地址空间大小。一个映射表中的任一个映射项用于记录逻辑地址和物理地址之间的映射关系。一个映射表中的每个映射项都可以指向下一级别映射表,因此同一级别的子映射表的个数有多个,但主映射表只有一个。
相邻的上下两级映射表可参见图2。若图2中的上一级别映射表为主映射表,则该映射表就没有上一级别映射表。若图2中的上一级别映射表不是主映射表,则该映射表就有上一级别映射表。由图2可看出:上一级别映射表中的某一个映射项可指向下一级别映射表中的全部映射项,也就是:上一级别映射表中的这一个映射项所指向的物理地址在下一级别映射表中进行了更细粒度的划分。在图2中,物理地址p即表示某一非对齐I/O的写入位置。
假设固态硬盘中设有1个主映射表和2个子映射表,主映射表的主映射粒度为4K,表示主映射表中的一个映射项指向4K大小的物理地址空间。子映射表1(最高级别子映射表)的子映射粒度为2K,表示该子映射表中 的一个映射项指向2K大小的物理地址空间。子映射表1(最低级别子映射表)的子映射粒度为1K,表示该子映射表中的一个映射项指向1K大小的物理地址空间。那么这3个映射表的级别由高至低为:主映射表--子映射表1--子映射表2,这三个级别的映射表的映射项大小(即映射粒度大小)分别为:4K-2K-1K。
在这三个级别的映射表中,相邻映射表之间的映射关系为:主映射表中的某一个映射项指向下一级别的子映射表1的整体物理地址空间大小,具体为:主映射表中的一个4K大小的映射项在子映射表1中呈现为2个2K大小的映射项。相应的,子映射表1中的某一个映射项指向下一级别的子映射表2的整体物理地址空间大小,具体为:子映射表1中的一个2K大小的映射项在子映射表2中呈现为2个1K大小的映射项。
当然,若子映射表1中的每个映射项都指向子映射表2,那么可以没有子映射表1,那么主映射表与子映射表2的映射粒度大小分别为:4K-1K,那么二者之间的映射关系为:主映射表中的一个4K大小的映射项在子映射表2中呈现为4个1K大小的映射项。在子映射表1中的每个映射项都指向子映射表2,且有子映射表1的情况下,子映射表1仅用于确定主映射表中的映射项与子映射表2中的映射项之间的映射关系。
S103、若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则在非对齐I/O的大小为目标子映射表的子映射粒度的整数倍的情况下,写入非对齐I/O至目标物理地址,并在目标子映射表中记录非对齐I/O的目标逻辑地址与目标物理地址之间的映射关系。
在本实施例中,总能够找到一个可以直接完成非对齐I/O的子映射表,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前非对齐I/O的大小的数据,从而降低硬盘的读写放大,能够提升非对齐I/O的性能和硬盘的使用寿命。具体的,针对非对齐I/O,依次查询各个子映射表,若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则表明基于目标子映射表可以直接写入当前非对齐I/O中的全部或部分I/O,那么在非对齐I/O的大小为目标子映射表的子映射粒度的整数倍的情况下,表明基于目标子映射表可以直接写入当前非对齐I/O中的全部I/O,那么写入非对齐I/O至目标物理地址,并在目标子映射表中记录非对齐I/O 的目标逻辑地址与目标物理地址之间的映射关系,降低了写放大和读放大。
例如:从I/O请求中拆分出的非对齐I/O的大小为2K,那么在三个级别的映射表的映射项大小分别为“4K(主映射表)-2K(子映射表1)-1K(子映射表2)”的情况下,那么首次查询到的目标子映射表即为子映射表1,此时子映射表1的子映射粒度2K不大于非对齐I/O的大小2K,且非对齐I/O的大小2K是子映射表1的子映射粒度2K的1倍,因此可直接基于子映射表1完成非对齐I/O的写入,并在子映射表1中的一个映射项(该映射项与主映射表的某一个映射项存在映射关系,主映射表中的这一个映射项指示当前非对齐I/O的目标逻辑地址)中记录非对齐I/O的写入位置(即目标物理地址)与非对齐I/O的目标逻辑地址的映射关系。
其中,从I/O请求中拆分出非对齐I/O包括:按照主映射表的主映射粒度的大小从I/O请求中拆分出非对齐I/O。例如:I/O请求要写入7K的数据,主映射粒度为4K,那么I/O请求中的对齐I/O为4K,非对齐I/O为3K。假设I/O请求要写入35K的数据,主映射粒度为4K,那么I/O请求中的对齐I/O为32K,非对齐I/O为1K。I/O请求要写入3K的数据,主映射粒度为4K,那么I/O请求中的对齐I/O为0K,非对齐I/O为3K。可见,对齐I/O是主映射粒度的整数倍,也即:当前待写入I/O与主映射粒度对齐。非对齐I/O的大小小于主映射粒度的大小,也即:当前待写入I/O与主映射粒度不对齐。
可见,本实施例针对I/O请求中的非对齐I/O,可以逐一查询N个级别的子映射表来完成其写入操作。若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断非对齐I/O的大小是否为目标子映射表的子映射粒度的整数倍;若是,则表明目标子映射表的子映射粒度与当前非对齐I/O的大小匹配,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前非对齐I/O的大小的数据,直接将当前非对齐I/O写入至目标物理地址,并在目标子映射表中记录非对齐I/O的目标逻辑地址与目标物理地址之间的映射关系。也即:针对非对齐I/O,在本申请提供的众多子映射表中,能够找到一个可以直接完成非对齐I/O的子映射表,从而降低硬盘的读写放大,能够提高硬盘的使用寿命。
基于上述实施例,需要说明的是,若针对非对齐I/O,由高级别至低级别逐一查询N个级别的子映射表的过程中,首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,但非对齐I/O的大小不是子映射粒度的整数倍,则从非对齐I/O中确定目标I/O;目标I/O的大小为目标子映射表的子映射粒度的整数倍;写入目标I/O至相应物理地址,并在目标子映射表中记录目标I/O的逻辑地址与相应物理地址之间的映射关系;将非对齐I/O中除目标I/O之外的剩余I/O作为非对齐I/O,并继续查询目标子映射表的下一级别映射表,直至完成非对齐I/O的写入。
例如:从I/O请求中拆分出的非对齐I/O的大小为3K,那么在三个级别的映射表的映射项大小分别为“4K(主映射表)-2K(子映射表1)-1K(子映射表2)”的情况下,那么首次查询到的目标子映射表即为子映射表1,此时子映射表1的子映射粒度2K不大于非对齐I/O的大小3K,且非对齐I/O的大小3K不是子映射表1的子映射粒度2K的整数倍,因此从3K大小的非对齐I/O中确定出目标I/O(即2K大小的I/O),以使当前待写入I/O与子映射表1的子映射粒度2K对齐,然后写入2K大小的目标I/O至相应物理地址,并在目标子映射表中记录目标I/O的逻辑地址与相应物理地址之间的映射关系。
之后,还剩1K大小的剩余I/O,将其作为非对齐I/O,并继续查询目标子映射表的下一级别映射表(即子映射表2),此时子映射表2的子映射粒度1K不大于非对齐I/O的大小1K,且非对齐I/O的大小1K是子映射表2的子映射粒度1K的1倍,因此可直接基于子映射表2完成1K大小的非对齐I/O的写入,并在子映射表2中的一个映射项(该映射项与子映射表1的某一个映射项存在映射关系,子映射表1中的这一个映射项指示当前非对齐I/O的逻辑地址)中记录1K大小的非对齐I/O的写入位置(即物理地址)与该非对齐I/O的逻辑地址的映射关系,从而完成非对齐I/O的写入。此方式可称为:针对非对齐I/O分次写入,即:针对3K大小的非对齐I/O,先用子映射表1写其中的2K,再用子映射表2写剩下的1K。
基于上述实施例,需要说明的是,若针对非对齐I/O,由高级别至低级别逐一查询完N个级别的子映射表后,但非对齐I/O未完成写入,则在 所有子映射表中确定最低级别子映射表;为最低级别子映射表创建下一级别子映射表;创建所得的下一级别子映射表的子映射粒度能够被非对齐I/O的大小整除;写入非对齐I/O至相应物理地址,并在创建所得的下一级别子映射表中记录非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
其中,为最低级别子映射表创建下一级别子映射表,包括:在最低级别子映射表中确定非对齐I/O对应的可更新映射项(即指示当前非对齐I/O的逻辑地址的映射项);创建目标表,并确定目标表中的映射项的个数;初始化目标表中的所有映射项,并将可更新映射项指向的物理地址更新为目标表中的所有映射项;将目标表确定为创建所得的下一级别子映射表。其中,任一个映射表的映射项的大小(映射粒度的大小)在设计硬盘时指定,且所有映射表的个数也在设计硬盘时指定。
其中,确定目标表中的映射项的个数,包括:确定目标表的子映射粒度,并将可更新映射项的大小与目标表的子映射粒度的比值,确定为目标表中的映射项的个数。如:可更新映射项的大小为4K,目标表的子映射粒度为1K,那么目标表中的映射项的个数即为4K/1K=4个。
例如:从I/O请求中拆分出的非对齐I/O的大小为3K,那么在2个级别的映射表的映射项大小分别为“4K(主映射表)-2K(子映射表1)”的情况下,那么首次查询到的目标子映射表即为子映射表1,此时子映射表1的子映射粒度2K不大于非对齐I/O的大小3K,且非对齐I/O的大小3K不是子映射表1的子映射粒度2K的整数倍,因此从3K大小的非对齐I/O中确定出目标I/O(即2K大小的I/O),以使当前待写入I/O与子映射表1的子映射粒度2K对齐,然后写入2K大小的目标I/O至相应物理地址,并在目标子映射表中记录目标I/O的逻辑地址与相应物理地址之间的映射关系。
之后,还剩1K大小的剩余I/O,但目标子映射表没有下一级别映射表,也就是查询完所有映射表后,但非对齐I/O未完成写入,此时在所有子映射表中确定最低级别子映射表(即子映射表1);为子映射表1创建下一级别子映射表(即子映射表2),且创建所得的下一级别子映射表的子映射粒度能够被非对齐I/O的大小整除,因此子映射表2的子映射粒度为1K,那么可以基于子映射表2直接写入1K大小的非对齐I/O至相应物理地址,并 在创建所得的子映射表2中记录非对齐I/O的逻辑地址与相应物理地址之间的映射关系。此方式可称为:针对非对齐I/O分次写入后再新建表写入,即:针对3K大小的非对齐I/O,先用子映射表1写其中的2K,还剩1K未完成写入且没有映射粒度为1K的映射表,那么创建映射粒度为1K的映射表,以完成剩余的1K大小的I/O的写入。
基于上述实施例,需要说明的是,针对非对齐I/O,可以由高级别至低级别逐一查询N个级别的子映射表,以从所有子映射表挑选出一个子映射粒度能够被非对齐I/O的大小整除的对象子映射表,从而直接完成非对齐I/O的写入,无需分次写入。因此若基于主映射粒度从I/O请求中拆分出非对齐I/O,且N个级别的子映射表中存在子映射粒度能够被非对齐I/O的大小整除的对象子映射表,则写入非对齐I/O至相应物理地址,并在对象子映射表中记录非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
例如:从I/O请求中拆分出的非对齐I/O的大小为3K,那么在三个级别的映射表的映射项大小分别为“4K(主映射表)-2K(子映射表1)-1K(子映射表2)”的情况下,那么直接挑选出子映射表2作为对象子映射表,以使当前待写入I/O与子映射表2的子映射粒度1K对齐,然后写入3K大小的I/O至相应物理地址,并在子映射表2中记录I/O的逻辑地址与相应物理地址之间的映射关系。此方式可称为:针对非对齐I/O选择对齐表直接写入,即:针对3K大小的非对齐I/O,直接用子映射表2写3个1K,以完成3K大小的非对齐I/O的写入。
基于上述实施例,需要说明的是,N个级别的子映射表是动态存在的,也即:子映射表可以根据需要即时创建,也可以基于垃圾回收进行删除。在一种具体实施方式中,将任意子映射表中的所有映射项指向的物理地址中的数据垃圾回收至其他连续的物理地址后,释放该子映射表占用的内存资源,并将该子映射表的上一级别映射表中的相应映射项指向其他物理地址。
例如:某一个子映射表中的所有映射项都指向物理地址(最低级别的 映射表比较常见),那么就可以将这些物理地址里存储的数据进行整合,然后将整合后的数据存储至某一连续物理地址,那么该子映射表中的所有映射项指向的这些物理地址里的数据就可以删除,因此该子映射表就没有用了,所以释放该子映射表占用的内存资源,也即删除该子映射表。当然,整合后的数据还是需要用映射表记录逻辑地址和物理地址的映射关系的,此时用将该子映射表的上一级别映射表中的相应映射项(用于指示整合后的数据的逻辑地址的映射项)记录该映射关系(也即:整合后的数据的逻辑地址和整合后的数据的新存储位置之间的映射关系)。
基于上述实施例,需要说明的是,对于对齐I/O,直接用主映射表写入对齐I/O至相应物理地址,并在主映射表中记录对齐I/O的逻辑地址与相应物理地址之间的映射关系。
请参见图3,下面以两级映射表详细介绍本申请提供的方案,这两级映射表包括:1个主映射表和1个子映射表,假设主映射表的主映射粒度为4K,子映射表的子映射粒度为512字节,那么主映射表中的一个映射项可以指向子映射表中的4K/512字节=8个映射项或是指向具体的物理地址。也即:主映射表用于进行对齐I/O的写入,而子映射表用于进行非对齐I/O的写入。
主映射表不仅可直接映射到物理地址,而且可以指向子映射表,这样通过子映射表更小粒度的映射来解决不对齐问题,不再需要通过读补齐,从而达到提升性能的目的,特别是对系统中存在少量非对齐写的场景,在不大幅增加系统开销的情况下可大幅提升系统性能。如图3所示,非对齐I/O为512字节,可基于子映射表直接完成该512字节的写入,无需从硬盘读取相邻数据对非对齐I/O进行补齐,也无需写入大于当前非对齐I/O的大小的数据,降低硬盘的读写放大,提高了盘的使用寿命。
固态硬盘中具体的I/O写入流程可以为:
1、FW(Flash Memory,闪存)收到非对齐I/O写大小为m。
2、FW按主映射粒度(4K)对非对齐I/O进行拆分,拆分为对齐I/O部分和非对齐I/O部分。
3、FW对对齐I/O部分按对齐写方式直接完成写入。
4、FW对非对齐I/O部分,查询主映射表;若主映射表中指示非对齐I/O的映射项已指向子映射表,则表明该映射项进行过非对齐写;若主映射表中指示非对齐I/O的映射项未指向子映射表,则表明该映射项未进行过非对齐写。
4a:如果进行过非对齐写,则基于已有的子映射表直接进行写。
4b:如果未进行过非对齐写,则需要为指示非对齐I/O的映射项创建一个小粒度的映射子表。
4b-a:计算子映射表的大小。计算过程为:4K/512字节=8个entry(即映射项)。
4b-b:申请子映射表,并按照512字节的粒度大小初始化子映射表中的各个entry,以得到包括8个512字节的entry的子映射表。
4b-c:将主映射表中指示非对齐I/O的映射项指向新创建的子映射表。也即:将主映射表中相应映射项的逻辑地址的映射指向子映射表。
5、给非对齐I/O分配物理地址地址,以将非对齐I/O写入Nand。
6、在子映射表中的相应entry中记录新分配的物理地址地址。
子映射表的动态释放:对子映射表的映射空间进行垃圾回收时,基于主映射表回收子映射表的映射空间里存储的数据,并删除子映射表。垃圾回收后,用主映射表记录被回收数据的新Nand地址,释放子映射表占用的DDR空间。
可见,该方案对非对齐写的映射空间动态建立下一级更小粒度的子映射表,在进行GC或空间资源不足的情况下,可以释放对应的子表的映射空间,在不大幅增加系统内存资源的情况下达到提升系统性能的目的。本实施例通过采用二级多粒度的映射方法,在不大幅提升系统资源占用的情况下,解决系统中的非对齐I/O因补齐导致系统性能大幅跌落的问题。若在资源不足的情况下无法新建子表,则通过子表把传统非对齐的前台读补齐方式改为后台读补齐方式(即垃圾回收),也能大幅提升系统非对齐写性能。
下面对本申请实施例提供的一种I/O请求处理装置进行介绍,下文描 述的一种I/O请求处理装置与上文描述的一种I/O请求处理方法可以相互参照。
参见图4所示,本申请实施例公开了一种I/O请求处理装置,应用于固态硬盘,包括:
接收模块401,用于接收主机发送的I/O请求;
拆分模块402,用于若基于主映射表的主映射粒度从I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表为最高级别子映射表的上一级别映射表,主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项均存在映射关系;N为不小于1的正整数;
非对齐I/O处理模块403,用于若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断非对齐I/O的大小是否为目标子映射表的子映射粒度的整数倍;若是,则写入非对齐I/O至目标物理地址,并在目标子映射表中记录非对齐I/O的目标逻辑地址与目标物理地址之间的映射关系。
在一种具体实施方式中,还包括:
另一非对齐I/O处理模块,用于若首次查询到目标子映射表,但非对齐I/O的大小不是子映射粒度的整数倍,则从非对齐I/O中确定目标I/O;目标I/O的大小为目标子映射表的子映射粒度的整数倍;写入目标I/O至相应物理地址,并在目标子映射表中记录目标I/O的逻辑地址与相应物理地址之间的映射关系;将非对齐I/O中除目标I/O之外的剩余I/O作为非对齐I/O,并继续查询目标子映射表的下一级别映射表,直至完成非对齐I/O的写入。
在一种具体实施方式中,还包括:
又一非对齐I/O处理模块,用于若查询完所有子映射表后非对齐I/O未完成写入,则在所有子映射表中确定最低级别子映射表;为最低级别子映射表创建下一级别子映射表;创建所得的下一级别子映射表的子映射粒度能够被非对齐I/O的大小整除;写入非对齐I/O至相应物理地址,并在创建所得的下一级别子映射表中记录非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
在一种具体实施方式中,又一非对齐I/O处理模块具体用于:
在最低级别子映射表中确定非对齐I/O对应的可更新映射项;
创建目标表,并确定目标表中的映射项的个数;
初始化目标表中的所有映射项,并将可更新映射项指向的物理地址更新为目标表中的所有映射项;
将目标表确定为创建所得的下一级别子映射表。
在一种具体实施方式中,又一非对齐I/O处理模块具体用于:
确定目标表的子映射粒度,并将可更新映射项的大小与目标表的子映射粒度的比值,确定为目标表中的映射项的个数。
在一种具体实施方式中,还包括:
再一非对齐I/O处理模块,用于若基于主映射粒度从I/O请求中拆分出非对齐I/O,且N个级别的子映射表中存在子映射粒度能够被非对齐I/O的大小整除的对象子映射表,则写入非对齐I/O至相应物理地址,并在对象子映射表中记录非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
在一种具体实施方式中,还包括:
子映射表回收模块,用于将任意子映射表中的所有映射项指向的物理地址中的数据垃圾回收至其他物理地址后,释放该子映射表占用的内存资源,并将该子映射表的上一级别映射表中的相应映射项指向其他物理地址。
在一种具体实施方式中,还包括:
对齐I/O处理模块,用于若基于主映射粒度从I/O请求中拆分出对齐I/O,则写入对齐I/O至相应物理地址,并在主映射表中记录对齐I/O的逻辑地址与相应物理地址之间的映射关系。
其中,关于本实施例中各个模块、单元更加具体的工作过程可以参考前述实施例中公开的相应内容,在此不再进行赘述。
可见,本实施例提供了一种I/O请求处理装置,该装置针对非对齐I/O,可以在众多子映射表中找到一个可以直接完成非对齐I/O的子映射表,从而降低硬盘的读写放大,能够提升非对齐I/O的性能和硬盘的使用寿命。
下面对本申请实施例提供的一种电子设备进行介绍,下文描述的一种 电子设备与上文描述的一种I/O请求处理方法及装置可以相互参照。
参见图5所示,本申请实施例公开了一种电子设备,包括:
存储器501,用于保存计算机程序;
处理器502,用于执行所述计算机程序,以实现上述任意实施例公开的方法。
下面对本申请实施例提供的一种可读存储介质进行介绍,下文描述的一种可读存储介质与上文描述的一种I/O请求处理方法、装置及设备可以相互参照。
一种可读存储介质,用于保存计算机程序,其中,所述计算机程序被处理器执行时实现前述实施例公开的I/O请求处理方法。关于该方法的具体步骤可以参考前述实施例中公开的相应内容,在此不再进行赘述。
本申请涉及的“第一”、“第二”、“第三”、“第四”等(如果存在)是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的实施例能够以除了在这里图示或描述的内容以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法或设备固有的其它步骤或单元。
需要说明的是,在本申请中涉及“第一”、“第二”等的描述仅用于描述目的,而不能理解为指示或暗示其相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。另外,各个实施例之间的技术方案可以相互结合,但是必须是以本领域普通技术人员能够实现为基础,当技术方案的结合出现相互矛盾或无法实现时应当认为这种技术方案的结合不存在,也不在本申请要求的保护范围之内。
本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其它实施例的不同之处,各个实施例之间相同或相似部分互相参见 即可。
结合本文中所公开的实施例描述的方法或算法的步骤可以直接用硬件、处理器执行的软件模块,或者二者的结合来实施。软件模块可以置于随机存储器(RAM)、内存、只读存储器(ROM)、电可编程ROM、电可擦除可编程ROM、寄存器、硬盘、可移动磁盘、CD-ROM、或技术领域内所公知的任意其它形式的可读存储介质中。
本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。
Claims (10)
- 一种I/O请求处理方法,其特征在于,应用于固态硬盘,包括:接收主机发送的I/O请求;若基于主映射表的主映射粒度从所述I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表为最高级别子映射表的上一级别映射表,所述主映射表和任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项均存在映射关系;N为不小于1的正整数;若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断所述非对齐I/O的大小是否为所述目标子映射表的子映射粒度的整数倍;若是,则写入所述非对齐I/O至目标物理地址,并在所述目标子映射表中记录所述非对齐I/O的目标逻辑地址与所述目标物理地址之间的映射关系。
- 根据权利要求1所述的I/O请求处理方法,其特征在于,还包括:若首次查询到所述目标子映射表,但所述非对齐I/O的大小不是所述子映射粒度的整数倍,则从所述非对齐I/O中确定目标I/O;所述目标I/O的大小为所述目标子映射表的子映射粒度的整数倍;将所述目标I/O写入至相应物理地址,并在所述目标子映射表中记录所述目标I/O的逻辑地址与相应物理地址之间的映射关系;将所述非对齐I/O中除所述目标I/O之外的剩余I/O作为所述非对齐I/O,并继续查询所述目标子映射表的下一级别映射表,直至完成所述非对齐I/O的写入。
- 根据权利要求2所述的I/O请求处理方法,其特征在于,还包括:若查询完所有子映射表后所述非对齐I/O未完成写入,则在所有子映射表中确定最低级别子映射表;为所述最低级别子映射表创建下一级别子映射表;创建所得的下一级别子映射表的子映射粒度能够被所述非对齐I/O的大小整除;写入所述非对齐I/O至相应的物理地址,并在创建所得的下一级别子映射表中记录所述非对齐I/O的逻辑地址与相应物理地址之间的映射关 系。
- 根据权利要求3所述的I/O请求处理方法,其特征在于,所述为所述最低级别子映射表创建下一级别子映射表,包括:在所述最低级别子映射表中确定所述非对齐I/O对应的可更新映射项;创建目标表,并确定所述目标表中的映射项的个数;初始化所述目标表中的所有映射项,并将所述可更新映射项指向的物理地址更新为所述目标表中的所有映射项;将所述目标表确定为创建所得的下一级别子映射表。
- 根据权利要求4所述的I/O请求处理方法,其特征在于,所述确定所述目标表中的映射项的个数,包括:确定所述目标表的子映射粒度,并将所述可更新映射项的大小与所述目标表的子映射粒度的比值,确定为所述目标表中的映射项的个数。
- 根据权利要求1-5任意一项所述的I/O请求处理方法,其特征在于,还包括:若基于所述主映射粒度从所述I/O请求中拆分出所述非对齐I/O,且N个级别的子映射表中存在子映射粒度能够被所述非对齐I/O的大小整除的对象子映射表,则写入所述非对齐I/O至相应物理地址,并在所述对象子映射表中记录所述非对齐I/O的逻辑地址与相应物理地址之间的映射关系。
- 根据权利要求1-5任意一项所述的I/O请求处理方法,其特征在于,还包括:将任意子映射表中的所有映射项指向的物理地址中的数据垃圾回收至其他物理地址后,释放该子映射表占用的内存资源,并将该子映射表的上一级别映射表中的相应映射项指向所述其他物理地址。
- 一种I/O请求处理装置,其特征在于,应用于固态硬盘,包括:接收模块,用于接收主机发送的I/O请求;拆分模块,用于若基于主映射表的主映射粒度从所述I/O请求中拆分出非对齐I/O,则由高级别至低级别逐一查询预设的N个级别的子映射表;其中,主映射表为最高级别子映射表的上一级别映射表,所述主映射表和 任一子映射表中的任一映射项与物理地址或下一级别映射表中的所有映射项均存在映射关系;N为不小于1的正整数;非对齐I/O处理模块,用于若首次查询到子映射粒度不大于非对齐I/O的大小的目标子映射表,则判断所述非对齐I/O的大小是否为所述目标子映射表的子映射粒度的整数倍;若是,则写入所述非对齐I/O至目标物理地址,并在所述目标子映射表中记录所述非对齐I/O的目标逻辑地址与所述目标物理地址之间的映射关系。
- 一种电子设备,其特征在于,包括:存储器,用于存储计算机程序;处理器,用于执行所述计算机程序,以实现如权利要求1至7任一项所述的I/O请求处理方法。
- 一种可读存储介质,其特征在于,用于保存计算机程序,其中,所述计算机程序被处理器执行时实现如权利要求1至7任一项所述的I/O请求处理方法。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111131242.0 | 2021-09-26 | ||
CN202111131242.0A CN113835639B (zh) | 2021-09-26 | 2021-09-26 | 一种i/o请求处理方法、装置、设备及可读存储介质 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2023045407A1 true WO2023045407A1 (zh) | 2023-03-30 |
Family
ID=78970209
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2022/097619 WO2023045407A1 (zh) | 2021-09-26 | 2022-06-08 | 一种i/o请求处理方法、装置、设备及可读存储介质 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN113835639B (zh) |
WO (1) | WO2023045407A1 (zh) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113835639B (zh) * | 2021-09-26 | 2024-03-19 | 深圳大普微电子科技有限公司 | 一种i/o请求处理方法、装置、设备及可读存储介质 |
CN115146716B (zh) * | 2022-06-22 | 2024-06-14 | 腾讯科技(深圳)有限公司 | 标注方法、装置、设备、存储介质及程序产品 |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103440206A (zh) * | 2013-07-25 | 2013-12-11 | 记忆科技(深圳)有限公司 | 一种固态硬盘及其混合映射方法 |
CN106293521A (zh) * | 2016-08-02 | 2017-01-04 | 华中科技大学 | 一种映射粒度自适应的闪存转换层管理方法 |
US20190042464A1 (en) * | 2017-06-30 | 2019-02-07 | Western Digital Technologies, Inc | Address range mapping for storage devices |
CN113031876A (zh) * | 2021-03-31 | 2021-06-25 | 深信服科技股份有限公司 | 一种数据处理方法、装置、设备及可读存储介质 |
CN113835639A (zh) * | 2021-09-26 | 2021-12-24 | 深圳大普微电子科技有限公司 | 一种i/o请求处理方法、装置、设备及可读存储介质 |
Family Cites Families (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101400506B1 (ko) * | 2012-07-13 | 2014-05-27 | 주식회사 이에프텍 | 비휘발성 메모리 제어기 및 그 제어 방법 |
CN103927265B (zh) * | 2013-01-04 | 2017-09-01 | 深圳市龙视传媒有限公司 | 一种内容分级存储装置、内容获取方法及内容获取装置 |
CN104035729B (zh) * | 2014-05-22 | 2017-02-15 | 中国科学院计算技术研究所 | 一种日志映射的块设备精简配置方法 |
CN104461925B (zh) * | 2014-11-14 | 2017-10-13 | 浪潮(北京)电子信息产业有限公司 | 一种存储设备地址对齐的自动纠正方法和装置 |
CN111638852A (zh) * | 2014-12-31 | 2020-09-08 | 华为技术有限公司 | 将数据写入固态硬盘的方法及固态硬盘 |
US9858289B2 (en) * | 2015-11-05 | 2018-01-02 | International Business Machines Corporation | Storage controller and method for managing a solid-state memory |
CN107589908B (zh) * | 2017-08-17 | 2020-01-17 | 暨南大学 | 一种基于固态盘缓存系统中非对齐更新数据的合并方法 |
CN109683817A (zh) * | 2018-12-14 | 2019-04-26 | 浪潮电子信息产业股份有限公司 | 一种数据写入方法、系统及电子设备和存储介质 |
CN109684238A (zh) * | 2018-12-19 | 2019-04-26 | 湖南国科微电子股份有限公司 | 一种固态硬盘映射关系的存储方法、读取方法及固态硬盘 |
CN111190867A (zh) * | 2019-12-27 | 2020-05-22 | 柏科数据技术(深圳)股份有限公司 | 一种用于文件存储的存储分层系统 |
CN112506438B (zh) * | 2020-12-14 | 2024-03-26 | 深圳大普微电子科技有限公司 | 一种映射表管理方法及固态硬盘 |
CN113608701B (zh) * | 2021-08-18 | 2024-09-20 | 合肥大唐存储科技有限公司 | 一种存储系统中数据管理方法和固态硬盘 |
-
2021
- 2021-09-26 CN CN202111131242.0A patent/CN113835639B/zh active Active
-
2022
- 2022-06-08 WO PCT/CN2022/097619 patent/WO2023045407A1/zh active Application Filing
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103440206A (zh) * | 2013-07-25 | 2013-12-11 | 记忆科技(深圳)有限公司 | 一种固态硬盘及其混合映射方法 |
CN106293521A (zh) * | 2016-08-02 | 2017-01-04 | 华中科技大学 | 一种映射粒度自适应的闪存转换层管理方法 |
US20190042464A1 (en) * | 2017-06-30 | 2019-02-07 | Western Digital Technologies, Inc | Address range mapping for storage devices |
CN113031876A (zh) * | 2021-03-31 | 2021-06-25 | 深信服科技股份有限公司 | 一种数据处理方法、装置、设备及可读存储介质 |
CN113835639A (zh) * | 2021-09-26 | 2021-12-24 | 深圳大普微电子科技有限公司 | 一种i/o请求处理方法、装置、设备及可读存储介质 |
Also Published As
Publication number | Publication date |
---|---|
CN113835639A (zh) | 2021-12-24 |
CN113835639B (zh) | 2024-03-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6764362B2 (ja) | メモリの重複除去方法及び重複除去dramメモリモジュール | |
US9298384B2 (en) | Method and device for storing data in a flash memory using address mapping for supporting various block sizes | |
US10402092B2 (en) | Resizing namespaces for storage devices | |
WO2023045407A1 (zh) | 一种i/o请求处理方法、装置、设备及可读存储介质 | |
US10452562B2 (en) | File access method and related device | |
KR101944876B1 (ko) | 파일 액세스 방법 및 장치 및 스토리지 디바이스 | |
US20170177497A1 (en) | Compressed caching of a logical-to-physical address table for nand-type flash memory | |
US10565103B2 (en) | Method for creating multi-namespace and method for accessing data therein | |
US20100030997A1 (en) | Virtual memory management | |
JP2019020788A (ja) | メモリシステムおよび制御方法 | |
US8326893B2 (en) | Allocating data sets to a container data set | |
US10296250B2 (en) | Method and apparatus for improving performance of sequential logging in a storage device | |
CN108595349B (zh) | 大容量存储设备的地址转换方法与装置 | |
US20150324281A1 (en) | System and method of implementing an object storage device on a computer main memory system | |
US9430492B1 (en) | Efficient scavenging of data and metadata file system blocks | |
US20230078081A1 (en) | B-plus tree access method and apparatus, and computer-readable storage medium | |
KR20160060550A (ko) | 효율적인 맵핑을 위한 페이지 캐시 장치 및 방법 | |
US20240086332A1 (en) | Data processing method and system, device, and medium | |
CN111512290A (zh) | 文件页表管理技术 | |
CN106776361B (zh) | 一种面向大规模非易失性存储介质的缓存方法和系统 | |
US11669445B2 (en) | Method for establishing hierarchical look-up tables and/or inquiring memory address according to hierarchical look-up tables | |
Na et al. | Iplb+-tree for flash memory database systems. | |
CN111338569A (zh) | 一种基于直接映射的对象存储后端优化方法 | |
JP2005108239A (ja) | 階層的データ構造体にデータを記憶する記憶システム | |
US11586353B2 (en) | Optimized access to high-speed storage device |
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: 22871468 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: 22871468 Country of ref document: EP Kind code of ref document: A1 |