-2008-03-13 Uros Bizjak <ubizjak@gmail.com>
-
- PR target/35553
- * config/i386/i386.h (TARGET_CPU_CPP_BUILTINS): Define
- __SSE_USE_INLINED_FUNC__ when using -flag-keep-inline-functions
- together with optimization.
- * config/i386/xmmintrin.h: Use __SSE_USE_INLINED_FUNC__ instead of
- __OPTIMIZE__ to choose between inlined intrinsic SSE function having
- immediate arguments and its equivalent macro definition.
- * config/i386/bmintrin.h: Ditto.
- * config/i386/smmintrin.h: Ditto.
- * config/i386/tmmintrin.h: Ditto.
- * config/i386/mmintrin-common.h: Ditto.
- * config/i386/ammintrin.h: Ditto.
- * config/i386/emmintrin.h: Ditto.
-
2008-03-13 Jakub Jelinek <jakub@redhat.com>
PR middle-end/35185
return (__m128i) __builtin_ia32_extrq ((__v2di) __X, (__v16qi) __Y);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_extracti_si64 (__m128i __X, unsigned const int __I, unsigned const int __L)
{
return (__m128i) __builtin_ia32_insertq ((__v2di)__X, (__v2di)__Y);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_inserti_si64(__m128i __X, __m128i __Y, unsigned const int __I, unsigned const int __L)
{
/* Rotates - Immediate form */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_roti_epi8(__m128i __A, const int __B)
{
return (__m128d)__builtin_ia32_cvtss2sd ((__v2df) __A, (__v4sf)__B);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128d __attribute__((__always_inline__, __artificial__))
_mm_shuffle_pd(__m128d __A, __m128d __B, const int __mask)
{
return (__m128i)__builtin_ia32_psradi128 ((__v4si)__A, __B);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_srli_si128 (__m128i __A, const int __N)
{
return (__m128i)__builtin_ia32_pcmpgtd128 ((__v4si)__A, (__v4si)__B);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline int __attribute__((__always_inline__, __artificial__))
_mm_extract_epi16 (__m128i const __A, int const __N)
{
return (__m128i)__builtin_ia32_pmulhuw128 ((__v8hi)__A, (__v8hi)__B);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_shufflehi_epi16 (__m128i __A, const int __mask)
{
builtin_define ("__SSE_MATH__"); \
if (TARGET_SSE_MATH && TARGET_SSE2) \
builtin_define ("__SSE2_MATH__"); \
- \
- /* Use inlined intrinsic SSE function having immediate \
- arguments instead of a macro definition. */ \
- if (optimize && !flag_keep_inline_functions) \
- builtin_define ("__SSE_USE_INLINED_FUNC__"); \
} \
while (0)
/* Packed/scalar double precision floating point rounding. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128d __attribute__((__always_inline__, __artificial__))
_mm_round_pd (__m128d __V, const int __M)
{
/* Packed/scalar single precision floating point rounding. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128 __attribute__((__always_inline__, __artificial__))
_mm_round_ps (__m128 __V, const int __M)
{
/* Integer blend instructions - select data from 2 sources using
constant/variable mask. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_blend_epi16 (__m128i __X, __m128i __Y, const int __M)
{
/* Single precision floating point blend instructions - select data
from 2 sources using constant/variable mask. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128 __attribute__((__always_inline__, __artificial__))
_mm_blend_ps (__m128 __X, __m128 __Y, const int __M)
{
/* Double precision floating point blend instructions - select data
from 2 sources using constant/variable mask. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128d __attribute__((__always_inline__, __artificial__))
_mm_blend_pd (__m128d __X, __m128d __Y, const int __M)
{
/* Dot product instructions with mask-defined summing and zeroing parts
of result. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128 __attribute__((__always_inline__, __artificial__))
_mm_dp_ps (__m128 __X, __m128 __Y, const int __M)
{
index, the bits [5-4] define D index, and bits [3-0] define
zeroing mask for D. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128 __attribute__((__always_inline__, __artificial__))
_mm_insert_ps (__m128 __D, __m128 __S, const int __N)
{
/* Extract binary representation of single precision float from packed
single precision array element of X selected by index N. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline int __attribute__((__always_inline__, __artificial__))
_mm_extract_ps (__m128 __X, const int __N)
{
/* Insert integer, S, into packed integer array element of D
selected by index N. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_insert_epi8 (__m128i __D, int __S, const int __N)
{
/* Extract integer from packed integer array element of X selected by
index N. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline int __attribute__((__always_inline__, __artificial__))
_mm_extract_epi8 (__m128i __X, const int __N)
{
byte integers in the first 2 operands. Starting offsets within
operands are determined by the 3rd mask operand. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_mpsadbw_epu8 (__m128i __X, __m128i __Y, const int __M)
{
/* Intrinsics for text/string processing. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_cmpistrm (__m128i __X, __m128i __Y, const int __M)
{
/* Intrinsics for text/string processing and reading values of
EFlags. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline int __attribute__((__always_inline__, __artificial__))
_mm_cmpistra (__m128i __X, __m128i __Y, const int __M)
{
return (__m64) __builtin_ia32_psignd ((__v2si)__X, (__v2si)__Y);
}
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128i __attribute__((__always_inline__, __artificial__))
_mm_alignr_epi8(__m128i __X, __m128i __Y, const int __N)
{
}
/* Selects four specific SPFP values from A and B based on MASK. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m128 __attribute__((__always_inline__, __artificial__))
_mm_shuffle_ps (__m128 __A, __m128 __B, int const __mask)
{
}
/* Extracts one of the four words of A. The selector N must be immediate. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline int __attribute__((__always_inline__, __artificial__))
_mm_extract_pi16 (__m64 const __A, int const __N)
{
/* Inserts word D into one of four words of A. The selector N must be
immediate. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m64 __attribute__((__always_inline__, __artificial__))
_mm_insert_pi16 (__m64 const __A, int const __D, int const __N)
{
/* Return a combination of the four 16-bit values in A. The selector
must be an immediate. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline __m64 __attribute__((__always_inline__, __artificial__))
_mm_shuffle_pi16 (__m64 __A, int const __N)
{
/* Loads one cache line from address P to a location "closer" to the
processor. The selector I specifies the type of prefetch operation. */
-#ifdef __SSE_USE_INLINED_FUNC__
+#ifdef __OPTIMIZE__
static __inline void __attribute__((__always_inline__, __artificial__))
_mm_prefetch (const void *__P, enum _mm_hint __I)
{
-2008-03-13 Uros Bizjak <ubizjak@gmail.com>
-
- PR target/35553
- * g++.dg/other/i386-3.C: New test.
-
2008-03-13 Paolo Bonzini <bonzini@gnu.org>
PR tree-opt/35422
+++ /dev/null
-/* Test that {,x,e,p,t,s,a,b}mmintrin.h, mm3dnow.h and mm_malloc.h are
- usable with -O -fkeep-inline-functions. */
-/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O -fkeep-inline-functions -march=k8 -m3dnow -msse4 -msse5" } */
-
-#include <bmmintrin.h>
-#include <smmintrin.h>
-#include <mm3dnow.h>