This is the mail archive of the
mailing list for the libstdc++ project.
Re: stringstream slowness
- From: Paolo Carlini <pcarlini at suse dot de>
- To: Radu Grigore <radugrigore at gmail dot com>
- Cc: libstdc++ at sources dot redhat dot com
- Date: Tue, 22 Jun 2004 11:22:27 +0200
- Subject: Re: stringstream slowness
- References: <firstname.lastname@example.org>
Radu Grigore wrote:
A program like the following works about 3 times faster when compiled
with VS7.1, compared to gcc3.3.1. The optimizations are turned on (-O2
for gcc and "release" mode for VS).
Any chance you can test gcc3.4.0 or the forthcoming gcc3.4.1? In the
3.4 series we have many performance improvements in this area.
Indeed, on my P4-2400, this version of your snippet:
for (unsigned i = 0; i < 500000; ++i)
v[i] = "100 200 300 400 500";
Gives these numbers for me:
5.640u 0.030s 0:05.68 99.8% 0+0k 0+0io 213pf+0w
1.500u 0.060s 0:01.58 98.7% 0+0k 0+0io 200pf+0w
Thanks for your message,