Write amplification


Write amplification is an undesirable phenomenon associated with flash memory and solid-state drives where the actual amount of information physically written to the storage media is a multiple of the logical amount intended to be written.
Because flash memory must be erased before it can be rewritten, with much coarser granularity of the erase operation when compared to the write operation, the process to perform these operations results in moving user data and metadata more than once. Thus, rewriting some data requires an already-used-portion of flash to be read, updated, and written to a new location, together with initially erasing the new location if it was previously used. Due to the way flash works, much larger portions of flash must be erased and rewritten than actually required by the amount of new data. This multiplying effect increases the number of writes required over the life of the SSD, which shortens the time it can operate reliably. The increased writes also consume bandwidth to the flash memory, which reduces write performance to the SSD. Many factors will affect the WA of an SSD; some can be controlled by the user and some are a direct result of the data written to and usage of the SSD.
Intel and SiliconSystems used the term write amplification in their papers and publications in 2008. WA is typically measured by the ratio of writes committed to the flash memory to the writes coming from the host system. Without compression, WA cannot drop below one. Using compression, SandForce has claimed to achieve a write amplification of 0.5, with best-case values as low as 0.14 in the SF-2281 controller.

Basic SSD operation

Due to the nature of flash memory's operation, data cannot be directly overwritten as it can in a hard disk drive. When data is first written to an SSD, the cells all start in an erased state so data can be written directly using pages at a time. The SSD controller on the SSD, which manages the flash memory and interfaces with the host system, uses a logical-to-physical mapping system known as logical block addressing that is part of the flash translation layer. When new data comes in replacing older data already written, the SSD controller will write the new data in a new location and update the logical mapping to point to the new physical location. The data in the former location is no longer valid, and will need to be erased before that location can be written to again.
Flash memory can be programmed and erased only a limited number of times. This is often referred to as the maximum number of program/erase cycles it can sustain over the life of the flash memory. Single-level cell flash, designed for higher performance and longer endurance, can typically operate between 50,000 and 100,000 cycles., multi-level cell flash is designed for lower cost applications and has a greatly reduced cycle count of typically between 3,000 and 5,000. Since 2013, triple-level cell flash has been available, with cycle counts dropping to 1,000 program-erase cycles. A lower write amplification is more desirable, as it corresponds to a reduced number of P/E cycles on the flash memory and thereby to an increased SSD life. The wear of flash memory may also cause performance degrade, such as I/O speed degrade.

Calculating the value

Write amplification was always present in SSDs before the term was defined, but it was in 2008 that both Intel and SiliconSystems started using the term in their papers and publications. All SSDs have a write amplification value and it is based on both what is currently being written and what was previously written to the SSD. In order to accurately measure the value for a specific SSD, the selected test should be run for enough time to ensure the drive has reached a steady state condition.
A simple formula to calculate the write amplification of an SSD is:
The two quantities used for calculation can be obtained via SMART statistics.

Factors affecting the value

Many factors affect the write amplification of an SSD. The table below lists the primary factors and how they affect the write amplification. For factors that are variable, the table notes if it has a direct relationship or an inverse relationship. For example, as the amount of over-provisioning increases, the write amplification decreases. If the factor is a toggle function then it has either a positive or negative relationship.
FactorDescriptionTypeRelationship*
Garbage collectionThe efficiency of the algorithm used to pick the next best block to erase and rewriteVariableInverse
Over-provisioningThe percentage of over-provisioning capacity which is allocated to the SSD controllerVariableInverse
Device's built-in DRAM bufferThe built-in DRAM buffer of the storage device may used to decrease the write amplificationVariableInverse
TRIM command for SATA or UNMAP for SCSIThese commands must be sent by the operating system which tells the storage device which pages contain invalid data. SSDs receiving these commands can then reclaim the blocks containing these pages as free space when they are erased instead of copying the invalid data to clean pages.TogglePositive
Zoned StorageZoned Storage is a storage technology set that can reduces write amplification and product cost. It divides the storage device to many zones, and allows operating systems to write data sequently on zones. It needs both operating system and device to support this feature. Also it can improve read performance as it can reduce read disturb.TogglePositive
Free user spaceThe percentage of the user capacity free of actual user data; requires TRIM, otherwise the SSD gains no benefit from any free user capacityVariableInverse
Secure eraseErases all user data and related metadata which resets the SSD to the initial out-of-box performance TogglePositive
Wear levelingThe efficiency of the algorithm that ensures every block is written an equal number of times to all other blocks as evenly as possibleVariableDepends
Separating static and dynamic dataGrouping data based on how often it tends to changeTogglePositive
Sequential writesIn theory, sequential writes have less write amplification, but other factors will still affect the real situationTogglePositive
Random writesWriting non-sequential data and smaller data sizes will have greater impact on write amplificationToggleNegative
Data compression which includes data deduplicationWrite amplification goes down and SSD speed goes up when data compression and deduplication eliminates more redundant data.VariableInverse
Using Multi-level cell NAND in SLC modeThis writes data at a rate of one bit per cell instead of the designed number of bits per cell to speed up reads and writes. If capacity limits of the NAND in SLC mode are approached, the SSD must rewrite the oldest data written in SLC mode into MLC / TLC mode to allow space in the SLC mode NAND to be erased in order to accept more data. However, this approach can reduce wear by keeping frequently-changed pages in SLC mode to avoid programming these changes in MLC / TLC mode, because writing in MLC / TLC mode does more damage to the flash than writing in SLC mode. Therefore, this approach drives up write amplification but could reduce wear when writing patterns target frequently-written pages. However, sequential- and random-write patterns will aggravate the damage because there are no or few frequently-written pages that could be contained in the SLC area, forcing old data to need to be constantly be rewritten to MLC / TLC from the SLC area. This method is sometimes called "SLC cache" or "SLC buffer". It has two types of "SLC buffer"; one type is static SLC buffer, another type is dynamic SLC buffer. However the SLC buffer usually does not accelerate read speed.ToggleDepends

TypeRelationship modifiedDescription
VariableDirectAs the factor increases the WA increases
VariableInverseAs the factor increases the WA decreases
VariableDependsDepends on different manufacturers and models
TogglePositiveWhen the factor is present the WA decreases
ToggleNegativeWhen the factor is present the WA increases
ToggleDependsDepends on different manufacturers and models

Garbage collection

Data is written to the flash memory in units called pages. However, the memory can only be erased in larger units called blocks. If the data in some of the pages of the block are no longer needed, only the pages with good data in that block are read and rewritten into another previously erased empty block. Then the free pages left by not moving the stale data are available for new data. This is a process called garbage collection. All SSDs include some level of garbage collection, but they may differ in when and how fast they perform the process. Garbage collection is a big part of write amplification on the SSD.
Reads do not require an erase of the flash memory, so they are not generally associated with write amplification. In the limited chance of a read disturb error, the data in that block is read and rewritten, but this would not have any material impact on the write amplification of the drive.