[PATCH] Don't #error if including <altivec.h> without -maltivec
Ziemowit Laski
zlaski@apple.com
Fri Mar 26 18:37:00 GMT 2004
On 25 Mar 2004, at 22.52, Segher Boessenkool wrote:
>> But "-maltivec" not only enables AltiVec instructions, but also the
>> various
>> AltiVec _types_, and I _really_ don't think we want to be
>> synthesizing these
>> types unconditionally. :-)
>
> And that is wrong. The option should do one thing, and one thing only.
> If there is a need to disable AltiVec vector types, there should be a
> separate option for that. But I don't see why that would be needed?
>
>>> I actually have some code like that, and it breaks with TOT compiler.
>>
>> If you want to use "generic" GCC vectors, then you should probably
>> use generic syntax for them as well (i.e.,
>> __attribute__(size_type(...)))
>> or whatever it is this week).
>
> No, I want AltiVec vectors.
Well, feel free to hit up one of the AltiVec maintainers (I'm _not_ one
of them, believe it or not :-) ). You'll need to change rs6000.c to
unconditionally construct the AltiVec types, and rs6000-c.c to
unconditionally #define __vector,
__pixel and friends (or you can move the latter into altivec.h, I
suppose).
--Zem
More information about the Gcc-patches
mailing list