diff options
-rw-r--r-- | clang/include/clang/Sema/Sema.h | 4 | ||||
-rw-r--r-- | clang/lib/CodeGen/CGExprScalar.cpp | 4 | ||||
-rw-r--r-- | clang/lib/Sema/SemaExpr.cpp | 72 | ||||
-rw-r--r-- | clang/test/CodeGen/aarch64-sve-vector-compare-ops.c | 734 | ||||
-rw-r--r-- | clang/test/Sema/aarch64-sve-vector-compare-ops.c | 761 | ||||
-rw-r--r-- | clang/test/Sema/sizeless-1.c | 6 | ||||
-rw-r--r-- | clang/test/SemaCXX/sizeless-1.cpp | 6 |
7 files changed, 1567 insertions, 20 deletions
diff --git a/clang/include/clang/Sema/Sema.h b/clang/include/clang/Sema/Sema.h index c0ad55d52bb3..5ec03391e287 100644 --- a/clang/include/clang/Sema/Sema.h +++ b/clang/include/clang/Sema/Sema.h @@ -11976,9 +11976,13 @@ public: bool AllowBothBool, bool AllowBoolConversion, bool AllowBoolOperation, bool ReportInvalid); QualType GetSignedVectorType(QualType V); + QualType GetSignedSizelessVectorType(QualType V); QualType CheckVectorCompareOperands(ExprResult &LHS, ExprResult &RHS, SourceLocation Loc, BinaryOperatorKind Opc); + QualType CheckSizelessVectorCompareOperands(ExprResult &LHS, ExprResult &RHS, + SourceLocation Loc, + BinaryOperatorKind Opc); QualType CheckVectorLogicalOperands(ExprResult &LHS, ExprResult &RHS, SourceLocation Loc); diff --git a/clang/lib/CodeGen/CGExprScalar.cpp b/clang/lib/CodeGen/CGExprScalar.cpp index ec9da20f0fbf..0711c993088b 100644 --- a/clang/lib/CodeGen/CGExprScalar.cpp +++ b/clang/lib/CodeGen/CGExprScalar.cpp @@ -1390,8 +1390,8 @@ Value *ScalarExprEmitter::EmitScalarConversion(Value *Src, QualType SrcType, if (isa<llvm::VectorType>(SrcTy) || isa<llvm::VectorType>(DstTy)) { // Allow bitcast from vector to integer/fp of the same size. - unsigned SrcSize = SrcTy->getPrimitiveSizeInBits(); - unsigned DstSize = DstTy->getPrimitiveSizeInBits(); + llvm::TypeSize SrcSize = SrcTy->getPrimitiveSizeInBits(); + llvm::TypeSize DstSize = DstTy->getPrimitiveSizeInBits(); if (SrcSize == DstSize) return Builder.CreateBitCast(Src, DstTy, "conv"); diff --git a/clang/lib/Sema/SemaExpr.cpp b/clang/lib/Sema/SemaExpr.cpp index c0a1ffcdb1b4..375bd2ec59c2 100644 --- a/clang/lib/Sema/SemaExpr.cpp +++ b/clang/lib/Sema/SemaExpr.cpp @@ -50,8 +50,10 @@ #include "clang/Sema/Template.h" #include "llvm/ADT/STLExtras.h" #include "llvm/ADT/StringExtras.h" +#include "llvm/Support/Casting.h" #include "llvm/Support/ConvertUTF.h" #include "llvm/Support/SaveAndRestore.h" +#include "llvm/Support/TypeSize.h" using namespace clang; using namespace sema; @@ -12153,6 +12155,10 @@ QualType Sema::CheckCompareOperands(ExprResult &LHS, ExprResult &RHS, RHS.get()->getType()->isVectorType()) return CheckVectorCompareOperands(LHS, RHS, Loc, Opc); + if (LHS.get()->getType()->isVLSTBuiltinType() || + RHS.get()->getType()->isVLSTBuiltinType()) + return CheckSizelessVectorCompareOperands(LHS, RHS, Loc, Opc); + diagnoseLogicalNotOnLHSofCheck(*this, LHS, RHS, Loc, Opc); diagnoseTautologicalComparison(*this, Loc, LHS.get(), RHS.get(), Opc); @@ -12614,6 +12620,18 @@ QualType Sema::GetSignedVectorType(QualType V) { VectorType::GenericVector); } +QualType Sema::GetSignedSizelessVectorType(QualType V) { + const BuiltinType *VTy = V->castAs<BuiltinType>(); + assert(VTy->isSizelessBuiltinType() && "expected sizeless type"); + + const QualType ETy = V->getSveEltType(Context); + const auto TypeSize = Context.getTypeSize(ETy); + + const QualType IntTy = Context.getIntTypeForBitwidth(TypeSize, true); + const llvm::ElementCount VecSize = Context.getBuiltinVectorTypeInfo(VTy).EC; + return Context.getScalableVectorType(IntTy, VecSize.getKnownMinValue()); +} + /// CheckVectorCompareOperands - vector comparisons are a clang extension that /// operates on extended vector types. Instead of producing an IntTy result, /// like a scalar comparison, a vector comparison produces a vector of integer @@ -12680,6 +12698,48 @@ QualType Sema::CheckVectorCompareOperands(ExprResult &LHS, ExprResult &RHS, return GetSignedVectorType(vType); } +QualType Sema::CheckSizelessVectorCompareOperands(ExprResult &LHS, + ExprResult &RHS, + SourceLocation Loc, + BinaryOperatorKind Opc) { + if (Opc == BO_Cmp) { + Diag(Loc, diag::err_three_way_vector_comparison); + return QualType(); + } + + // Check to make sure we're operating on vectors of the same type and width, + // Allowing one side to be a scalar of element type. + QualType vType = CheckSizelessVectorOperands( + LHS, RHS, Loc, /*isCompAssign*/ false, ACK_Comparison); + + if (vType.isNull()) + return vType; + + QualType LHSType = LHS.get()->getType(); + + // For non-floating point types, check for self-comparisons of the form + // x == x, x != x, x < x, etc. These always evaluate to a constant, and + // often indicate logic errors in the program. + diagnoseTautologicalComparison(*this, Loc, LHS.get(), RHS.get(), Opc); + + // Check for comparisons of floating point operands using != and ==. + if (BinaryOperator::isEqualityOp(Opc) && + LHSType->hasFloatingRepresentation()) { + assert(RHS.get()->getType()->hasFloatingRepresentation()); + CheckFloatComparison(Loc, LHS.get(), RHS.get(), Opc); + } + + const BuiltinType *LHSBuiltinTy = LHSType->getAs<BuiltinType>(); + const BuiltinType *RHSBuiltinTy = RHS.get()->getType()->getAs<BuiltinType>(); + + if (LHSBuiltinTy && RHSBuiltinTy && LHSBuiltinTy->isSVEBool() && + RHSBuiltinTy->isSVEBool()) + return LHSType; + + // Return a signed type for the vector. + return GetSignedSizelessVectorType(vType); +} + static void diagnoseXorMisusedAsPow(Sema &S, const ExprResult &XorLHS, const ExprResult &XorRHS, const SourceLocation Loc) { @@ -12986,7 +13046,8 @@ inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS, SourceLocation Loc, BinaryOperatorKind Opc) { // Check vector operands differently. - if (LHS.get()->getType()->isVectorType() || RHS.get()->getType()->isVectorType()) + if (LHS.get()->getType()->isVectorType() || + RHS.get()->getType()->isVectorType()) return CheckVectorLogicalOperands(LHS, RHS, Loc); bool EnumConstantInBoolContext = false; @@ -13020,14 +13081,13 @@ inline QualType Sema::CheckLogicalOperands(ExprResult &LHS, ExprResult &RHS, !RHS.get()->getExprLoc().isMacroID()) || (Result != 0 && Result != 1)) { Diag(Loc, diag::warn_logical_instead_of_bitwise) - << RHS.get()->getSourceRange() - << (Opc == BO_LAnd ? "&&" : "||"); + << RHS.get()->getSourceRange() << (Opc == BO_LAnd ? "&&" : "||"); // Suggest replacing the logical operator with the bitwise version Diag(Loc, diag::note_logical_instead_of_bitwise_change_operator) << (Opc == BO_LAnd ? "&" : "|") - << FixItHint::CreateReplacement(SourceRange( - Loc, getLocForEndOfToken(Loc)), - Opc == BO_LAnd ? "&" : "|"); + << FixItHint::CreateReplacement( + SourceRange(Loc, getLocForEndOfToken(Loc)), + Opc == BO_LAnd ? "&" : "|"); if (Opc == BO_LAnd) // Suggest replacing "Foo() && kNonZero" with "Foo()" Diag(Loc, diag::note_logical_instead_of_bitwise_remove_constant) diff --git a/clang/test/CodeGen/aarch64-sve-vector-compare-ops.c b/clang/test/CodeGen/aarch64-sve-vector-compare-ops.c new file mode 100644 index 000000000000..e2e8bb851652 --- /dev/null +++ b/clang/test/CodeGen/aarch64-sve-vector-compare-ops.c @@ -0,0 +1,734 @@ +// NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py +// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve \ +// RUN: -fallow-half-arguments-and-returns -disable-O0-optnone \ +// RUN: -emit-llvm -o - %s | opt -S -sroa | FileCheck %s + +// REQUIRES: aarch64-registered-target + +#include <arm_sve.h> + +// EQ + +// CHECK-LABEL: @eq_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t eq_bool(svbool_t a, svbool_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t eq_i8(svint8_t a, svint8_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t eq_i16(svint16_t a, svint16_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t eq_i32(svint32_t a, svint32_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t eq_i64(svint64_t a, svint64_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t eq_u8(svuint8_t a, svuint8_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t eq_u16(svuint16_t a, svuint16_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t eq_u32(svuint32_t a, svuint32_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp eq <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t eq_u64(svuint64_t a, svuint64_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oeq <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t eq_f16(svfloat16_t a, svfloat16_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oeq <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t eq_f32(svfloat32_t a, svfloat32_t b) { + return a == b; +} + +// CHECK-LABEL: @eq_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oeq <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t eq_f64(svfloat64_t a, svfloat64_t b) { + return a == b; +} + +// NEQ + +// CHECK-LABEL: @neq_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t neq_bool(svbool_t a, svbool_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t neq_i8(svint8_t a, svint8_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t neq_i16(svint16_t a, svint16_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t neq_i32(svint32_t a, svint32_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t neq_i64(svint64_t a, svint64_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t neq_u8(svuint8_t a, svuint8_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t neq_u16(svuint16_t a, svuint16_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t neq_u32(svuint32_t a, svuint32_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ne <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t neq_u64(svuint64_t a, svuint64_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp une <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t neq_f16(svfloat16_t a, svfloat16_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp une <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t neq_f32(svfloat32_t a, svfloat32_t b) { + return a != b; +} + +// CHECK-LABEL: @neq_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp une <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t neq_f64(svfloat64_t a, svfloat64_t b) { + return a != b; +} + +// LT + +// CHECK-LABEL: @lt_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t lt_bool(svbool_t a, svbool_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t lt_i8(svint8_t a, svint8_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t lt_i16(svint16_t a, svint16_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t lt_i32(svint32_t a, svint32_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t lt_i64(svint64_t a, svint64_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t lt_u8(svuint8_t a, svuint8_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t lt_u16(svuint16_t a, svuint16_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t lt_u32(svuint32_t a, svuint32_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ult <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t lt_u64(svuint64_t a, svuint64_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp olt <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t lt_f16(svfloat16_t a, svfloat16_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp olt <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t lt_f32(svfloat32_t a, svfloat32_t b) { + return a < b; +} + +// CHECK-LABEL: @lt_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp olt <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t lt_f64(svfloat64_t a, svfloat64_t b) { + return a < b; +} + +// LEQ + +// CHECK-LABEL: @leq_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t leq_bool(svbool_t a, svbool_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t leq_i8(svint8_t a, svint8_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t leq_i16(svint16_t a, svint16_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t leq_i32(svint32_t a, svint32_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t leq_i64(svint64_t a, svint64_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t leq_u8(svuint8_t a, svuint8_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t leq_u16(svuint16_t a, svuint16_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t leq_u32(svuint32_t a, svuint32_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ule <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t leq_u64(svuint64_t a, svuint64_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ole <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t leq_f16(svfloat16_t a, svfloat16_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ole <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t leq_f32(svfloat32_t a, svfloat32_t b) { + return a <= b; +} + +// CHECK-LABEL: @leq_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ole <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t leq_f64(svfloat64_t a, svfloat64_t b) { + return a <= b; +} + +// GT + +// CHECK-LABEL: @gt_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t gt_bool(svbool_t a, svbool_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t gt_i8(svint8_t a, svint8_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t gt_i16(svint16_t a, svint16_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t gt_i32(svint32_t a, svint32_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t gt_i64(svint64_t a, svint64_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t gt_u8(svuint8_t a, svuint8_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t gt_u16(svuint16_t a, svuint16_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t gt_u32(svuint32_t a, svuint32_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp ugt <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t gt_u64(svuint64_t a, svuint64_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ogt <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t gt_f16(svfloat16_t a, svfloat16_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ogt <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t gt_f32(svfloat32_t a, svfloat32_t b) { + return a > b; +} + +// CHECK-LABEL: @gt_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp ogt <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t gt_f64(svfloat64_t a, svfloat64_t b) { + return a > b; +} + +// GEQ + +// CHECK-LABEL: @geq_bool( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 16 x i1> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: ret <vscale x 16 x i1> [[CMP]] +// +svbool_t geq_bool(svbool_t a, svbool_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_i8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t geq_i8(svint8_t a, svint8_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_i16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t geq_i16(svint16_t a, svint16_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_i32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t geq_i32(svint32_t a, svint32_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_i64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t geq_i64(svint64_t a, svint64_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_u8( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 16 x i8> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 16 x i1> [[CMP]] to <vscale x 16 x i8> +// CHECK-NEXT: ret <vscale x 16 x i8> [[CONV]] +// +svint8_t geq_u8(svuint8_t a, svuint8_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_u16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 8 x i16> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t geq_u16(svuint16_t a, svuint16_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_u32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 4 x i32> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t geq_u32(svuint32_t a, svuint32_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_u64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = icmp uge <vscale x 2 x i64> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t geq_u64(svuint64_t a, svuint64_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_f16( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oge <vscale x 8 x half> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 8 x i1> [[CMP]] to <vscale x 8 x i16> +// CHECK-NEXT: ret <vscale x 8 x i16> [[CONV]] +// +svint16_t geq_f16(svfloat16_t a, svfloat16_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_f32( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oge <vscale x 4 x float> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 4 x i1> [[CMP]] to <vscale x 4 x i32> +// CHECK-NEXT: ret <vscale x 4 x i32> [[CONV]] +// +svint32_t geq_f32(svfloat32_t a, svfloat32_t b) { + return a >= b; +} + +// CHECK-LABEL: @geq_f64( +// CHECK-NEXT: entry: +// CHECK-NEXT: [[CMP:%.*]] = fcmp oge <vscale x 2 x double> [[A:%.*]], [[B:%.*]] +// CHECK-NEXT: [[CONV:%.*]] = zext <vscale x 2 x i1> [[CMP]] to <vscale x 2 x i64> +// CHECK-NEXT: ret <vscale x 2 x i64> [[CONV]] +// +svint64_t geq_f64(svfloat64_t a, svfloat64_t b) { + return a >= b; +} diff --git a/clang/test/Sema/aarch64-sve-vector-compare-ops.c b/clang/test/Sema/aarch64-sve-vector-compare-ops.c new file mode 100644 index 000000000000..6ff91f4c0e33 --- /dev/null +++ b/clang/test/Sema/aarch64-sve-vector-compare-ops.c @@ -0,0 +1,761 @@ +// RUN: %clang_cc1 -verify -triple aarch64-none-linux-gnu -target-feature +sve -fallow-half-arguments-and-returns -fsyntax-only %s + +// REQUIRES: aarch64-registered-target + +#include <arm_sve.h> + +void eq(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 == b); // expected-error{{invalid operands to binary expression}} + (void)(i8 == i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 == i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 == i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 == u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 == u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 == u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 == f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 == f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 == b); // expected-error{{invalid operands to binary expression}} + (void)(u8 == i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 == i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 == i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 == u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 == u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 == u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 == f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 == f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 == b); // expected-error{{invalid operands to binary expression}} + (void)(i16 == i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 == i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 == i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 == u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 == u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 == u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 == f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 == f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 == b); // expected-error{{invalid operands to binary expression}} + (void)(u16 == i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 == i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 == i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 == u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 == u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 == u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 == f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 == f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 == b); // expected-error{{invalid operands to binary expression}} + (void)(i32 == i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 == i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 == i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 == u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 == u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 == u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 == f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 == f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 == b); // expected-error{{invalid operands to binary expression}} + (void)(u32 == i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 == i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 == i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 == u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 == u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 == u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 == f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 == f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 == b); // expected-error{{invalid operands to binary expression}} + (void)(i64 == i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 == i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 == i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 == u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 == u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 == u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 == f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 == f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 == b); // expected-error{{invalid operands to binary expression}} + (void)(u64 == i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 == i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 == i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 == u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 == u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 == u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 == f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 == f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 == b); // expected-error{{invalid operands to binary expression}} + (void)(f16 == i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 == i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 == i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 == i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 == u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 == u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 == u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 == f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 == b); // expected-error{{invalid operands to binary expression}} + (void)(f32 == i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 == i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 == i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 == i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 == u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 == u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 == u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 == f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 == f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 == b); // expected-error{{invalid operands to binary expression}} + (void)(f64 == i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 == i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 == i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 == i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 == u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 == u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 == u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 == f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 == f32); // expected-error{{invalid operands to binary expression}} +} + +void neq(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 != b); // expected-error{{invalid operands to binary expression}} + (void)(i8 != i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 != i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 != i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 != u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 != u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 != u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 != f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 != f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 != b); // expected-error{{invalid operands to binary expression}} + (void)(u8 != i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 != i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 != i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 != u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 != u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 != u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 != f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 != f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 != b); // expected-error{{invalid operands to binary expression}} + (void)(i16 != i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 != i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 != i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 != u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 != u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 != u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 != f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 != f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 != b); // expected-error{{invalid operands to binary expression}} + (void)(u16 != i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 != i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 != i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 != u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 != u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 != u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 != f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 != f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 != b); // expected-error{{invalid operands to binary expression}} + (void)(i32 != i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 != i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 != i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 != u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 != u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 != u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 != f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 != f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 != b); // expected-error{{invalid operands to binary expression}} + (void)(u32 != i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 != i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 != i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 != u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 != u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 != u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 != f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 != f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 != b); // expected-error{{invalid operands to binary expression}} + (void)(i64 != i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 != i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 != i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 != u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 != u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 != u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 != f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 != f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 != b); // expected-error{{invalid operands to binary expression}} + (void)(u64 != i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 != i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 != i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 != u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 != u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 != u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 != f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 != f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 != b); // expected-error{{invalid operands to binary expression}} + (void)(f16 != i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 != i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 != i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 != i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 != u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 != u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 != u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 != f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 != b); // expected-error{{invalid operands to binary expression}} + (void)(f32 != i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 != i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 != i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 != i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 != u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 != u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 != u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 != f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 != f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 != b); // expected-error{{invalid operands to binary expression}} + (void)(f64 != i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 != i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 != i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 != i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 != u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 != u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 != u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 != f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 != f32); // expected-error{{invalid operands to binary expression}} +} + +void lt(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 < b); // expected-error{{invalid operands to binary expression}} + (void)(i8 < i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 < i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 < i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 < u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 < u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 < u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 < f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 < f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 < b); // expected-error{{invalid operands to binary expression}} + (void)(u8 < i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 < i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 < i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 < u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 < u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 < u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 < f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 < f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 < b); // expected-error{{invalid operands to binary expression}} + (void)(i16 < i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 < i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 < i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 < u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 < u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 < u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 < f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 < f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 < b); // expected-error{{invalid operands to binary expression}} + (void)(u16 < i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 < i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 < i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 < u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 < u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 < u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 < f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 < f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 < b); // expected-error{{invalid operands to binary expression}} + (void)(i32 < i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 < i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 < i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 < u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 < u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 < u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 < f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 < f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 < b); // expected-error{{invalid operands to binary expression}} + (void)(u32 < i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 < i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 < i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 < u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 < u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 < u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 < f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 < f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 < b); // expected-error{{invalid operands to binary expression}} + (void)(i64 < i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 < i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 < i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 < u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 < u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 < u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 < f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 < f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 < b); // expected-error{{invalid operands to binary expression}} + (void)(u64 < i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 < i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 < i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 < u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 < u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 < u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 < f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 < f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 < b); // expected-error{{invalid operands to binary expression}} + (void)(f16 < i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 < i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 < i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 < i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 < u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 < u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 < u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 < f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 < b); // expected-error{{invalid operands to binary expression}} + (void)(f32 < i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 < i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 < i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 < i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 < u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 < u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 < u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 < f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 < f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 < b); // expected-error{{invalid operands to binary expression}} + (void)(f64 < i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 < i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 < i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 < i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 < u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 < u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 < u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 < f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 < f32); // expected-error{{invalid operands to binary expression}} +} + +void leq(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 <= b); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 <= b); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 <= b); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 <= b); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 <= b); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 <= b); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 <= b); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 <= b); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 <= b); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 <= b); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 <= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 <= b); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 <= f32); // expected-error{{invalid operands to binary expression}} +} + +void gt(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 > b); // expected-error{{invalid operands to binary expression}} + (void)(i8 > i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 > i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 > i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 > u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 > u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 > u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 > f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 > f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 > b); // expected-error{{invalid operands to binary expression}} + (void)(u8 > i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 > i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 > i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 > u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 > u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 > u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 > f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 > f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 > b); // expected-error{{invalid operands to binary expression}} + (void)(i16 > i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 > i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 > i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 > u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 > u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 > u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 > f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 > f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 > b); // expected-error{{invalid operands to binary expression}} + (void)(u16 > i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 > i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 > i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 > u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 > u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 > u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 > f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 > f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 > b); // expected-error{{invalid operands to binary expression}} + (void)(i32 > i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 > i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 > i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 > u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 > u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 > u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 > f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 > f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 > b); // expected-error{{invalid operands to binary expression}} + (void)(u32 > i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 > i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 > i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 > u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 > u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 > u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 > f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 > f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 > b); // expected-error{{invalid operands to binary expression}} + (void)(i64 > i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 > i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 > i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 > u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 > u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 > u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 > f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 > f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 > b); // expected-error{{invalid operands to binary expression}} + (void)(u64 > i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 > i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 > i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 > u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 > u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 > u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 > f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 > f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 > b); // expected-error{{invalid operands to binary expression}} + (void)(f16 > i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 > i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 > i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 > i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 > u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 > u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 > u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 > f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 > b); // expected-error{{invalid operands to binary expression}} + (void)(f32 > i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 > i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 > i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 > i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 > u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 > u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 > u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 > f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 > f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 > b); // expected-error{{invalid operands to binary expression}} + (void)(f64 > i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 > i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 > i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 > i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 > u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 > u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 > u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 > f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 > f32); // expected-error{{invalid operands to binary expression}} +} + +void geq(svint8_t i8, svint16_t i16, svint32_t i32, svint64_t i64, + svuint8_t u8, svuint16_t u16, svuint32_t u32, svuint64_t u64, + svfloat16_t f16, svfloat32_t f32, svfloat64_t f64, + svbool_t b) { + (void)(i8 >= b); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(i8 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u8 >= b); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(u8 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i16 >= b); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(i16 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u16 >= b); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(u16 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i32 >= b); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(i32 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u32 >= b); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(u32 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(i64 >= b); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(i64 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(u64 >= b); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(u64 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f16 >= b); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= f32); // expected-error{{invalid operands to binary expression}} + (void)(f16 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f32 >= b); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= u64); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(f32 >= f64); // expected-error{{invalid operands to binary expression}} + + (void)(f64 >= b); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= i8); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= i16); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= i32); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= i64); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= u8); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= u16); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= u32); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= f16); // expected-error{{invalid operands to binary expression}} + (void)(f64 >= f32); // expected-error{{invalid operands to binary expression}} +} diff --git a/clang/test/Sema/sizeless-1.c b/clang/test/Sema/sizeless-1.c index 1bf344e2bf0b..b77ee479f104 100644 --- a/clang/test/Sema/sizeless-1.c +++ b/clang/test/Sema/sizeless-1.c @@ -200,12 +200,6 @@ void func(int sel) { local_int8 << init_int8; // expected-error {{invalid operands to binary expression}} local_int8 >> init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 < init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 <= init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 == init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 != init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 >= init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 > init_int8; // expected-error {{invalid operands to binary expression}} local_int8 &&init_int8; // expected-error {{invalid operands to binary expression}} local_int8 || init_int8; // expected-error {{invalid operands to binary expression}} diff --git a/clang/test/SemaCXX/sizeless-1.cpp b/clang/test/SemaCXX/sizeless-1.cpp index d7684c08641d..fa29e1582cd3 100644 --- a/clang/test/SemaCXX/sizeless-1.cpp +++ b/clang/test/SemaCXX/sizeless-1.cpp @@ -212,12 +212,6 @@ void func(int sel) { local_int8 << init_int8; // expected-error {{invalid operands to binary expression}} local_int8 >> init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 < init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 <= init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 == init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 != init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 >= init_int8; // expected-error {{invalid operands to binary expression}} - local_int8 > init_int8; // expected-error {{invalid operands to binary expression}} local_int8 &&init_int8; // expected-error {{invalid operands to binary expression}} expected-error {{not contextually convertible}} local_int8 || init_int8; // expected-error {{invalid operands to binary expression}} expected-error {{not contextually convertible}} |