clang++ fstreams 10X slower than g++
问题 Q: Is there a way to speed up clang++ STD Library fstreams? (And does anybody know why it is so much slower than g++?) I am trying to process very large (many GBs) binary data files and was surprised to find the performance was so poor. At first, I thought it was something to do with my code. But I am seeing the same slow performance in a boiled down example. I even tried allocating different size buffers via rdbuf()->pubsetbuf() but this didn't seem to have much effect. Here is a simple