forked from OSchip/llvm-project
Disallow direct inclusion of avxintrin.h. Users should include immintrin.h instead. This matches GCC's behavior.
llvm-svn: 111692
This commit is contained in:
parent
6f3b38a851
commit
6f35f3cd80
|
@ -21,12 +21,9 @@
|
||||||
*===-----------------------------------------------------------------------===
|
*===-----------------------------------------------------------------------===
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef __AVXINTRIN_H
|
#ifndef __IMMINTRIN_H
|
||||||
#define __AVXINTRIN_H
|
#error "Never use <avxintrin.h> directly; include <immintrin.h> instead."
|
||||||
|
#endif
|
||||||
#ifndef __AVX__
|
|
||||||
#error "AVX instruction set not enabled"
|
|
||||||
#else
|
|
||||||
|
|
||||||
typedef double __v4df __attribute__ ((__vector_size__ (32)));
|
typedef double __v4df __attribute__ ((__vector_size__ (32)));
|
||||||
typedef float __v8sf __attribute__ ((__vector_size__ (32)));
|
typedef float __v8sf __attribute__ ((__vector_size__ (32)));
|
||||||
|
@ -1157,7 +1154,3 @@ _mm256_castsi128_si256(__m128i in)
|
||||||
__m128i zero = _mm_setzero_si128();
|
__m128i zero = _mm_setzero_si128();
|
||||||
return __builtin_shufflevector(in, zero, 0, 1, 2, 2);
|
return __builtin_shufflevector(in, zero, 0, 1, 2, 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* __AVX__ */
|
|
||||||
|
|
||||||
#endif /* __AVXINTRIN_H */
|
|
||||||
|
|
|
@ -4,33 +4,16 @@
|
||||||
|
|
||||||
#if defined(i386) || defined(__x86_64__)
|
#if defined(i386) || defined(__x86_64__)
|
||||||
|
|
||||||
# if defined(__MMX__)
|
#ifdef __MMX__
|
||||||
#include <emmintrin.h>
|
|
||||||
#include <mm_malloc.h>
|
#include <mm_malloc.h>
|
||||||
# endif
|
#endif
|
||||||
|
|
||||||
# if defined(__SSE__)
|
#ifdef __SSE4_2__
|
||||||
#include <xmmintrin.h>
|
// nmmintrin forwards to smmintrin.
|
||||||
# endif
|
|
||||||
|
|
||||||
# if defined(__SSE3__)
|
|
||||||
#include <pmmintrin.h>
|
|
||||||
# endif
|
|
||||||
|
|
||||||
# if defined(__SSSE3__)
|
|
||||||
#include <tmmintrin.h>
|
|
||||||
# endif
|
|
||||||
|
|
||||||
# if defined(__SSE4_1__)
|
|
||||||
#include <smmintrin.h>
|
|
||||||
# endif
|
|
||||||
|
|
||||||
# if defined(__SSE4_2__)
|
|
||||||
#include <nmmintrin.h>
|
#include <nmmintrin.h>
|
||||||
# endif
|
#endif
|
||||||
|
|
||||||
# if defined(__AVX__)
|
// immintrin includes all other intel intrinsic headers.
|
||||||
#include <avxintrin.h>
|
#include <immintrin.h>
|
||||||
# endif
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue