[cfe-dev] [RFC] A proposal for #pragma optnone
Hal Finkel
hfinkel at anl.gov
Tue Apr 29 06:46:12 PDT 2014
----- Original Message -----
> From: "Renato Golin" <renato.golin at linaro.org>
> To: "Hal Finkel" <hfinkel at anl.gov>
> Cc: "Paul Robinson" <Paul_Robinson at playstation.sony.com>, "clang-dev Developers" <cfe-dev at cs.uiuc.edu>
> Sent: Tuesday, April 29, 2014 8:39:44 AM
> Subject: Re: [cfe-dev] [RFC] A proposal for #pragma optnone
>
> On 29 April 2014 12:33, Hal Finkel <hfinkel at anl.gov> wrote:
> > As Chandler points out, you would want to put them inside function
> > bodies to catch lambdas. However, we should issue a warning in
> > this case.
>
> We can easily skip that semantics for now. GCC doesn't allow it:
>
> error: #pragma GCC optimize is not allowed inside functions
But why? I don't find this gcc comparison a compelling argument. It seems easier to support it, and more useful, than not supporting it. Adding a warning does not seem more difficult than adding the error. Regardless of what gcc does, Clang/LLVM must have a design process that keeps modern C++ in mind, and modern C++ includes lambda functions.
-Hal
>
> cheers,
> -renato
>
--
Hal Finkel
Assistant Computational Scientist
Leadership Computing Facility
Argonne National Laboratory
More information about the cfe-dev
mailing list