mirror of
https://github.com/shadps4-emu/ext-cryptopp.git
synced 2024-11-23 09:59:42 +00:00
Update Power7 tests for Clang
Clang 3.4 and 3.8 are resiting the builtins
This commit is contained in:
parent
743cb6a0e6
commit
20d3db813b
@ -1,13 +1,21 @@
|
||||
#ifdef __GNUC__
|
||||
# pragma GCC diagnostic ignored "-Wdeprecated"
|
||||
#endif
|
||||
|
||||
#include <altivec.h>
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
#if defined(_ARCH_PWR7)
|
||||
__vector unsigned int x = {1, 2};
|
||||
__vector unsigned int y = vec_add(x, vec_ld(0, (__vector unsigned int*)argv[0]));
|
||||
__vector unsigned int a = {1,2,3,4};
|
||||
__vector unsigned int b = vec_ld(0, (__vector unsigned int*)argv[0]);
|
||||
__vector unsigned int c = vec_xor(a, b);
|
||||
|
||||
__vector unsigned int x = {5,6,7,8};
|
||||
__vector unsigned int y = vec_xl(0, (__vector unsigned int*)argv[0]);
|
||||
__vector unsigned int z = vec_xor(x, y);
|
||||
# if defined(__VSX__)
|
||||
__vector unsigned long long xx = (__vector unsigned long long)x;
|
||||
__vector unsigned long long yy = (__vector unsigned long long)y;
|
||||
__vector unsigned long long xx = {1,2};
|
||||
__vector unsigned long long yy = vec_xl(0, (__vector unsigned long long*)argv[0]);
|
||||
__vector unsigned long long zz = vec_xor(xx, yy);
|
||||
# endif
|
||||
#else
|
||||
|
@ -78,8 +78,8 @@
|
||||
#endif
|
||||
|
||||
// IBM XLC on AIX does not define __VSX__ with -qarch=pwr7
|
||||
// or with -qarch=pwr8. The manual says it is available with
|
||||
// the architectures; see XL C: Compiler Reference p. 104.
|
||||
// or -qarch=pwr8. The manual says it is available with the
|
||||
// architectures; see XL C: Compiler Reference p. 104.
|
||||
#if defined(_AIX) && (defined(_ARCH_PWR7) || defined(_ARCH_PWR8)) && defined(__xlC__)
|
||||
# undef __VSX__
|
||||
# define __VSX__ 1
|
||||
|
Loading…
Reference in New Issue
Block a user