diff options
| author | Anders Carlsson <andersca@mac.com> | 2008-12-22 03:16:40 +0000 |
|---|---|---|
| committer | Anders Carlsson <andersca@mac.com> | 2008-12-22 03:16:40 +0000 |
| commit | 1e71996bd19aa8b1d4816acbae18874bc64f1f57 (patch) | |
| tree | b5f7c8990b8542c762cb249e38f23fa8daf8d473 /clang/lib/Headers/xmmintrin.devel.h | |
| parent | c7d0d8b60d5b9dbe256bc79f738b766b03b97661 (diff) | |
| download | bcm5719-llvm-1e71996bd19aa8b1d4816acbae18874bc64f1f57.tar.gz bcm5719-llvm-1e71996bd19aa8b1d4816acbae18874bc64f1f57.zip | |
Add store intrinsics
llvm-svn: 61322
Diffstat (limited to 'clang/lib/Headers/xmmintrin.devel.h')
| -rw-r--r-- | clang/lib/Headers/xmmintrin.devel.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/clang/lib/Headers/xmmintrin.devel.h b/clang/lib/Headers/xmmintrin.devel.h index 828f0dd6a59..f5ae1b677b2 100644 --- a/clang/lib/Headers/xmmintrin.devel.h +++ b/clang/lib/Headers/xmmintrin.devel.h @@ -480,6 +480,43 @@ static inline __m128 __attribute__((__always__inline__)) _mm_setzero_ps(void) return (__m128){ 0, 0, 0, 0 }; } +static inline void __attribute__((__always__inline__)) _mm_storeh_pi(__m64 *p, __m128 a) +{ + __builtin_ia32_storehps((__v2si *)p, a); +} + +static inline void __attribute__((__always__inline__)) _mm_storel_pi(__m64 *p, __m128 a) +{ + __builtin_ia32_storelps((__v2si *)p, a); +} + +static inline void __attribute__((__always__inline__)) _mm_store_ss(float *p, __m128 a) +{ + *p = a[0]; +} + +static inline void __attribute__((__always_inline__)) _mm_storeu_ps(float *p, __m128 a) +{ + __builtin_ia32_storeups(p, a); +} + +static inline void __attribute__((__always_inline__)) _mm_store1_ps(float *p, __m128 a) +{ + a = __builtin_shufflevector(a, a, 0, 0, 0, 0); + _mm_storeu_ps(p, a); +} + +static inline void __attribute__((__always_inline__)) _mm_store_ps(float *p, __m128 a) +{ + *(__m128 *)p = a; +} + +static inline void __attribute__((__always_inline__)) _mm_storer_ps(float *p, __m128 a) +{ + a = __builtin_shufflevector(a, a, 3, 2, 1, 0); + _mm_store_ps(p, a); +} + #endif /* __SSE__ */ #endif /* __XMMINTRIN_H */ |

