From patchwork Fri Dec 16 17:36:36 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Vyukov X-Patchwork-Id: 131877 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 52E291007D7 for ; Sat, 17 Dec 2011 04:37:08 +1100 (EST) Received: (qmail 31540 invoked by alias); 16 Dec 2011 17:37:01 -0000 Received: (qmail 31414 invoked by uid 22791); 16 Dec 2011 17:36:59 -0000 X-SWARE-Spam-Status: No, hits=-4.1 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-ee0-f73.google.com (HELO mail-ee0-f73.google.com) (74.125.83.73) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 16 Dec 2011 17:36:38 +0000 Received: by eekd41 with SMTP id d41so48097eek.2 for ; Fri, 16 Dec 2011 09:36:37 -0800 (PST) Received: by 10.14.119.4 with SMTP id m4mr1526791eeh.7.1324056997163; Fri, 16 Dec 2011 09:36:37 -0800 (PST) Received: by 10.14.119.4 with SMTP id m4mr1526782eeh.7.1324056996966; Fri, 16 Dec 2011 09:36:36 -0800 (PST) Received: from hpza9.eem.corp.google.com ([74.125.121.33]) by gmr-mx.google.com with ESMTPS id a53si7224189eeg.1.2011.12.16.09.36.36 (version=TLSv1/SSLv3 cipher=AES128-SHA); Fri, 16 Dec 2011 09:36:36 -0800 (PST) Received: from 1024cores.msk.corp.google.com (1024cores.msk.corp.google.com [172.28.51.220]) by hpza9.eem.corp.google.com (Postfix) with ESMTP id D6A695C0050; Fri, 16 Dec 2011 09:36:36 -0800 (PST) Received: by 1024cores.msk.corp.google.com (Postfix, from userid 129372) id 47B85C30C1; Fri, 16 Dec 2011 21:36:36 +0400 (MSK) To: reply@codereview.appspotmail.com,gcc-patches@gcc.gnu.org Subject: Address the comments (issue5492055) Message-Id: <20111216173636.47B85C30C1@1024cores.msk.corp.google.com> Date: Fri, 16 Dec 2011 21:36:36 +0400 (MSK) From: dvyukov@google.com (Dmitriy Vyukov) 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 This is for google-main branch. Ignore thunks in ThreadSanitizer pass. --- This patch is available for review at http://codereview.appspot.com/5492055 Index: gcc/tree-tsan.c =================================================================== --- gcc/tree-tsan.c (revision 182401) +++ gcc/tree-tsan.c (working copy) @@ -426,6 +426,10 @@ ignore_init = 1; } + /* Must be some artificial thunk function. */ + if (DECL_ARTIFICIAL (cfun->decl) && DECL_IGNORED_P (cfun->decl)) + return tsan_ignore_func; + src_name = expand_location (cfun->function_start_locus).file; if (src_name == NULL) src_name = ""; Index: gcc/ChangeLog.google-main =================================================================== --- gcc/ChangeLog.google-main (revision 182401) +++ gcc/ChangeLog.google-main (working copy) @@ -1,3 +1,7 @@ +2011-12-16 Dmitriy Vyukov + + * tree-tsan.c (tsan_ignore): Add check for thunks. + 2011-12-16 Dehao Chen * ipa-inline-transform.c (dump_inline_decision): New function.