https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81395
--- Comment #13 from Paolo Carlini <paolo.carlini at oracle dot com> --- Hi, > It looks strange, because usually _M_set_buffer(-1) is used for uncommitted > mode, but what it's actually doing is nuking the buffers. The next read > would need to do an underflow to refill the get area (which is correct), or > the next write would need to do a seek and then an overflow to make a put > area available (which is correct). Indeed, you are making explicit some vague thoughts of mine, which, by and large pointed in the direction that uncommited mode may well be fine, modulo possible performance implications, like, again very vague thoughts, we end up re-reading something which we already read. Those cases I was hoping you could investigate a bit ;)