https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81519

--- Comment #11 from Daniel Santos <daniel.santos at pobox dot com> ---
(In reply to Eric Gallager from comment #9)
> (In reply to Daniel Santos from comment #7)
> > (In reply to Martin Liška from comment #4)
> > > Ok, so I've briefly investigated source code and providing such 
> > > information
> > > is definitely not a simple task :/
> > > 
> > > I would recommend to fix PR39851 and then one will just compare output of
> > > following 2 invocations:
> > > 
> > > gcc --help=target  -Q
> > > gcc --help=target -march=native -Q 
> > > 
> > > Will it work for you?
> > > 
> > > Note that fully understand which ISA extensions are enable when is also
> > > quite complex.
> > 
> > I've thought about this some more and I'm starting to think that all of this
> > can be determined with a script that iteratively calls gcc --help=target -Q
> > with various machine flags to determine which -mno-* flags are really needed
> > and which -m<isa> flags include others.  So in effect, I'm thinking that we
> > can produce optimal C(XX)FLAGS with a script and your PR39851 fix.  I'll
> > have to test this out.
> > 
> > Thanks
> 
> If you come up with a script, do you want to put it in contrib?

Interesting.  I thought I replied to this already, but maybe that was on a
different bug report?  Anyway, I have a script at
https://github.com/daniel-santos/distccflags but it has a flaw
(https://github.com/daniel-santos/distccflags/issues/2) that I need to fix. 
Other than that, it's fairly use-friendly.  It would probably be a lot cleaner
re-written in perl.

I tried to push this off onto distcc but they wanted it re-written in C.

Reply via email to