Re:1BRC Merykitty's Magic SWAR: 8 Lines of Code Explained in...
by davidmurdoch on Saturday March 09, 2024 @08:29PM
(#39656033)
I was surprised by this recently when optimizing a build process that uses an intermediate write-to-disk step. I replaced the intermediate filesystem API with an in-memory one and it was not measurably faster. Not even by a single millisecond.
[ Parent
| on HN ]
Re:1BRC Merykitty's Magic SWAR: 8 Lines of Code Explained in...
by 10000truths on Saturday March 09, 2024 @10:30PM
(#39656512)
How much data were you writing? If you don't fill the OS's page cache and the SSD controller's DRAM cache, and you're not blocking on fsync() or O_DIRECT or some other explicit flushing mechanism, then you're not going to see much of a difference in throughput.
Re:1BRC Merykitty's Magic SWAR: 8 Lines of Code Explained in...
by davidmurdoch on Sunday March 10, 2024 @12:16PM
(#39660314)
Only a few MB written then read, so that is a likely explanation.