From patchwork Tue Nov 23 15:52:20 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aldy Hernandez X-Patchwork-Id: 72692 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 4EDBCB70DE for ; Wed, 24 Nov 2010 02:52:43 +1100 (EST) Received: (qmail 16936 invoked by alias); 23 Nov 2010 15:52:40 -0000 Received: (qmail 16927 invoked by uid 22791); 23 Nov 2010 15:52:39 -0000 X-SWARE-Spam-Status: No, hits=-6.3 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; Tue, 23 Nov 2010 15:52:24 +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.13.8/8.13.8) with ESMTP id oANFqN9l012459 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 23 Nov 2010 10:52:23 -0500 Received: from redhat.com (vpn-11-32.rdu.redhat.com [10.11.11.32]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id oANFqKeU024444 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Tue, 23 Nov 2010 10:52:22 -0500 Date: Tue, 23 Nov 2010 10:52:20 -0500 From: Aldy Hernandez To: gcc-patches@gcc.gnu.org, rth@redhat.com Subject: [trans-mem] PR45940: respect pure annotations in STL Message-ID: <20101123155212.GA8618@redhat.com> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-08-17) 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 If the user said the caller was TM-pure, respect it, similarly to what we do with TM-safe annotated functions. OK for branch? PR/45940 * trans-mem.c (ipa_tm_execute): Do not push caller into worklist if it is tm_pure. Index: trans-mem.c =================================================================== --- trans-mem.c (revision 166949) +++ trans-mem.c (working copy) @@ -4513,6 +4513,7 @@ ipa_tm_execute (void) for (e = node->callers; e ; e = e->next_caller) if (!is_tm_safe (e->caller->decl) + && !is_tm_pure (e->caller->decl) && !e->caller->local.tm_may_enter_irr) maybe_push_queue (e->caller, &worklist, &d->in_worklist); }