Patent ID: 9645924
Date: 2017-05-09
CPC Classifications: G06F

Claim:
1. A method for scaling garbage collection, the method comprising: determining, by a first computer processor, an over-provisioning ratio of a storage device, wherein the storage device includes a plurality of blocks; monitoring a write pattern of the storage device, wherein monitoring the host write pattern comprises determining a randomness of a plurality of write commands, each write command identifying a logical block address; determining a write amplification target based on the write pattern and the over-provisioning ratio, wherein a low write amplification target is associated with a high over-provisioning ratio value and a high write amplification target is associated with a low over-provisioning ratio value; determining a staleness threshold based on the write amplification target, wherein the staleness threshold corresponds to a quantity of valid pages of the block and wherein the staleness threshold indicates a ratio of invalid pages to total pages of the block, wherein the total pages of the block comprises a set of valid pages and a set of invalid pages; and proactively performing garbage collection on one or more blocks, with a write amplification cost low enough such that a total write amplification does not exceed the write amplification target, wherein proactively performing garbage collection on the one or more blocks comprises erasing content in each of the one or more blocks having a staleness exceeding the staleness threshold, and wherein proactively performing garbage collection on the one or more blocks is based on a delay on at least one of a rate of change in staleness for the block and an amount of time since determining that that the staleness of the block exceeded the staleness threshold.