CN110109625A - 一种改善Free Queue的管理方法 - Google Patents

一种改善Free Queue的管理方法 Download PDF

Info

Publication number
CN110109625A
CN110109625A CN201910405928.0A CN201910405928A CN110109625A CN 110109625 A CN110109625 A CN 110109625A CN 201910405928 A CN201910405928 A CN 201910405928A CN 110109625 A CN110109625 A CN 110109625A
Authority
CN
China
Prior art keywords
block
value
free
recovered
free queue
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN201910405928.0A
Other languages
English (en)
Inventor
倪黄忠
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Intention Electronics Co Ltd During Shenzhen
Original Assignee
Intention Electronics Co Ltd During Shenzhen
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 Intention Electronics Co Ltd During Shenzhen filed Critical Intention Electronics Co Ltd During Shenzhen
Priority to CN201910405928.0A priority Critical patent/CN110109625A/zh
Publication of CN110109625A publication Critical patent/CN110109625A/zh
Pending legal-status Critical Current

Links

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/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0238Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory
    • G06F12/0246Memory management in non-volatile memory, e.g. resistive RAM or ferroelectric memory in block erasable memory, e.g. flash memory
    • 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/0223User address space allocation, e.g. contiguous or non contiguous base addressing
    • G06F12/023Free address space management
    • G06F12/0253Garbage collection, i.e. reclamation of unreferenced memory
    • 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
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • G06F3/0607Improving or facilitating administration, e.g. storage management by facilitating the process of upgrading existing storage systems, e.g. for improving compatibility between host and storage device
    • 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
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0614Improving the reliability of storage systems
    • G06F3/0616Improving the reliability of storage systems in relation to life time, e.g. increasing Mean Time Between Failures [MTBF]
    • 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
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/064Management of blocks
    • 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
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket
    • 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
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/0671In-line storage system
    • G06F3/0673Single storage device
    • G06F3/0679Non-volatile semiconductor memory device, e.g. flash memory, one time programmable memory [OTP]

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 (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)

Abstract

本发明公开了一种改善Free Queue的管理方法,包含步骤1、数据写入;2、寻取自由块来存取数据;3、检查是否有可直接回收的块,若有则执行6,若无则执行4;4、启动垃圾回收机制回收块;5、检查将被回收的块PE值与t值差距,优先挑选PE值相对t值小的块回收到自由块队列表,其它的块后回收到自由块队列表;6、块回收到自由块队列表;7、回收到自由块队列表的块按照PE值来做分类;8、判断回收到自由块队列表的块PE值是否小于t值,若是则选用为自由块;若否则作为下次垃圾回收时的交换块。本发明优先选用PE值小的块来做自由块,减少了抹除次数高的块持续被使用,延迟了平均抹写触发机制,增加了闪存的寿命与效能。

Description

一种改善Free Queue的管理方法
技术领域
本发明涉及搭载FLASH memory的储存装置储存技术领域,具体的说涉及一种改善Free Queue的管理方法。
背景技术
在搭载FLASH memory的数码储存方案中,FTL算法为产品效能和寿命的关键因素,FTL算法包含众多具有复杂度和探讨性的模块,Free Queue Table则是被用来管理及存放每一次需要新的自由块来做为新的写入块的环节。
目前传统的Free Queue Table控制方式都是使用循序渐进的拿取方式,在一个有限制的记忆范围内使用两个Point来对应Table Head & Table Tail,Table Head Point指向的位置为下一个可使用的Free Block位置,Table Tail Point指向的位置为下一个经由回收可归还的位置,当大量的数据写入时,算法会不断地从Table Head Point得到FreeBlock来存取数据,当Free Queue Table内的Free Block不足于做使用时,算法则会开始检查目前的Data Block是否有可直接回收的Dirty Block,若有则会直接回收进Free QueueTable,反之,若检查不到有可直接回收的Dirty Block,则算法启动垃圾回收机制后回收Dirty Block进Free Queue Table,在回收的这些Data Block的每一个Block抹除次数会有大有小,当下一个被拿取出来当Free Block的PE值接近t值(Wear Leveling Threshold) ,算法则会启动平均抹除,此时将会找一个PE值小于t值的Data Block来做交换,此时也因为启动了平均抹除而降低了闪存效能。
发明内容
针对现有技术中的不足,本发明要解决的技术问题在于提供了一种改善FreeQueue的管理方法。
为解决上述技术问题,本发明通过以下方案来实现:一种改善Free Queue的管理方法,包括以下步骤:
S1:数据写入;
S2:寻取Free Block来存取数据;
S3:检查目前的Block是否有可直接回收的Dirty Block,若有,则执行步骤S6,若无,则执行步骤S4;
S4:启动垃圾回收机制来回收Dirty Block;
S5:检查将被回收的这些Block 的PE值与t值(Wear Leveling Threshold)差距,优先挑选PE值相对t值小的Block回收到Free Queue Table,其它的Block后回收到Free QueueTable;
S6:Block回收到Free Queue Table;
S7:回收到Free Queue Table的Block按照PE值来做分类区隔;
S8:判断回收到Free Queue Table的Block的PE值是否小于t值,若是,则选用为FreeBlock;若不是,作为下次垃圾回收时的交换Block。
进一步的,所述Free Queue Table是被用来管理及存放每一次需要写入新数据Free Block的Table。
进一步的,所述步骤S5通过垃圾回收机制的算法来完成。
进一步的,所述步骤S8中的PE值小于t值的Block按PE值从小到大的顺序选用为Free Block来储存数据。
进一步的,所述步骤S8中PE值不小于t值的Block先暂时存放在Free Queue Table里,当下次垃圾回收机制启动时,优先拿出来当被回收的source block。
相对于现有技术,本发明的有益效果是:在每一次的垃圾回收机制里,先检查将被回收的这些Block PE值与t值差距,优先挑选PE值相对t值小的Block来做回收,并且在回收到Free Queue Table时按照PE值来做分类区隔,PE值较小的Block被选用为Free Block,PE值较大的Block则会被当成下次垃圾回收时的交换Block,藉由此两种模式来平均每个块抹除次数(平均每个Block的PE增长),减少了抹除次数高的块持续被使用,由于优先选用PE值小的Block来做Free Block使得算法达不到启动平均抹写的条件而延迟了平均抹写触发机制,进而增加闪存的使用寿命与效能。
附图说明
图1为本发明改善Free Queue 管理方法的流程示意图。
具体实施方式
下面结合附图对本发明的优选实施例进行详细阐述,以使发明的优点和特征能更易于被本领域技术人员理解,从而对本发明的保护范围做出更为清楚明确的界定。
参照附图1,本发明的一种改善Free Queue的管理方法,包括以下步骤:
S1:数据写入;
S2:寻取Free Block来存取数据;
S3:检查目前的Block是否有可直接回收的Dirty Block,若有,则执行步骤S6,若无,则执行步骤S4;
S4:启动垃圾回收机制来回收Dirty Block;
S5:通过垃圾回收机制算法来检查将被回收的这些Block 的PE值与t值(WearLeveling Threshold)差距,优先挑选PE值相对t值小的Block回收到Free Queue Table,其它的Block后回收到Free Queue Table;
S6:Block回收到Free Queue Table;
S7:回收到Free Queue Table的Block按照PE值来做分类区隔;
S8:判断回收到Free Queue Table的Block的PE值是否小于t值,若是,则按PE值从小到大的顺序选用为Free Block来储存数据;若不是,则先暂时存放在Free Queue Table里,当下次垃圾回收机制启动时,优先拿出来当被回收的source block。
Free Block是用来写入新数据的自由数据块,由其它的区块经抹除数据后得到;Free Queue Table用来管理及存放每一次需要写入新数据Free Block的管理Table,它通过一套完整管理机制来存放Free Block队列,使得Free Block有优先使用的顺序。
本发明的Free Queue 管理机制,PE值小于t值的Block被回收选为Free Block,之前的数据会被抹除,它的PE值也就随之增长;而PE值不小于t值的的Block,则会当成下次垃圾回收时的交换Block,重新参与与t值的比较,直到比t值小才回收到Free Queue Table中,这种管理机制通过这两种模式来平均每个块抹除次数(平均每个Block的PE增长),减少了抹除次数高的块持续被使用。由于优先选用PE值小的Block来当做Free Block,使得算法达不到启动平均抹写的条件而延迟了平均抹写触发机制,进而增加闪存的使用寿命与效能。
以上所述仅为本发明的优选实施方式,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其它相关的技术领域,均同理包括在本发明的专利保护范围内。

Claims (5)

1.一种改善Free Queue的管理方法,其特征在于,包括以下步骤:
S1:数据写入;
S2:寻取Free Block来存取数据;
S3:检查目前的Block是否有可直接回收的Dirty Block,若有,则执行步骤S6,若无,则执行步骤S4;
S4:启动垃圾回收机制来回收Dirty Block;
S5:检查将被回收的这些Block 的PE值与t值(Wear Leveling Threshold)差距,优先挑选PE值相对t值小的Block回收到Free Queue Table,其它的Block后回收到Free QueueTable;
S6:Block回收到Free Queue Table;
S7:回收到Free Queue Table的Block按照PE值来做分类区隔;
S8:判断回收到Free Queue Table的Block的PE值是否小于t值,若是,则选用为FreeBlock;若不是,作为下次垃圾回收时的交换Block。
2.根据权利要求1所述的改善Free Queue的管理方法,其特征在于:所述Free QueueTable是被用来管理及存放每一次需要写入新数据Free Block的Table。
3.根据权利要求1所述的改善Free Queue的管理方法,其特征在于:所述步骤S5通过垃圾回收机制的算法来完成。
4.根据权利要求1所述的改善Free Queue的管理方法,其特征在于:所述步骤S8中的PE值小于t值的Block按PE值从小到大的顺序选用为Free Block来储存数据。
5.根据权利要求1所述的改善Free Queue的管理方法,其特征在于:所述步骤S8中PE值不小于t值的Block先暂时存放在Free Queue Table里,当下次垃圾回收机制启动时,优先拿出来当被回收的source block。
CN201910405928.0A 2019-05-16 2019-05-16 一种改善Free Queue的管理方法 Pending CN110109625A (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910405928.0A CN110109625A (zh) 2019-05-16 2019-05-16 一种改善Free Queue的管理方法

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910405928.0A CN110109625A (zh) 2019-05-16 2019-05-16 一种改善Free Queue的管理方法

Publications (1)

Publication Number Publication Date
CN110109625A true CN110109625A (zh) 2019-08-09

Family

ID=67490422

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910405928.0A Pending CN110109625A (zh) 2019-05-16 2019-05-16 一种改善Free Queue的管理方法

Country Status (1)

Country Link
CN (1) CN110109625A (zh)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101777026A (zh) * 2009-01-09 2010-07-14 成都市华为赛门铁克科技有限公司 一种存储管理方法、硬盘及存储系统
CN102637145A (zh) * 2011-02-11 2012-08-15 慧荣科技股份有限公司 用来进行区块管理的方法、记忆装置及其控制器
CN102789423A (zh) * 2012-07-11 2012-11-21 山东华芯半导体有限公司 四池闪存磨损均衡方法
CN106484323A (zh) * 2016-09-13 2017-03-08 郑州云海信息技术有限公司 一种固态存储的损耗均衡方法及系统
US20170262175A1 (en) * 2016-03-08 2017-09-14 Kabushiki Kaisha Toshiba Storage system, information processing system and method for controlling nonvolatile memory
CN107193493A (zh) * 2017-05-19 2017-09-22 惠州佰维存储科技有限公司 Nand闪存块的管理方法及其系统
CN107329902A (zh) * 2013-07-25 2017-11-07 慧荣科技股份有限公司 数据储存装置以及快闪存储器控制方法
CN107562381A (zh) * 2017-08-30 2018-01-09 紫光华山信息技术有限公司 一种数据处理方法及装置
CN109254927A (zh) * 2018-08-30 2019-01-22 浪潮电子信息产业股份有限公司 一种固态硬盘磨损均衡的实现方法

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101777026A (zh) * 2009-01-09 2010-07-14 成都市华为赛门铁克科技有限公司 一种存储管理方法、硬盘及存储系统
CN102637145A (zh) * 2011-02-11 2012-08-15 慧荣科技股份有限公司 用来进行区块管理的方法、记忆装置及其控制器
CN102789423A (zh) * 2012-07-11 2012-11-21 山东华芯半导体有限公司 四池闪存磨损均衡方法
CN107329902A (zh) * 2013-07-25 2017-11-07 慧荣科技股份有限公司 数据储存装置以及快闪存储器控制方法
US20170262175A1 (en) * 2016-03-08 2017-09-14 Kabushiki Kaisha Toshiba Storage system, information processing system and method for controlling nonvolatile memory
CN106484323A (zh) * 2016-09-13 2017-03-08 郑州云海信息技术有限公司 一种固态存储的损耗均衡方法及系统
CN107193493A (zh) * 2017-05-19 2017-09-22 惠州佰维存储科技有限公司 Nand闪存块的管理方法及其系统
CN107562381A (zh) * 2017-08-30 2018-01-09 紫光华山信息技术有限公司 一种数据处理方法及装置
CN109254927A (zh) * 2018-08-30 2019-01-22 浪潮电子信息产业股份有限公司 一种固态硬盘磨损均衡的实现方法

Similar Documents

Publication Publication Date Title
CN103425600B (zh) 一种固态盘闪存转换层中的地址映射方法
CN102508788B (zh) Ssd及ssd垃圾回收方法和装置
CN102982180B (zh) 数据存储方法及设备
CN102163175B (zh) 一种基于局部性分析的混合地址映射方法
CN102768645B (zh) 混合缓存的固态硬盘预取方法和固态硬盘ssd
CN103870514B (zh) 重复数据删除方法和装置
CN106484323A (zh) 一种固态存储的损耗均衡方法及系统
CN102819494B (zh) 一种闪存顺序写入时的优化方法
CN103473150A (zh) 一种用于数据去重系统中的碎片重写方法
CN104268159B (zh) 一种基于动态镜像的实时数据仓库数据预存取方法
CN101447940A (zh) 访问控制列表规则的更新方法和装置
CN106227598A (zh) 一种缓存资源的回收方法
CN104933051B (zh) 文件存储空间回收方法和装置
CN107229414A (zh) 存储空间回收方法及装置
CN106066818A (zh) 一种提高重复数据删除备份系统恢复性能的数据布局方法
CN107632789A (zh) 基于分布式存储的重删方法、系统及数据重复检测方法
CN105204783A (zh) 一种基于数据生存期的固态盘垃圾回收方法
US10372605B2 (en) Generational garbage collector for trees under multi-version concurrency control
CN105653466B (zh) 数据储存装置以及快闪存储器控制方法
CN105988939A (zh) 数据储存装置以及快闪存储器控制方法
CN102591788B (zh) 一种Java卡垃圾回收方法
CN105677233B (zh) 即时数据的储存方法及储存装置
CN110109625A (zh) 一种改善Free Queue的管理方法
CN114297092A (zh) 数据处理方法、系统、设备、存储系统及介质
CN106951193B (zh) 改善Nand Flash存储性能的方法及其系统

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Address after: 518000 the first floor to the third floor of No.7 Xinfa East Road, Xinqiao street, Bao'an District, Shenzhen City, Guangdong Province. The business premises are set up in No.2 workshop, zone a, xinfengze Industrial Zone, Shangnan East Road

Applicant after: SHENZHEN SHICHUANGYI ELECTRONIC Co.,Ltd.

Address before: Baoan District Shenzhen City manhole street 518000 Guangdong Province on the South East New fortress Industrial Park A District 2

Applicant before: SHENZHEN SHICHUANGYI ELECTRONIC Co.,Ltd.

CB02 Change of applicant information
RJ01 Rejection of invention patent application after publication

Application publication date: 20190809

RJ01 Rejection of invention patent application after publication