This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Idea: extend gcc to save C from the hell of intel vector instructions


On 2/18/19, Andrew Pinski <pinskia@gmail.com> wrote:
> GCC already has most of this support.  See
> https://gcc.gnu.org/onlinedocs/gcc-8.2.0/gcc/Vector-Extensions.html#Vector-Extensions
>
> The dot in the typenames are not going to supported though.
>
> Thanks,
> Andrew

--what #include files and/or compiler flags are needed to enable this stuff?
(Be nice if that doc page said.)
My gcc allows me to use, e.g.
   c = _mm_shuffle_epi8(a, b);
(and my code worked!) provided I have done
#include <tmmintrin.h>
#include <immintrin.h>

but if I try to replace that with the nicer (since more portable)
   c = __builtin_shuffle(a, b);
then
error: use of unknown builtin '__builtin_shuffle'
[-Wimplicit-function-declaration]

-- 
Warren D. Smith
http://RangeVoting.org  <-- add your endorsement (by clicking
"endorse" as 1st step)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]