diff options
| author | Eric Christopher <echristo@gmail.com> | 2016-05-24 22:25:06 +0000 |
|---|---|---|
| committer | Eric Christopher <echristo@gmail.com> | 2016-05-24 22:25:06 +0000 |
| commit | d83af71b3a7789867fecabcac2e140fc15a23aca (patch) | |
| tree | c2d8fa947bdad3bc67b28fa8b87f41a86e017a5e | |
| parent | 7004e06b806d5700285320c21f1e5483c84e6c5c (diff) | |
| download | bcm5719-llvm-d83af71b3a7789867fecabcac2e140fc15a23aca.tar.gz bcm5719-llvm-d83af71b3a7789867fecabcac2e140fc15a23aca.zip | |
Make the altivec intrinsics that require immediate constant propagation
macros rather than functions.
Unfortunately couldn't come up with a simple testcase that didn't need
code generation to verify what was going on.
llvm-svn: 270625
| -rw-r--r-- | clang/lib/Headers/altivec.h | 32 |
1 files changed, 12 insertions, 20 deletions
diff --git a/clang/lib/Headers/altivec.h b/clang/lib/Headers/altivec.h index 77bc9286159..74a1914ce83 100644 --- a/clang/lib/Headers/altivec.h +++ b/clang/lib/Headers/altivec.h @@ -2102,32 +2102,24 @@ static __inline__ void __attribute__((__always_inline__)) vec_dssall(void) { } /* vec_dst */ - -static __inline__ void __attribute__((__always_inline__)) -vec_dst(const void *__a, int __b, int __c) { - __builtin_altivec_dst(__a, __b, __c); -} +#define vec_dst(__PTR, __CW, __STR) \ + __extension__( \ + { __builtin_altivec_dst((const void *)(__PTR), (__CW), (__STR)); }) /* vec_dstst */ - -static __inline__ void __attribute__((__always_inline__)) -vec_dstst(const void *__a, int __b, int __c) { - __builtin_altivec_dstst(__a, __b, __c); -} +#define vec_dstst(__PTR, __CW, __STR) \ + __extension__( \ + { __builtin_altivec_dstst((const void *)(__PTR), (__CW), (__STR)); }) /* vec_dststt */ - -static __inline__ void __attribute__((__always_inline__)) -vec_dststt(const void *__a, int __b, int __c) { - __builtin_altivec_dststt(__a, __b, __c); -} +#define vec_dststt(__PTR, __CW, __STR) \ + __extension__( \ + { __builtin_altivec_dststt((const void *)(__PTR), (__CW), (__STR)); }) /* vec_dstt */ - -static __inline__ void __attribute__((__always_inline__)) -vec_dstt(const void *__a, int __b, int __c) { - __builtin_altivec_dstt(__a, __b, __c); -} +#define vec_dstt(__PTR, __CW, __STR) \ + __extension__( \ + { __builtin_altivec_dstt((const void *)(__PTR), (__CW), (__STR)); }) /* vec_eqv */ |

