Except for some backups, all of my machines use solid state storage so I don't think there is a point for most people, is there?

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

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.

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.

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.

You cannot directly inspect the degree of fragmentation, because it has less to do with being contiguous in the Logical Block Address (LBA) space and more to do with having been written at the same time. To properly defragment a file on a SSD, you pretty much need to sequentially re-write the whole file in one go, to a newly-allocated part of the drive's LBA space.

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

I haven't measured it but the SSD firmware should be able to look up where the next block is speculatively in order to be able to immediately start sending it if the host tries and read the next block (as opposed to a random one).

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