[PATCH] D30415: Fix -mno-altivec cannot overwrite -maltivec option

Eric Christopher via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 16 19:21:39 PDT 2017


Great, thanks! Can you make this change instead Sean? :)

-eric

On Thu, Mar 16, 2017 at 7:20 PM Hal Finkel <hfinkel at anl.gov> wrote:

>
> On 03/16/2017 08:11 PM, Eric Christopher wrote:
>
>
>
> On Thu, Mar 16, 2017 at 5:45 PM Hal Finkel <hfinkel at anl.gov> wrote:
>
>
> On 03/16/2017 07:40 PM, Eric Christopher wrote:
>
>
>
> On Thu, Mar 16, 2017 at 5:37 PM Hal Finkel via Phabricator <
> reviews at reviews.llvm.org> wrote:
>
> hfinkel added a comment.
>
> In https://reviews.llvm.org/D30415#703398, @echristo wrote:
>
> > Different suggestion:
> >
> > Remove the faltivec option. Even gcc doesn't support it anymore afaict.
>
>
> What are you suggesting? Always having the language extensions on? Or
> explicitly tying the language extensions to the underlying target feature?
>
>
> I was thinking the latter.
>
>
> Is that what GCC now does?
>
>
> That would be my guess given the option isn't listed anymore, but what it
> does is this:
>
> echristo at dzur ~/s/gcc-git> grep -r faltivec *
> gcc/testsuite/gcc.target/powerpc/stabs-attrib-vect-darwin.c:/* {
> dg-options "-gstabs+ -fno-eliminate-unused-debug-types -faltivec" } */
> gcc/testsuite/ChangeLog-1993-2007: * g++.dg/ext/altivec-8.C: Use
> '-maltivec' instead of '-faltivec';
> gcc/config/rs6000/darwin.h:   the kernel or some such.  The "-faltivec"
> option should have been
> gcc/config/rs6000/darwin.h:  %{faltivec:-maltivec -include altivec.h}
> %{fno-altivec:-mno-altivec} \
> gcc/config/rs6000/darwin.h:  %<faltivec %<fno-altivec " \
> gcc/config/rs6000/darwin.opt:faltivec
> gcc/ChangeLog-2003: -maltivec is specified, not the non-existent
> -faltivec.
> gcc/ChangeLog-2010: * config/rs6000/darwin.h (CC1_SPEC): Handle -faltivec
> and -fno-altivec.
> gcc/ChangeLog-2010: * config/rs6000/darwin.opt (Waltivec-long-deprecated,
> faltivec,
>
> and only on darwin. I don't see anything that treats the faltivec alias as
> anything language specific anywhere. It basically just says "pass the
> include and turn on maltivec".
>
> At this point I'm pretty sure that -faltivec can just be ignored.
>
>
> It is certainly fair to say that having the ability to use -fno-altivec
> was much more important when -faltivec included altivec.h (which injected
> names like vec_add into the global namespace). I'm fine with enabling the
> vector syntax extensions when targeting altivec is enabled (they're
> extensions to extensions anyway).
>
>
>  -Hal
>
>
>
> -eric
>
>
>
>  -Hal
>
>
>
> -eric
>
>
> > (Go ahead and commit the zvector part if you'd like).
> >
> > -eric
>
>
>
>
> https://reviews.llvm.org/D30415
>
>
>
>
> --
> Hal Finkel
> Lead, Compiler Technology and Programming Languages
> Leadership Computing Facility
> Argonne National Laboratory
>
>
> --
> Hal Finkel
> Lead, Compiler Technology and Programming Languages
> Leadership Computing Facility
> Argonne National Laboratory
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170317/a4ca2b93/attachment-0001.html>


More information about the cfe-commits mailing list