# Amphishea: A Novel Persistent Buffer Management Strategy to Improve SMR Disk Performance
## 1 Introduction
Second, a single data layout scheme cannot efficiently manage blocks with different update frequencies, reducing the efficiency of buffer cleanup. Finally, in a zone-level write-back mechanism, the size and spatial locality of the evicted victims are important factors affecting the buffer cleanup cost, and these factors have not been considered in these studies, leading to unpredictable write-back durations. To improve the efficiency of CMR-based persistent buffer cleanup, we propose a novel management strategy called Amphisbaena, which is optimized in three phases: (1) exploiting the knowledge provided by write requests in the workload to capture frequently updated blocks; (2) managing blocks with different update frequencies in a way that dynamically partitions the persistent buffer; (3) using a low-overhead GC policy to minimize the impact of buffer cleanup on user request latency. Specifically, the main contributions of this paper are as follows. * A two-phase data block classification method is proposed to capture blocks with frequent updates, thus reducing the frequency of write-back of hot blocks. In the first phase, the data classifier predicts the update frequency of blocks based on the explicit characteristics of the current write request. In the second phase, the data classifier further mines the implicit characteristics of blocks and assigns specific roles to them to reserve frequently updated blocks in the buffer for as long as possible. * A locality-aware buffer space management scheme is developed to improve the efficiency of buffer cleanup. To isolate blocks with different update frequencies, the persistent buffer is partitioned into a high-frequency buffer (HFB) and a low-frequency buffer (LFB). The HFB uses the fine-grained unit to hold frequently updated blocks for better space utilization, while the LFB uses the coarse-grained unit to improve write efficiency for cold (infrequently updated) blocks. In addition, each buffer can be periodically reallocated to match the access pattern of the workload. * A latency-sensitive garbage collection policy is designed to minimize the overhead of the zone-level write-back mechanism. First, the time-consuming victim collection process is broken down into sub-stages and collection is stopped as soon as a new write request is detected at a checkpoint, reducing the blocking time of user requests. Then, a metric called fragmentation level is used to guide victim selection to minimize unnecessary RMW operations during data migration. We evaluated Amphisheana with real-world workloads from Microsoft Research (MSR) Cambridge [17], and verified its I/O performance improvement on a real HM-SMR disk. The experimental results show that Amphisheana can reduce the average latency by 29.9% and the number of RMWs by 37% on average compared to the latest strategies. The rest of the paper is organized as follows. Section 2 describes the background and motivation. Section 3 presents the related work. The overall architecture of Amphisheana is provided in Section 4. Section 5 introduces the detailed design of the Amphisheana. Section 6 shows the experimental setup and the analysis of the results. We conclude this paper and discuss future work in Section 7.