diff --git a/gcc/config/rs6000/smmintrin.h b/gcc/config/rs6000/smmintrin.h index 382f50c90c5..919627b0810 100644 --- a/gcc/config/rs6000/smmintrin.h +++ b/gcc/config/rs6000/smmintrin.h @@ -232,4 +232,36 @@ _mm_test_mix_ones_zeros (__m128i __A, __m128i __mask) return any_ones * any_zeros; } +__inline __m128d +__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) +_mm_ceil_pd (__m128d __A) +{ + return (__m128d) vec_ceil ((__v2df) __A); +} + +__inline __m128d +__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) +_mm_ceil_sd (__m128d __A, __m128d __B) +{ + __v2df __r = vec_ceil ((__v2df) __B); + __r[1] = ((__v2df) __A)[1]; + return (__m128d) __r; +} + +__inline __m128 +__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) +_mm_ceil_ps (__m128 __A) +{ + return (__m128) vec_ceil ((__v4sf) __A); +} + +__inline __m128 +__attribute__ ((__gnu_inline__, __always_inline__, __artificial__)) +_mm_ceil_ss (__m128 __A, __m128 __B) +{ + __v4sf __r = (__v4sf) __A; + __r[0] = __builtin_ceil (((__v4sf) __B)[0]); + return __r; +} + #endif