On 07/19/2018 03:47 PM, Jakub Jelinek wrote:
> On Thu, Jul 19, 2018 at 03:25:15PM +0200, Martin Liška wrote:
>> Few weeks ago I added new Deprecated flag for options. Apparently, there's
>> one similar called Ignore. Thus I moved all Deprecated to Ignore and for
>> all Ignored I do a warning of following format:
>>
>> $ xgcc: warning: switch ‘-mmpx’ is no longer supported
> 
> Is that what we want for all the Ignore options?  Looking at {,*/}*.opt,
> I see a lot of options that have those Warn(switch %qs is no longer supported)
> and a lot of them that do not, while with your patch it will now warn all.

I must admit that was my intention :) In my eyes it makes it more consistent and
it gives consumers feedback about usage of an option that does nothing.
For x86_64 there's list of options that are Ignore and don't produce a warning:

Wimport
Wunreachable-code
Wunsafe-loop-optimizations
fargument-alias
fargument-noalias
fargument-noalias-anything
fargument-noalias-global
fcse-skip-blocks
fdefault-inline
fdump-core
feliminate-dwarf2-dups
fforce-addr
fipa-cp-alignment
fipa-matrix-reorg
fipa-struct-reorg
floop-flatten
floop-optimize
foptimize-register-move
foptional-diags
fregmove
frerun-loop-opt
fsched2-use-traces
fsee
fstrength-reduce
ftree-coalesce-inlined-vars
ftree-copyrename
ftree-loop-if-convert-stores
ftree-salias
ftree-store-ccp
ftree-store-copy-prop
ftree-vect-loop-version
ftree-vectorizer-verbose=
funsafe-loop-optimizations
fwhole-file
fzee


> Especially when it is a warning without corresponding -W... option that can
> be quite nasty.

As spoken on IRC, we can always add -Wno-ignored-options that will suppress the 
warnings. We'll do distro rebuild before next release, so if huge numbers
of the warnings will be seen, we can revert that.

Martin

> 
> Wouldn't be better to just remove Deprecated and keep the Ignore behavior it
> had?  Or make Deprecated effectively an alias for
> Ignore Warn(switch %qs is no longer supported)
> and use it for those options that did that?
> 
>       Jakub
> 

Reply via email to