From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21649 invoked by alias); 10 Nov 2016 17:31:24 -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 21633 invoked by uid 89); 10 Nov 2016 17:31:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=moon, Hx-languages-length:1562, undesirable X-HELO: mail-pf0-f169.google.com Received: from mail-pf0-f169.google.com (HELO mail-pf0-f169.google.com) (209.85.192.169) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 10 Nov 2016 17:31:22 +0000 Received: by mail-pf0-f169.google.com with SMTP id i88so148905562pfk.2 for ; Thu, 10 Nov 2016 09:31:22 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:subject:to:references:cc:from:message-id :date:user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=G60fYwqNuYjmaHiBKiAmKE5zfuyU3kVEvL/lZz5eyRU=; b=Gq1kY+ay235A7Y6x6eI14P8EbAvq1Xb80Nage+lo2PsDlBgg+TjE8bsRXf8uW+Rft3 2NpyHPpMgyuq0iD6bY8iuNsKbLXZRMdH78AGi8V4PnmYTkxNLjVonW+Jkr+iUfAbk7ar EpZ3izi9mz3koLzjfBZxEiStkIFZ7L50uF8RnBxZ4rOVzAvPIH2PKZ5qKv1NU5YbIDR1 +8gXoQZn7ggneMmyjqmXlneON+e7LhvktF8UiD5jlL7yyi/lNjzqAolY9bRB5Jdg1TT+ SSDFZsFFhfT+GsQCXk7M0EA+9nw9420wj80xxR/4lkhjUcSf31eWk1vRHYXf/Z5wojay Bzkw== X-Gm-Message-State: ABUngvcB0bSU5nEkiPNgGbtng5TODS0mdTolZoolpeXSfLwjoFld7D8QCGGPEeu9zm4q5w== X-Received: by 10.99.159.26 with SMTP id g26mr5273799pge.62.1478799081393; Thu, 10 Nov 2016 09:31:21 -0800 (PST) Received: from ?IPv6:2620:10d:c082:1055:6d69:a153:286a:5ce0? ([2620:10d:c090:200::7:a8f8]) by smtp.googlemail.com with ESMTPSA id y73sm8682981pfa.68.2016.11.10.09.31.19 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 10 Nov 2016 09:31:20 -0800 (PST) Subject: Re: [PATCH] Introduce -fprofile-update=maybe-atomic To: =?UTF-8?Q?Martin_Li=c5=a1ka?= , David Edelsohn References: <87f2bc4f-c4df-eadd-aec6-a937ed0ccaba@acm.org> <1ff3cc75-7cee-79f3-395b-ef7a4d286a3d@acm.org> <04a05835-4666-4d7d-c1a9-d4bcc4ea924a@suse.cz> <87k2fpdatl.fsf@tassilo.jf.intel.com> <6f8b1905-818b-bfff-1bf3-5ba04f3b4b64@suse.cz> <20160818155130.GE5871@two.firstfloor.org> <631cf1bd-8ae9-f07b-5672-5084b699f650@redhat.com> <2c750f4c-c96c-2b22-43ae-53bbebf18af8@suse.cz> <73aa44d7-5287-e4b8-6188-a87d52d3d6b9@acm.org> <9aca1f7c-e7eb-e101-249e-8b5edd21cd48@suse.cz> <2419555f-7271-d64d-94ac-ac97ee7cb953@suse.cz> <4cbaad58-421d-cef5-e1b1-6c78a56d18b8@suse.cz> <5b7cdf6c-54e4-126b-1461-26f88b45dbbb@suse.cz> <36aaf074-5042-c4b9-8d47-9f52313765d6@acm.org> <8e2214bb-3944-7bc7-0d61-098f9f4cadae@suse.cz> <2442c0ca-fa36-30bc-1797-3f30fbd75030@suse.cz> Cc: Jeff Law , Andi Kleen , GCC Patches , Jan Hubicka From: Nathan Sidwell Message-ID: Date: Thu, 10 Nov 2016 17:31:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <2442c0ca-fa36-30bc-1797-3f30fbd75030@suse.cz> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-SW-Source: 2016-11/txt/msg00985.txt.bz2 On 11/10/2016 08:24 AM, Martin Liška wrote: > On 11/10/2016 05:17 PM, David Edelsohn wrote: >> Maybe instead of adding "maybe", we need to change the severity of the >> warning so that the warning is not emitted by default. > > Adding the warning option to -Wextra can be solution. Is it acceptable > approach? I don't think that's good. Now I understand the -pthreads thing, we have different use cases. 1) user explicitly said -fprofile-update=FOO. They shouldn't have to enable something else to get a diagnostic that FOO doesn't work. 2) driver implicitly said -fprofile-update=FOO, because the user said -pthreads but the driver doesn't know if FOO is acceptable. We want to silently fallback to the old behaviour. The proposed solution addresses #2 by having the driver say -fprofile-update=META-FOO. My dislike is that we're exposing this to the user and they're going to start using it. That strikes me as undesirable. How hard is it to implement the fprofile-update option value as a list. I.e. '-fprofile-update=atomic,single', with semantics of 'pick the first one you can do'? If that's straightforwards, then that seems to me as a better solution for #2. [flyby-thought, have 'atomic,single' as an acceptable single option value?] Failing that, Martin's solution is probably the sanest available solution, but I'd like to rename 'maybe-atomic' to the more meaningful 'prefer-atomic'. With 'maybe-atomic', I'm left wondering if it looks at the phase of the moon. nathan -- Nathan Sidwell