diff options
Diffstat (limited to 'lib/Headers/emmintrin.h')
-rw-r--r-- | lib/Headers/emmintrin.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/Headers/emmintrin.h b/lib/Headers/emmintrin.h index e22ffaf19240a..656bc19d3dea1 100644 --- a/lib/Headers/emmintrin.h +++ b/lib/Headers/emmintrin.h @@ -24,6 +24,10 @@ #ifndef __EMMINTRIN_H #define __EMMINTRIN_H +#ifndef __SSE2__ +#error "SSE2 instruction set not enabled" +#else + #include <xmmintrin.h> typedef double __m128d __attribute__((__vector_size__(16))); @@ -36,7 +40,7 @@ typedef short __v8hi __attribute__((__vector_size__(16))); typedef char __v16qi __attribute__((__vector_size__(16))); /* Define the default attributes for the functions in this file. */ -#define __DEFAULT_FN_ATTRS __attribute__((__always_inline__, __nodebug__, __target__("sse2"))) +#define __DEFAULT_FN_ATTRS __attribute__((__always_inline__, __nodebug__)) static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_add_sd(__m128d __a, __m128d __b) @@ -1471,4 +1475,6 @@ _mm_pause(void) #define _MM_SHUFFLE2(x, y) (((x) << 1) | (y)) +#endif /* __SSE2__ */ + #endif /* __EMMINTRIN_H */ |