From patchwork Mon Mar 19 21:42:41 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Benjamin Kosnik X-Patchwork-Id: 147647 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 06C2BB6FA3 for ; Tue, 20 Mar 2012 08:43:13 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1332798194; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Received: Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: Mime-Version:Content-Type:Mailing-List:Precedence:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=3K2AOUoYEV3yQtf4EBmN2KtX/XY=; b=tfQ8ei4eM6/V9gd ++jX3MSdUWEDXkJ3gNP5gqzJ/Zj1AFKSN/o4138HnTh57n8g6UKEvZcyFvgsQ00Y oNDJP8WNOeTj0JE7RSI0bJc5b5WibXt33aqw4eAb+R7+JA9LpY7mHip5qboTus/9 Iopdr+Lb7Y9SUTb1swNAG2OQhJZM= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Received:Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References:Mime-Version:Content-Type:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=x2kSbc/vTslvttt0X4ijSYKveiFyuwQlQsjVbMb1WTruIsKY3zdCh3PeE4NW3n rMZmtbErYk22KL8QQomDL7xp7DFrk7CzqaHaW98bq7zKIB/Mc4WUGg8hd21VBH20 WWQUIWTlMh/Bz3jTWlSzE9LagAKQ5u74YQ1inWhK2sCBY=; Received: (qmail 13747 invoked by alias); 19 Mar 2012 21:43:07 -0000 Received: (qmail 13734 invoked by uid 22791); 19 Mar 2012 21:43:06 -0000 X-SWARE-Spam-Status: No, hits=-6.2 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_HI, SPF_HELO_PASS, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 19 Mar 2012 21:42:37 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q2JLgbng015441 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 19 Mar 2012 17:42:37 -0400 Received: from adair (ovpn-113-146.phx2.redhat.com [10.3.113.146]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q2JLgajd004524; Mon, 19 Mar 2012 17:42:36 -0400 Date: Mon, 19 Mar 2012 14:42:41 -0700 From: Benjamin De Kosnik To: Richard Guenther Cc: Jonathan Wakely , Kai Tietz , GCC Patches , "libstdc++" Subject: Re: Ping: Re: [patch middle-end]: Fix PR/48814 - [4.4/4.5/4.6/4.7 Regression] Incorrect scalar increment result Message-ID: <20120319144241.6d3f598a@adair> In-Reply-To: References: Mime-Version: 1.0 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On Fri, 16 Mar 2012 11:10:48 +0100 Richard Guenther wrote: > On Fri, Mar 16, 2012 at 1:29 AM, Jonathan Wakely > wrote: > > On 15 March 2012 15:40, Richard Guenther wrote: > >> On Thu, Mar 15, 2012 at 4:22 PM, Kai Tietz > >> wrote: > >>> Richard, > >>> > >>> ping.  I think now could be a good time for applying the patch you > >>> have for this issue as we are in stage 1. > >> > >> It will still regress the two libstdc++ testcases (well, I guess > >> so at least). > >> > >> Jonathan - you didn't answer my reply to your question?  Would it > >> be ok to apply this patch with leaving the regressions in-place, > >> to be investigated by libstdc++ folks? > > > > Sorry, I've either forgotten or missed the reply - but if you think > > the problem is in libstdc++ then certainly go ahead and apply it, > > I'll investigate the libstdc++ problems (and ask for help if they > > defeat me!) > > Ok. I'll do so after re-testing the patch. FYI, here is the patch for the new libstdc++ fails. -benjamin 2012-03-19 Benjamin Kosnik * include/ext/pb_ds/detail/pat_trie_/ constructors_destructor_fn_imps.hpp: Increment after recursion. * include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp: Convert node_type markup from brief. diff --git a/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp b/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp index 8370a2e..c5748ec 100644 --- a/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp +++ b/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/constructors_destructor_fn_imps.hpp @@ -1,6 +1,6 @@ // -*- C++ -*- -// Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011 +// Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -188,7 +188,11 @@ recursive_copy_node(node_const_pointer p_ncp) __try { while (child_it != p_icp->end()) - a_p_children[child_i++] = recursive_copy_node(*(child_it++)); + { + a_p_children[child_i] = recursive_copy_node(*(child_it)); + child_i++; + child_it++; + } p_ret = s_inode_allocator.allocate(1); } __catch(...) diff --git a/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp b/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp index b7eb024..0a763b5 100644 --- a/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp +++ b/libstdc++-v3/include/ext/pb_ds/detail/pat_trie_/pat_trie_base.hpp @@ -1,6 +1,6 @@ // -*- C++ -*- -// Copyright (C) 2005, 2006, 2009, 2011 Free Software Foundation, Inc. +// Copyright (C) 2005, 2006, 2009, 2011, 2012 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the terms @@ -50,7 +50,11 @@ namespace __gnu_pbds /// Base type for PATRICIA trees. struct pat_trie_base { - /// Three types of nodes. + /** + * @brief Three types of nodes. + * + * i_node is used by _Inode, leaf_node by _Leaf, and head_node by _Head. + */ enum node_type { i_node,