logoalt Hacker News

charcircuittoday at 3:49 AM4 repliesview on HN

Sequential reads are faster for SSDs. As long as defragmentation is reducing the chance of doing a random read, it is beneficial.


Replies

shuwixtoday at 7:44 AM

Don't want to wake you up from your Pakistani coma, but data is accessed differently on metal disc spinning 120 revolutions per second, and a NAND flash.

Defragmentation logic for HDD's doesn't work on SSD. For like 10+ years, all SSD's have T.R.I.M. technology to rearrange data themself for faster access, and for more consistent storing of new data.

socalgal2today at 5:39 AM

OH! TIL! Apparently

                                contiguous              fragmented
    -------------------------------------------------------------------
    PCIe 4.0 NVMe Read Speed    ~5,000 – 7,000 MB/s     ~80 – 250 MB/s
    SATA 3.0 SSD Read Speed     ~500 – 550 MB/s         ~30 – 60 MB/s

Still, given SSDs have a lifespan and given few of my files are that large, I think I'm personally okay without defragmenting. Those numbers are impressive but, most of 10s of thousands of files are source code text files. Asking online what the real-world loss is from not defragmenting

> You are giving up virtually 0% to 3% of real-world performance. In daily development, media editing, and standard system use, defragmenting your SSD will yield no human-noticeable speedup.

__dtoday at 4:33 AM

Is it possible to determine which sectors are physically sequential given remapping for wear-leveling?

Otherwise the claimed defragmentation here is not actually resulting in sequential data.

show 2 replies
Groxxtoday at 4:50 AM

Prefetching applies to SSDs too, and that's generally sequential in some sense.