on efficient wear leveling for large-scale flash-memory
TRANSCRIPT
![Page 1: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/1.jpg)
On Efficient Wear Leveling for Large-Scale Flash-Memory Storage Systems
Li-Pin ChangDepartment of Computer Science, National Chiao-Tung University, Hsin-Chu, Taiwan
2008-02-15 Speaker: Kwon, Ohhoon
ACM Symposium on Applied Computing 2007
![Page 2: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/2.jpg)
Introduction Attractive features of flash memory
Small size Fast access speed Shock resistance Light weight
Characteristics Write is not allowed before erasing The number of erase operations is limited (100,000) Asymmetry in read and write speeds
Erase(100X) > Write(5X) > Read(1X) Asymmetry in read/write and erase size
Read/write : page Erase : block
![Page 3: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/3.jpg)
Flash Memory
erase update
write
To update the data in flash memory, 1. All data in the block is copied to
a system buffer 2. The data is updated in system
buffer3. The block on flash memory has
been erased, 4. all data must be written back
from system buffer to the block. Therefore, updating even one
byte data requires one slow erase and several write operations.
In-Place-Update
block
block
block
block
Update this data
read
![Page 4: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/4.jpg)
Flash Memory
update write
Out-Place-Update
block
block
block
block
read
Update this data
To address the problem of in-place-update, out-place-update is exploited
1. The page only is copied to a system buffer
2. The data is updated in system buffer
3. The page is written at the other place on flash memory
4. The orignal page is marked as invalid
Garbage collection is performed to translate invalid page to free page
buffer
![Page 5: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/5.jpg)
Hot and Cold Data
As hot data and cold data differently wear flash memory, its overall lifespan could be unexpectedly short under such workload.
Wear leveling refers to system activities in order to lengthen the overall lifespan
block block block block block block block block block
![Page 6: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/6.jpg)
A dual-pool algorithm dual-pool for wear leveling
HpHp Hp Hp Hp...
Hot pool
CpCp Cp Cp...
Cold pool
( Dual-pool )( None)
![Page 7: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/7.jpg)
Dirty Swap (DS) On the completion of a write request, the following condition
is checked:
Step 1. Data on alll live pages in block H+(QHP) are copied to some other free pages
Step 2. Erase block H+(QHP)
Step 3. Copy data on all live pages from block H-(QCP) to block H+(QHP)
Step 4. Erase block H-(QCP)
Step 5. Swap block H+(QHP) and block H-(QCP) in terms of their pool associations.
A dual-pool algorithm
![Page 8: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/8.jpg)
A dual-pool algorithm Dirty Swap (DS)
HpHp Hp Hp Hp...
Hot pool
CpCp Cp Cp...
Cold pool
H+(QHP)
H-(QCP)
8 3 - > 4
Dirty Swap (DS) should be now performed
![Page 9: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/9.jpg)
A dual-pool algorithm Dirty Swap (DS)
Hp Hp Hp Hp...
Hot pool
CpCp Cp Cp...
Cold pool
H+(QHP)
H-(QCP)
H+(QHP)
HpFree block
H-(QCP)
H+(QCP)
H-(QHP)
![Page 10: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/10.jpg)
Adaptive pool resizing Hot-Pool Resize(HPR): On the completion of a write request,
block H-(QHP) is moved from the hot pool to the cold pool if the following condition is checked:
Cold-Pool Resize(CPR): On the completion of a write request, block H+(QCP) is moved from the cold pool to the hot pool if the following condition is checked:
A dual-pool algorithm
* Effective Erase Cycle(EEC): how many time a block is erased since the last time the block is involoved in DS
![Page 11: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/11.jpg)
Random Priority Queues : Bit-Pyramid RPQ A pyramid RPQ is of a bit pyramid and a linear array Indexes of the linear array stand for keys of items, and each
slot of the array contains the priority of an item.
A dual-pool algorithm
![Page 12: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/12.jpg)
Performance Evaluation
(65,536 items)
![Page 13: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/13.jpg)
Conclusion This paper aims at both the two issues
Poor wear-leveling, Low scalability
A novel algorithm is proposed based on two new ideas To cease the wearing of a frequently erased block by storing
cold data in it To leave alone blocks just involved in wear leveling.
Based on a newly proposed data structure, a highly scalable implementation of the proposed algorithm is presented.
![Page 14: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/14.jpg)
Conclusion This paper aims at both the two issues
Poor wear-leveling, Low scalability
A novel algorithm is proposed based on two new ideas To cease the wearing of a frequently erased block by storing
cold data in it To leave alone blocks just involved in wear leveling.
Based on a newly proposed data structure, a highly scalable implementation of the proposed algorithm is presented.
![Page 15: On Efficient Wear Leveling for Large-Scale Flash-Memory](https://reader038.vdocument.in/reader038/viewer/2022103116/558b2448d8b42a9f478b46d7/html5/thumbnails/15.jpg)
Garbage collection procedure1. Select a victim block to clean2. Copy valid pages in the victim block to free block3. Erase the victim block
block block block block block block
① Select a victim block
② copy out valid pages
③ erase the victim block