This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/38132] std::string is faster with -D_GLIBCXX_DEBUG=1 than without



------- Comment #1 from edwintorok at gmail dot com  2008-11-15 13:56 -------
Created an attachment (id=16682)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16682&action=view)
example to illustrate

compile with g++ -O3, I get:
real    0m0.130s
user    0m0.100s
sys     0m0.028s

compile with g++ -D_GLIBCXX_DEBUG=1 -O3 I get:
real    0m0.080s
user    0m0.056s
sys     0m0.028s

If I explicitly instantiate the template, I get similar effect as of defining
_GLIBCXX_DEBUG:
template class basic_string<char>;


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38132


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]