An SSD can read the filesystem allocation bitmap, but that's a "rampant layering violation".
Most people confuse trim with garbage collection, which proactively cleans out invalid data (creating more pre-erased blocks to speed future writes) and potentially defragments data (to speed future sequential reads).
Most people confuse trim with garbage collection, which proactively cleans out invalid data (creating more pre-erased blocks to speed future writes) and potentially defragments data (to speed future sequential reads).