[clang] 9d27139 - [SystemZ] Fix __builtin_s390_vceq* inconsistency
Ulrich Weigand via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 4 08:02:26 PST 2023
Author: Ulrich Weigand
Date: 2023-12-04T17:00:05+01:00
New Revision: 9d27139293890a18b903c62f2c43954cc2bc302d
URL: https://github.com/llvm/llvm-project/commit/9d27139293890a18b903c62f2c43954cc2bc302d
DIFF: https://github.com/llvm/llvm-project/commit/9d27139293890a18b903c62f2c43954cc2bc302d.diff
LOG: [SystemZ] Fix __builtin_s390_vceq* inconsistency
The __builtin_s390_vceq* family of builtins currently take
signed arguments with clang, but unsigned with GCC. Update
clang to match existing GCC precendent.
Added:
Modified:
clang/include/clang/Basic/BuiltinsSystemZ.def
clang/lib/Headers/vecintrin.h
clang/test/CodeGen/SystemZ/builtins-systemz-vector.c
Removed:
################################################################################
diff --git a/clang/include/clang/Basic/BuiltinsSystemZ.def b/clang/include/clang/Basic/BuiltinsSystemZ.def
index 02171d29ffd91..4cfc52ae42168 100644
--- a/clang/include/clang/Basic/BuiltinsSystemZ.def
+++ b/clang/include/clang/Basic/BuiltinsSystemZ.def
@@ -80,10 +80,10 @@ TARGET_BUILTIN(__builtin_s390_vavglb, "V16UcV16UcV16Uc", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vavglh, "V8UsV8UsV8Us", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vavglf, "V4UiV4UiV4Ui", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vavglg, "V2ULLiV2ULLiV2ULLi", "nc", "vector")
-TARGET_BUILTIN(__builtin_s390_vceqbs, "V16ScV16ScV16Sci*", "nc", "vector")
-TARGET_BUILTIN(__builtin_s390_vceqhs, "V8SsV8SsV8Ssi*", "nc", "vector")
-TARGET_BUILTIN(__builtin_s390_vceqfs, "V4SiV4SiV4Sii*", "nc", "vector")
-TARGET_BUILTIN(__builtin_s390_vceqgs, "V2SLLiV2SLLiV2SLLii*", "nc", "vector")
+TARGET_BUILTIN(__builtin_s390_vceqbs, "V16ScV16UcV16Uci*", "nc", "vector")
+TARGET_BUILTIN(__builtin_s390_vceqhs, "V8SsV8UsV8Usi*", "nc", "vector")
+TARGET_BUILTIN(__builtin_s390_vceqfs, "V4SiV4UiV4Uii*", "nc", "vector")
+TARGET_BUILTIN(__builtin_s390_vceqgs, "V2SLLiV2ULLiV2ULLii*", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vchbs, "V16ScV16ScV16Sci*", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vchhs, "V8SsV8SsV8Ssi*", "nc", "vector")
TARGET_BUILTIN(__builtin_s390_vchfs, "V4SiV4SiV4Sii*", "nc", "vector")
diff --git a/clang/lib/Headers/vecintrin.h b/clang/lib/Headers/vecintrin.h
index 0ea411f40218e..ecfd6cd1a2f87 100644
--- a/clang/lib/Headers/vecintrin.h
+++ b/clang/lib/Headers/vecintrin.h
@@ -2689,7 +2689,8 @@ vec_cmplt(__vector double __a, __vector double __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 0;
}
@@ -2697,7 +2698,8 @@ vec_all_eq(__vector signed char __a, __vector signed char __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 0;
}
@@ -2705,15 +2707,15 @@ vec_all_eq(__vector signed char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, __b, &__cc);
return __cc == 0;
}
@@ -2721,8 +2723,7 @@ vec_all_eq(__vector unsigned char __a, __vector unsigned char __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, (__vector unsigned char)__b, &__cc);
return __cc == 0;
}
@@ -2730,23 +2731,23 @@ vec_all_eq(__vector unsigned char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a, __b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 0;
}
@@ -2754,7 +2755,8 @@ vec_all_eq(__vector signed short __a, __vector signed short __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 0;
}
@@ -2762,15 +2764,15 @@ vec_all_eq(__vector signed short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, __b, &__cc);
return __cc == 0;
}
@@ -2778,8 +2780,7 @@ vec_all_eq(__vector unsigned short __a, __vector unsigned short __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, (__vector unsigned short)__b, &__cc);
return __cc == 0;
}
@@ -2787,23 +2788,23 @@ vec_all_eq(__vector unsigned short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a, __b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 0;
}
@@ -2811,7 +2812,8 @@ vec_all_eq(__vector signed int __a, __vector signed int __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 0;
}
@@ -2819,15 +2821,15 @@ vec_all_eq(__vector signed int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, __b, &__cc);
return __cc == 0;
}
@@ -2835,8 +2837,7 @@ vec_all_eq(__vector unsigned int __a, __vector unsigned int __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, (__vector unsigned int)__b, &__cc);
return __cc == 0;
}
@@ -2844,23 +2845,23 @@ vec_all_eq(__vector unsigned int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a, __b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 0;
}
@@ -2868,7 +2869,8 @@ vec_all_eq(__vector signed long long __a, __vector signed long long __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector signed long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 0;
}
@@ -2876,15 +2878,15 @@ vec_all_eq(__vector signed long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, __b, &__cc);
return __cc == 0;
}
@@ -2892,8 +2894,7 @@ vec_all_eq(__vector unsigned long long __a, __vector unsigned long long __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector unsigned long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, (__vector unsigned long long)__b, &__cc);
return __cc == 0;
}
@@ -2901,16 +2902,15 @@ vec_all_eq(__vector unsigned long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a, __b, &__cc);
return __cc == 0;
}
static inline __ATTRS_o_ai int
vec_all_eq(__vector __bool long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 0;
}
@@ -2935,7 +2935,8 @@ vec_all_eq(__vector double __a, __vector double __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
@@ -2943,7 +2944,8 @@ vec_all_ne(__vector signed char __a, __vector signed char __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
@@ -2951,15 +2953,16 @@ vec_all_ne(__vector signed char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
@@ -2967,8 +2970,7 @@ vec_all_ne(__vector unsigned char __a, __vector unsigned char __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
@@ -2976,23 +2978,23 @@ vec_all_ne(__vector unsigned char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a, __b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 3;
}
@@ -3000,7 +3002,8 @@ vec_all_ne(__vector signed short __a, __vector signed short __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 3;
}
@@ -3008,15 +3011,15 @@ vec_all_ne(__vector signed short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, __b, &__cc);
return __cc == 3;
}
@@ -3024,8 +3027,7 @@ vec_all_ne(__vector unsigned short __a, __vector unsigned short __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, (__vector unsigned short)__b, &__cc);
return __cc == 3;
}
@@ -3033,23 +3035,23 @@ vec_all_ne(__vector unsigned short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a, __b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 3;
}
@@ -3057,7 +3059,8 @@ vec_all_ne(__vector signed int __a, __vector signed int __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 3;
}
@@ -3065,15 +3068,15 @@ vec_all_ne(__vector signed int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, __b, &__cc);
return __cc == 3;
}
@@ -3081,8 +3084,7 @@ vec_all_ne(__vector unsigned int __a, __vector unsigned int __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, (__vector unsigned int)__b, &__cc);
return __cc == 3;
}
@@ -3090,23 +3092,23 @@ vec_all_ne(__vector unsigned int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a, __b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 3;
}
@@ -3114,7 +3116,8 @@ vec_all_ne(__vector signed long long __a, __vector signed long long __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector signed long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 3;
}
@@ -3122,15 +3125,15 @@ vec_all_ne(__vector signed long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, __b, &__cc);
return __cc == 3;
}
@@ -3138,8 +3141,7 @@ vec_all_ne(__vector unsigned long long __a, __vector unsigned long long __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector unsigned long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, (__vector unsigned long long)__b, &__cc);
return __cc == 3;
}
@@ -3147,16 +3149,15 @@ vec_all_ne(__vector unsigned long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a, __b, &__cc);
return __cc == 3;
}
static inline __ATTRS_o_ai int
vec_all_ne(__vector __bool long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc == 3;
}
@@ -4241,7 +4242,8 @@ vec_all_numeric(__vector double __a) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc <= 1;
}
@@ -4249,7 +4251,8 @@ vec_any_eq(__vector signed char __a, __vector signed char __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc <= 1;
}
@@ -4257,15 +4260,15 @@ vec_any_eq(__vector signed char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, __b, &__cc);
return __cc <= 1;
}
@@ -4273,8 +4276,7 @@ vec_any_eq(__vector unsigned char __a, __vector unsigned char __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, (__vector unsigned char)__b, &__cc);
return __cc <= 1;
}
@@ -4282,23 +4284,23 @@ vec_any_eq(__vector unsigned char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a, __b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc <= 1;
}
@@ -4306,7 +4308,8 @@ vec_any_eq(__vector signed short __a, __vector signed short __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc <= 1;
}
@@ -4314,15 +4317,15 @@ vec_any_eq(__vector signed short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, __b, &__cc);
return __cc <= 1;
}
@@ -4330,8 +4333,7 @@ vec_any_eq(__vector unsigned short __a, __vector unsigned short __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, (__vector unsigned short)__b, &__cc);
return __cc <= 1;
}
@@ -4339,23 +4341,23 @@ vec_any_eq(__vector unsigned short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a, __b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc <= 1;
}
@@ -4363,7 +4365,8 @@ vec_any_eq(__vector signed int __a, __vector signed int __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc <= 1;
}
@@ -4371,15 +4374,15 @@ vec_any_eq(__vector signed int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, __b, &__cc);
return __cc <= 1;
}
@@ -4387,8 +4390,7 @@ vec_any_eq(__vector unsigned int __a, __vector unsigned int __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, (__vector unsigned int)__b, &__cc);
return __cc <= 1;
}
@@ -4396,23 +4398,23 @@ vec_any_eq(__vector unsigned int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a, __b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc <= 1;
}
@@ -4420,7 +4422,8 @@ vec_any_eq(__vector signed long long __a, __vector signed long long __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector signed long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc <= 1;
}
@@ -4428,15 +4431,15 @@ vec_any_eq(__vector signed long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, __b, &__cc);
return __cc <= 1;
}
@@ -4444,8 +4447,7 @@ vec_any_eq(__vector unsigned long long __a, __vector unsigned long long __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector unsigned long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, (__vector unsigned long long)__b, &__cc);
return __cc <= 1;
}
@@ -4453,16 +4455,15 @@ vec_any_eq(__vector unsigned long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a, __b, &__cc);
return __cc <= 1;
}
static inline __ATTRS_o_ai int
vec_any_eq(__vector __bool long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc <= 1;
}
@@ -4487,7 +4488,8 @@ vec_any_eq(__vector double __a, __vector double __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc != 0;
}
@@ -4495,7 +4497,8 @@ vec_any_ne(__vector signed char __a, __vector signed char __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs(__a, (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc != 0;
}
@@ -4503,15 +4506,15 @@ vec_any_ne(__vector signed char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool char __a, __vector signed char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a, __b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, __b, &__cc);
return __cc != 0;
}
@@ -4519,8 +4522,7 @@ vec_any_ne(__vector unsigned char __a, __vector unsigned char __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs(__a, (__vector unsigned char)__b, &__cc);
return __cc != 0;
}
@@ -4528,23 +4530,23 @@ vec_any_ne(__vector unsigned char __a, __vector __bool char __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool char __a, __vector unsigned char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a, __b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool char __a, __vector __bool char __b) {
int __cc;
- __builtin_s390_vceqbs((__vector signed char)__a,
- (__vector signed char)__b, &__cc);
+ __builtin_s390_vceqbs((__vector unsigned char)__a,
+ (__vector unsigned char)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc != 0;
}
@@ -4552,7 +4554,8 @@ vec_any_ne(__vector signed short __a, __vector signed short __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs(__a, (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc != 0;
}
@@ -4560,15 +4563,15 @@ vec_any_ne(__vector signed short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool short __a, __vector signed short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a, __b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, __b, &__cc);
return __cc != 0;
}
@@ -4576,8 +4579,7 @@ vec_any_ne(__vector unsigned short __a, __vector unsigned short __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs(__a, (__vector unsigned short)__b, &__cc);
return __cc != 0;
}
@@ -4585,23 +4587,23 @@ vec_any_ne(__vector unsigned short __a, __vector __bool short __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool short __a, __vector unsigned short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a, __b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool short __a, __vector __bool short __b) {
int __cc;
- __builtin_s390_vceqhs((__vector signed short)__a,
- (__vector signed short)__b, &__cc);
+ __builtin_s390_vceqhs((__vector unsigned short)__a,
+ (__vector unsigned short)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc != 0;
}
@@ -4609,7 +4611,8 @@ vec_any_ne(__vector signed int __a, __vector signed int __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs(__a, (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc != 0;
}
@@ -4617,15 +4620,15 @@ vec_any_ne(__vector signed int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool int __a, __vector signed int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a, __b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, __b, &__cc);
return __cc != 0;
}
@@ -4633,8 +4636,7 @@ vec_any_ne(__vector unsigned int __a, __vector unsigned int __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs(__a, (__vector unsigned int)__b, &__cc);
return __cc != 0;
}
@@ -4642,23 +4644,23 @@ vec_any_ne(__vector unsigned int __a, __vector __bool int __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool int __a, __vector unsigned int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a, __b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool int __a, __vector __bool int __b) {
int __cc;
- __builtin_s390_vceqfs((__vector signed int)__a,
- (__vector signed int)__b, &__cc);
+ __builtin_s390_vceqfs((__vector unsigned int)__a,
+ (__vector unsigned int)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc != 0;
}
@@ -4666,7 +4668,8 @@ vec_any_ne(__vector signed long long __a, __vector signed long long __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector signed long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs(__a, (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc != 0;
}
@@ -4674,15 +4677,15 @@ vec_any_ne(__vector signed long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool long long __a, __vector signed long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a, __b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, __b, &__cc);
return __cc != 0;
}
@@ -4690,8 +4693,7 @@ vec_any_ne(__vector unsigned long long __a, __vector unsigned long long __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector unsigned long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs(__a, (__vector unsigned long long)__b, &__cc);
return __cc != 0;
}
@@ -4699,16 +4701,15 @@ vec_any_ne(__vector unsigned long long __a, __vector __bool long long __b) {
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool long long __a, __vector unsigned long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a, __b, &__cc);
return __cc != 0;
}
static inline __ATTRS_o_ai int
vec_any_ne(__vector __bool long long __a, __vector __bool long long __b) {
int __cc;
- __builtin_s390_vceqgs((__vector signed long long)__a,
- (__vector signed long long)__b, &__cc);
+ __builtin_s390_vceqgs((__vector unsigned long long)__a,
+ (__vector unsigned long long)__b, &__cc);
return __cc != 0;
}
diff --git a/clang/test/CodeGen/SystemZ/builtins-systemz-vector.c b/clang/test/CodeGen/SystemZ/builtins-systemz-vector.c
index d17daaf35ca4b..877032a52a0ae 100644
--- a/clang/test/CodeGen/SystemZ/builtins-systemz-vector.c
+++ b/clang/test/CodeGen/SystemZ/builtins-systemz-vector.c
@@ -362,13 +362,13 @@ void test_integer(void) {
len = __builtin_s390_vtm(vuc, vuc);
// CHECK: call i32 @llvm.s390.vtm(<16 x i8> %{{.*}}, <16 x i8> %{{.*}})
- vsc = __builtin_s390_vceqbs(vsc, vsc, &cc);
+ vsc = __builtin_s390_vceqbs(vuc, vuc, &cc);
// CHECK: call { <16 x i8>, i32 } @llvm.s390.vceqbs(<16 x i8> %{{.*}}, <16 x i8> %{{.*}})
- vss = __builtin_s390_vceqhs(vss, vss, &cc);
+ vss = __builtin_s390_vceqhs(vus, vus, &cc);
// CHECK: call { <8 x i16>, i32 } @llvm.s390.vceqhs(<8 x i16> %{{.*}}, <8 x i16> %{{.*}})
- vsi = __builtin_s390_vceqfs(vsi, vsi, &cc);
+ vsi = __builtin_s390_vceqfs(vui, vui, &cc);
// CHECK: call { <4 x i32>, i32 } @llvm.s390.vceqfs(<4 x i32> %{{.*}}, <4 x i32> %{{.*}})
- vsl = __builtin_s390_vceqgs(vsl, vsl, &cc);
+ vsl = __builtin_s390_vceqgs(vul, vul, &cc);
// CHECK: call { <2 x i64>, i32 } @llvm.s390.vceqgs(<2 x i64> %{{.*}}, <2 x i64> %{{.*}})
vsc = __builtin_s390_vchbs(vsc, vsc, &cc);
More information about the cfe-commits
mailing list