From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16820 invoked by alias); 15 Nov 2008 13:58:13 -0000 Received: (qmail 5485 invoked by uid 48); 15 Nov 2008 13:56:51 -0000 Date: Sat, 15 Nov 2008 13:58:00 -0000 Message-ID: <20081115135651.5481.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug c++/38132] std::string is faster with -D_GLIBCXX_DEBUG=1 than without In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "edwintorok at gmail dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2008-11/txt/msg01195.txt.bz2 ------- 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; -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38132