From bc1e43ea95b9455cdccee442db77bc5fafd3dcc6 Mon Sep 17 00:00:00 2001 From: David Monniaux Date: Tue, 26 May 2020 22:11:32 +0200 Subject: tests for kvx --- test/kvx/instr/builtin64.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 test/kvx/instr/builtin64.c (limited to 'test/kvx/instr/builtin64.c') diff --git a/test/kvx/instr/builtin64.c b/test/kvx/instr/builtin64.c new file mode 100644 index 00000000..252eb2c6 --- /dev/null +++ b/test/kvx/instr/builtin64.c @@ -0,0 +1,17 @@ +#include "framework.h" + +BEGIN_TEST(long long) + long long *ptr = &c; +#ifdef __KVX__ + long long d = c; + a = __builtin_kvx_alclrd(ptr); + c = d; + c += a; + + c += __builtin_clzll(a); + + /* Removed the AFADDD builtin who was incorrect in CompCert, see #157 */ + // a = __builtin_kvx_afaddd(ptr, a); + // a = __builtin_kvx_afaddd(ptr, a); +#endif +END_TEST64() -- cgit