This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/45574] cin.getline() is extremely slow
- From: "paolo dot carlini at oracle dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Sep 2010 09:59:33 -0000
- Subject: [Bug libstdc++/45574] cin.getline() is extremely slow
- References: <bug-45574-19663@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #11 from paolo dot carlini at oracle dot com 2010-09-08 09:59 -------
(In reply to comment #8)
> But a 9-10x difference doesn't sound reasonable to me. The synced mode is not
> unbuffered, before or after my suggested change, it uses the internal buffer in
> glibc.
So? We are not changing glibc here. The C++ library does *not* use buffering in
the synced mode, and it does otherwise, for fstreams in particular. Where do
you think the performance difference is essentially coming from?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45574