Hi all,
Attached are the header and the patch giving support for all the predicates and a portion of another AltiVec functions. The test is also attached.
'altivec.h' is now included implicitly when '-faltivec' option is set. Only vital builtins are handled by clang, others are supported via header.
Please review.
altivec.h (37.6 KB)
altivec.patch (7.6 KB)
builtins-pcc-altivec.c (18.5 KB)
Hi Anton,
I have no opinion or background to decide if this implements the feature properly, but the patch itself looks great to me.
One minor change though: please remove __builtin_altivec_abs_v4sf. Instead of having the builtin, you can just implement vec_abs with the corresponding expanded code in the header. Feel free to apply the patch (or resend and I'll apply) with that change.
Thanks!
-Chris
Hi Chris,
here are updated files
altivec.h (37.7 KB)
altivec.patch (7.03 KB)
builtins-pcc-altivec.c (18.4 KB)
Applied in r101215! Note that I had to xfail test/Parser/cxx-altivec.cpp since it is now dying with this patch, please investigate.
-Chris
Added explicit type casting for cpp
Additionally removed all unneeded functions with plain char argument(s)
altivec.patch (16.4 KB)
builtins-pcc-altivec.c (18.4 KB)
Applied in r101281, thanks!