2
Before an SSD sector1 was ever written to, it looks like all filled with zeros.
So, if I write all zeros to a sector, for the purpose of functionality, it will look just like a free one. Thus the controller has a technical possibility to treat it as such. My limited knowledge of IC architecture says that hardware-wise, slowdown from a circuit testing for all zeros would probably be negligible, if any at all.
The question is: does any flash/SSD controller actually implement this or anything similar?
It looks even more applicable to flash memory storage connected via interfaces that don't have the TRIM command, like USB.
In the answers posted so far, a few people outlined possible show-stopper issues. Yet they all turned out to be non-issues. Unless there's evidence those really are serious problems, please do not authoritatively claim they are but rather honestly say you're only hypothesizing that.
1A logical sector i.e. what the host sees.
SSDs will wear out quickly if you write to every single sector. Each cell has a limited number of times that it can be written to, and after that the cell is too slow to be useful. If you have security reasons to "secure erase" the drive, then know that most SSDs are overprovisioned, so that there are physical cells left to spare. Thus, someone who can use a vendor utility to access every single cell might have access to data you thought was "securely erased". – Christopher Hostage – 2017-08-17T23:05:49.390
Sounds like you are asking whether some controller would do garbage collection by checking whether a logical block contains (to be less ambiguous, reads) all zero? (Like, auto-TRIM it if that's the case?) – Tom Yan – 2017-08-18T00:23:03.317
@TomYan It's even easier. It only needs to be checked on an incoming write command. If the data operand is all zeros, no writing is done and the logical block is unmapped instead. – ivan_pozdeev – 2017-08-18T00:28:00.813
1I've heard of controllers that would be smart enough to ignore zero filling after it exceeds certain contiguous length. I would assume (part of) the logical blocks would be in a state that is equivalence as TRIM'd. – Tom Yan – 2017-08-18T00:28:13.270
@TomYan I read that top gun SSDs (like Samsung PRO/EVO) compress data on the fly to achieve even faster read/write speeds - naturally, a chunk of zeros compresses really well. – ivan_pozdeev – 2017-08-18T01:16:46.237
"So, unless there's evidence those really are serious problems, answers authoritatively claiming they are (rather than only hypothesizing that) are not acceptable." - They are acceptable from a community perspective. They might just not answer your question. I caution you from using verbiage like "not acceptable", as a question author, you want as many people willing to write an answer as possible, negative verbiage can chase people who might know the answer to your question away. – Ramhound – 2017-08-21T15:50:09.773
I’m VTC as too broad because there are too many flash controller types. You need to seriously narrow down the scope of this question. Either way, Super User is not a research service. – Daniel B – 2017-08-21T15:55:43.860
@DanielB there are not so many distinctive techniques that SSDs use and they are typically mentioned in tech papers/reviews/etc. i.e. don't require firmware-level knowledge of specific models. Controllers only vary in details of their implementation which are of no concern here. – ivan_pozdeev – 2017-08-21T16:02:17.090