From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 33796 invoked by alias); 9 Aug 2016 11:24:42 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 33703 invoked by uid 89); 9 Aug 2016 11:24:38 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_PASS autolearn=ham version=3.3.2 spammy=bs, 11417, 1141,7, coverage X-HELO: mx2.suse.de Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (CAMELLIA256-SHA encrypted) ESMTPS; Tue, 09 Aug 2016 11:24:28 +0000 Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 8D7EAAAD1; Tue, 9 Aug 2016 11:24:25 +0000 (UTC) Subject: [PATCH] Set -fprofile-update=atomic when -pthread is present To: Nathan Sidwell , gcc-patches@gcc.gnu.org References: <53c4f874443d63de99393a9816041ba75f1d605e.1470041316.git.mliska@suse.cz> <95628fa2-8719-bb82-d1ab-ca8d46355020@acm.org> <0ec1ad3f-0fc7-507e-878c-907adae1c011@suse.cz> <0e248978-3717-1d78-b3b1-9fc60ded5c8e@suse.cz> <882f0f98-9b33-a764-833b-ca61796f3143@acm.org> <87f2bc4f-c4df-eadd-aec6-a937ed0ccaba@acm.org> <1253ac69-3301-f185-e43a-a34cadf8f51e@suse.cz> <67fda6d2-9b3e-a0d1-effc-34e1115030b2@acm.org> <1ff3cc75-7cee-79f3-395b-ef7a4d286a3d@acm.org> <04a05835-4666-4d7d-c1a9-d4bcc4ea924a@suse.cz> Cc: jh@suse.cz From: =?UTF-8?Q?Martin_Li=c5=a1ka?= Message-ID: Date: Tue, 09 Aug 2016 11:24:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2 MIME-Version: 1.0 In-Reply-To: <04a05835-4666-4d7d-c1a9-d4bcc4ea924a@suse.cz> Content-Type: multipart/mixed; boundary="------------C3791BF4B4A42D6252F2E505" X-IsSubscribed: yes X-SW-Source: 2016-08/txt/msg00687.txt.bz2 This is a multi-part message in MIME format. --------------C3791BF4B4A42D6252F2E505 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Content-length: 206 Hi. As mention in [1], enabling -fprofile-update=atomic when -pthread is logical thing and is quite expected default behavior. Ready for trunk? [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58306#c21 --------------C3791BF4B4A42D6252F2E505 Content-Type: text/x-patch; name="0001-Set-fprofile-update-atomic-when-pthread-is-present.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename*0="0001-Set-fprofile-update-atomic-when-pthread-is-present.patc"; filename*1="h" Content-length: 885 >From 7135fcf5f7b8f2f3c55a6e80048660c1beea5052 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 9 Aug 2016 13:19:26 +0200 Subject: [PATCH] Set -fprofile-update=atomic when -pthread is present gcc/ChangeLog: 2016-08-09 Martin Liska * gcc.c: Add -fprofile-update=atomic when -pthread is present. --- gcc/gcc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/gcc.c b/gcc/gcc.c index 7460f6a..2f42619 100644 --- a/gcc/gcc.c +++ b/gcc/gcc.c @@ -1141,7 +1141,8 @@ static const char *cc1_options = %{-help=*:--help=%*}\ %{!fsyntax-only:%{S:%W{o*}%{!o*:-o %b.s}}}\ %{fsyntax-only:-o %j} %{-param*}\ - %{coverage:-fprofile-arcs -ftest-coverage}"; + %{coverage:-fprofile-arcs -ftest-coverage}\ + %{pthread:-fprofile-update=atomic}"; static const char *asm_options = "%{-target-help:%:print-asm-header()} " -- 2.9.2 --------------C3791BF4B4A42D6252F2E505--