It is completely weird, isn't it? You'd expect writing new data to the SSD would mark those sectors as the freshest possible and therefore not something to be discarded, but these utilities actually both fill all the available space and then delete the giant file it made afterwards.
Perhaps if the drive knows an entire block has been deleted, then its contents can all be placed into a pool to be bulk erased by garbage collection later when the drive is idle, no TRIM required--although a TRIM command to explicitly instruct the drive to discard the data for sure may hasten this process. The OS filesystem has no clue on how the drive is arranged internally but if a file is altered, it gets written to a new page and the old version marked as stale. It's more complicated if a file is deleted as the OS merely marks the file system clusters occupied by the deleted file as overwritable, only updating the Master File Table and metadata while leaving the file contents itself on the media--but of course the OS can then send a TRIM command to make sure the drive knows they are marked to be deleted, or else schedule a periodic entire-drive TRIM to prune expired data.
The problem of course is that an SSD can write pages but cannot erase only pages--only entire blocks of hundreds of pages.
When a page needs to be written, it will be first written to a free block and if there are none, an entire block of stale pages is (slowly!) combined and erased to make room and any good pages that were in those are combined with the new page and written into the one block. Garbage collection's job is to find the oldest stale pages as the SSD can know when the pages were last written to, but if all available pages now contain stale data that is the same age, then perhaps the drive is smart enough to just treat all the stale data as equivalently deletable/available.
Garbage collection works behind the scenes to compact all of the good pages into blocks and stale pages into their own blocks, so if needed the blocks made entirely of stale pages can be quickly erased if needed without having to slowly move a bunch of stuff around later. Without TRIM it can't be entirely sure if the pages are actually valid or stale so it's reasonable to treat the stale pages modified the longest time ago as least valuable. TRIM makes things way more efficient because then Garbage Collection can erase stale pages right away instead of moving them around in the background just-in-case.
Technically, the discarded data may actually remain on the SSD as the Garbage Collection needn't zero it out if the entire block is marked for erasure since that can be done quickly. However the TRIM command unlinks pages in the block from the LBA to PBA map/table so the SSD no longer knows where things that were in there are, and any query about unmapped sectors immediately returns all zeroes without even attempting to read the drive, much like the TRIMmed SMR disk. Unlike the HDD though, even the factory probably couldn't reassemble files from the tiny pieces scattered all over the flash.
If you think about it, modern firmware may even be smart enough to see you are writing all zeroes and refrain from actually storing them, only marking a LBA range as filled with zeroes, essentially compressing the data since all zeroes compresses rather a lot. As you say, the conundrum is TRIM unmaps all LBA to PBA while zero-filling "should" map it all, opposite of TRIM. So the true answer is we don't know, but some drive engineer who worked there probably does. That it works though, is probably more useful than how it should or shouldn't work.
Of course now we've entirely derailed the thread and poor OP is wondering what this has to do with their HDD. I wonder why they haven't been by recently.