Index: lib/Transforms/InstCombine/InstCombineAndOrXor.cpp =================================================================== --- lib/Transforms/InstCombine/InstCombineAndOrXor.cpp +++ lib/Transforms/InstCombine/InstCombineAndOrXor.cpp @@ -39,30 +39,45 @@ } /// Similar to getICmpCode but for FCmpInst. This encodes a fcmp predicate into -/// a three bit mask. It also returns whether it is an ordered predicate by -/// reference. -static unsigned getFCmpCode(FCmpInst::Predicate CC, bool &isOrdered) { - isOrdered = false; - switch (CC) { - case FCmpInst::FCMP_ORD: isOrdered = true; return 0; // 000 - case FCmpInst::FCMP_UNO: return 0; // 000 - case FCmpInst::FCMP_OGT: isOrdered = true; return 1; // 001 - case FCmpInst::FCMP_UGT: return 1; // 001 - case FCmpInst::FCMP_OEQ: isOrdered = true; return 2; // 010 - case FCmpInst::FCMP_UEQ: return 2; // 010 - case FCmpInst::FCMP_OGE: isOrdered = true; return 3; // 011 - case FCmpInst::FCMP_UGE: return 3; // 011 - case FCmpInst::FCMP_OLT: isOrdered = true; return 4; // 100 - case FCmpInst::FCMP_ULT: return 4; // 100 - case FCmpInst::FCMP_ONE: isOrdered = true; return 5; // 101 - case FCmpInst::FCMP_UNE: return 5; // 101 - case FCmpInst::FCMP_OLE: isOrdered = true; return 6; // 110 - case FCmpInst::FCMP_ULE: return 6; // 110 - // True -> 7 - default: - // Not expecting FCMP_FALSE and FCMP_TRUE; - llvm_unreachable("Unexpected FCmp predicate!"); - } +/// a four bit mask. +static unsigned getFCmpCode(FCmpInst::Predicate CC) { + assert(FCmpInst::FCMP_FALSE <= CC && CC <= FCmpInst::FCMP_TRUE && + "Unexpected FCmp predicate!"); + // Take the advantage of the bit pattern of FCmpInst::Predicate here. + // U L G E + static_assert(FCmpInst::FCMP_FALSE == 0, // 0 0 0 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_OEQ == 1, // 0 0 0 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_OGT == 2, // 0 0 1 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_OGE == 3, // 0 0 1 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_OLT == 4, // 0 1 0 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_OLE == 5, // 0 1 0 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_ONE == 6, // 0 1 1 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_ORD == 7, // 0 1 1 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_UNO == 8, // 1 0 0 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_UEQ == 9, // 1 0 0 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_UGT == 10, // 1 0 1 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_UGE == 11, // 1 0 1 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_ULT == 12, // 1 1 0 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_ULE == 13, // 1 1 0 1 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_UNE == 14, // 1 1 1 0 + "FCMP_* predicates have unexpected bit patterns"); + static_assert(FCmpInst::FCMP_TRUE == 15, // 1 1 1 1 + "FCMP_* predicates have unexpected bit patterns"); + return CC; } /// This is the complement of getICmpCode, which turns an opcode and two @@ -78,26 +93,16 @@ } /// This is the complement of getFCmpCode, which turns an opcode and two -/// operands into either a FCmp instruction. isordered is passed in to determine -/// which kind of predicate to use in the new fcmp instruction. -static Value *getFCmpValue(bool isordered, unsigned code, - Value *LHS, Value *RHS, +/// operands into either a FCmp instruction. +static Value *getFCmpValue(unsigned Code, Value *LHS, Value *RHS, InstCombiner::BuilderTy *Builder) { - CmpInst::Predicate Pred; - switch (code) { - default: llvm_unreachable("Illegal FCmp code!"); - case 0: Pred = isordered ? FCmpInst::FCMP_ORD : FCmpInst::FCMP_UNO; break; - case 1: Pred = isordered ? FCmpInst::FCMP_OGT : FCmpInst::FCMP_UGT; break; - case 2: Pred = isordered ? FCmpInst::FCMP_OEQ : FCmpInst::FCMP_UEQ; break; - case 3: Pred = isordered ? FCmpInst::FCMP_OGE : FCmpInst::FCMP_UGE; break; - case 4: Pred = isordered ? FCmpInst::FCMP_OLT : FCmpInst::FCMP_ULT; break; - case 5: Pred = isordered ? FCmpInst::FCMP_ONE : FCmpInst::FCMP_UNE; break; - case 6: Pred = isordered ? FCmpInst::FCMP_OLE : FCmpInst::FCMP_ULE; break; - case 7: - if (!isordered) - return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 1); - Pred = FCmpInst::FCMP_ORD; break; - } + const auto Pred = static_cast(Code); + assert(FCmpInst::FCMP_FALSE <= Pred && Pred <= FCmpInst::FCMP_TRUE && + "Unexpected FCmp predicate!"); + if (Pred == FCmpInst::FCMP_FALSE) + return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 0); + if (Pred == FCmpInst::FCMP_TRUE) + return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 1); return Builder->CreateFCmp(Pred, LHS, RHS); } @@ -1107,6 +1112,29 @@ /// Optimize (fcmp)&(fcmp). NOTE: Unlike the rest of instcombine, this returns /// a Value which should already be inserted into the function. Value *InstCombiner::FoldAndOfFCmps(FCmpInst *LHS, FCmpInst *RHS) { + Value *Op0LHS = LHS->getOperand(0), *Op0RHS = LHS->getOperand(1); + Value *Op1LHS = RHS->getOperand(0), *Op1RHS = RHS->getOperand(1); + FCmpInst::Predicate Op0CC = LHS->getPredicate(), Op1CC = RHS->getPredicate(); + + if (Op0LHS == Op1RHS && Op0RHS == Op1LHS) { + // Swap RHS operands to match LHS. + Op1CC = FCmpInst::getSwappedPredicate(Op1CC); + std::swap(Op1LHS, Op1RHS); + } + + // Simplify (fcmp cc0 x, y) & (fcmp cc1 x, y). + // Suppose the relation between x and y is R, where R is one of + // U(1000), L(0100), G(0010) or E(0001), and CC0 and CC1 are the bitmasks for + // testing the desired relations. + // + // Since (R & CC0) and (R & CC1) are either R or 0, we actually have this: + // bool(R & CC0) && bool(R & CC1) + // = bool((R & CC0) & (R & CC1)) + // = bool(R & (CC0 & CC1)) <= by re-association, commutation, and idempotency + if (Op0LHS == Op1LHS && Op0RHS == Op1RHS) + return getFCmpValue(getFCmpCode(Op0CC) & getFCmpCode(Op1CC), Op0LHS, Op0RHS, + Builder); + if (LHS->getPredicate() == FCmpInst::FCMP_ORD && RHS->getPredicate() == FCmpInst::FCMP_ORD) { if (LHS->getOperand(0)->getType() != RHS->getOperand(0)->getType()) @@ -1130,56 +1158,6 @@ return nullptr; } - Value *Op0LHS = LHS->getOperand(0), *Op0RHS = LHS->getOperand(1); - Value *Op1LHS = RHS->getOperand(0), *Op1RHS = RHS->getOperand(1); - FCmpInst::Predicate Op0CC = LHS->getPredicate(), Op1CC = RHS->getPredicate(); - - - if (Op0LHS == Op1RHS && Op0RHS == Op1LHS) { - // Swap RHS operands to match LHS. - Op1CC = FCmpInst::getSwappedPredicate(Op1CC); - std::swap(Op1LHS, Op1RHS); - } - - if (Op0LHS == Op1LHS && Op0RHS == Op1RHS) { - // Simplify (fcmp cc0 x, y) & (fcmp cc1 x, y). - if (Op0CC == Op1CC) - return Builder->CreateFCmp((FCmpInst::Predicate)Op0CC, Op0LHS, Op0RHS); - if (Op0CC == FCmpInst::FCMP_FALSE || Op1CC == FCmpInst::FCMP_FALSE) - return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 0); - if (Op0CC == FCmpInst::FCMP_TRUE) - return RHS; - if (Op1CC == FCmpInst::FCMP_TRUE) - return LHS; - - bool Op0Ordered; - bool Op1Ordered; - unsigned Op0Pred = getFCmpCode(Op0CC, Op0Ordered); - unsigned Op1Pred = getFCmpCode(Op1CC, Op1Ordered); - // uno && ord -> false - if (Op0Pred == 0 && Op1Pred == 0 && Op0Ordered != Op1Ordered) - return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 0); - if (Op1Pred == 0) { - std::swap(LHS, RHS); - std::swap(Op0Pred, Op1Pred); - std::swap(Op0Ordered, Op1Ordered); - } - if (Op0Pred == 0) { - // uno && ueq -> uno && (uno || eq) -> uno - // ord && olt -> ord && (ord && lt) -> olt - if (!Op0Ordered && (Op0Ordered == Op1Ordered)) - return LHS; - if (Op0Ordered && (Op0Ordered == Op1Ordered)) - return RHS; - - // uno && oeq -> uno && (ord && eq) -> false - if (!Op0Ordered) - return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 0); - // ord && ueq -> ord && (uno || eq) -> oeq - return getFCmpValue(true, Op1Pred, Op0LHS, Op0RHS, Builder); - } - } - return nullptr; } @@ -1996,6 +1974,29 @@ /// Optimize (fcmp)|(fcmp). NOTE: Unlike the rest of instcombine, this returns /// a Value which should already be inserted into the function. Value *InstCombiner::FoldOrOfFCmps(FCmpInst *LHS, FCmpInst *RHS) { + Value *Op0LHS = LHS->getOperand(0), *Op0RHS = LHS->getOperand(1); + Value *Op1LHS = RHS->getOperand(0), *Op1RHS = RHS->getOperand(1); + FCmpInst::Predicate Op0CC = LHS->getPredicate(), Op1CC = RHS->getPredicate(); + + if (Op0LHS == Op1RHS && Op0RHS == Op1LHS) { + // Swap RHS operands to match LHS. + Op1CC = FCmpInst::getSwappedPredicate(Op1CC); + std::swap(Op1LHS, Op1RHS); + } + + // Simplify (fcmp cc0 x, y) | (fcmp cc1 x, y). + // Suppose the relation between x and y is R, where R is one of + // U(1000), L(0100), G(0010) or E(0001), and CC0 and CC1 are the bitmasks for + // testing the desired relations. + // + // Since (R & CC0) and (R & CC1) are either R or 0, we actually have this: + // bool(R & CC0) || bool(R & CC1) + // = bool((R & CC0) | (R & CC1)) + // = bool(R & (CC0 | CC1)) <= by reversed distribution (contribution? ;) + if (Op0LHS == Op1LHS && Op0RHS == Op1RHS) + return getFCmpValue(getFCmpCode(Op0CC) | getFCmpCode(Op1CC), Op0LHS, Op0RHS, + Builder); + if (LHS->getPredicate() == FCmpInst::FCMP_UNO && RHS->getPredicate() == FCmpInst::FCMP_UNO && LHS->getOperand(0)->getType() == RHS->getOperand(0)->getType()) { @@ -2020,35 +2021,6 @@ return nullptr; } - Value *Op0LHS = LHS->getOperand(0), *Op0RHS = LHS->getOperand(1); - Value *Op1LHS = RHS->getOperand(0), *Op1RHS = RHS->getOperand(1); - FCmpInst::Predicate Op0CC = LHS->getPredicate(), Op1CC = RHS->getPredicate(); - - if (Op0LHS == Op1RHS && Op0RHS == Op1LHS) { - // Swap RHS operands to match LHS. - Op1CC = FCmpInst::getSwappedPredicate(Op1CC); - std::swap(Op1LHS, Op1RHS); - } - if (Op0LHS == Op1LHS && Op0RHS == Op1RHS) { - // Simplify (fcmp cc0 x, y) | (fcmp cc1 x, y). - if (Op0CC == Op1CC) - return Builder->CreateFCmp((FCmpInst::Predicate)Op0CC, Op0LHS, Op0RHS); - if (Op0CC == FCmpInst::FCMP_TRUE || Op1CC == FCmpInst::FCMP_TRUE) - return ConstantInt::get(CmpInst::makeCmpResultType(LHS->getType()), 1); - if (Op0CC == FCmpInst::FCMP_FALSE) - return RHS; - if (Op1CC == FCmpInst::FCMP_FALSE) - return LHS; - bool Op0Ordered; - bool Op1Ordered; - unsigned Op0Pred = getFCmpCode(Op0CC, Op0Ordered); - unsigned Op1Pred = getFCmpCode(Op1CC, Op1Ordered); - if (Op0Ordered == Op1Ordered) { - // If both are ordered or unordered, return a new fcmp with - // or'ed predicates. - return getFCmpValue(Op0Ordered, Op0Pred|Op1Pred, Op0LHS, Op0RHS, Builder); - } - } return nullptr; } Index: test/Transforms/InstCombine/and-fcmp.ll =================================================================== --- test/Transforms/InstCombine/and-fcmp.ll +++ test/Transforms/InstCombine/and-fcmp.ll @@ -14,8 +14,8 @@ define i1 @t2(float %x, float %y) { ; CHECK-LABEL: @t2( -; CHECK-NEXT: [[A:%.*]] = fcmp olt float %x, %y -; CHECK-NEXT: ret i1 [[A]] +; CHECK-NEXT: [[TMP1:%.*]] = fcmp olt float %x, %y +; CHECK-NEXT: ret i1 [[TMP1]] ; %a = fcmp olt float %x, %y %b = fcmp ord float %x, %y @@ -35,8 +35,8 @@ define i1 @t4(float %x, float %y) { ; CHECK-LABEL: @t4( -; CHECK-NEXT: [[A:%.*]] = fcmp one float %y, %x -; CHECK-NEXT: ret i1 [[A]] +; CHECK-NEXT: [[TMP1:%.*]] = fcmp one float %y, %x +; CHECK-NEXT: ret i1 [[TMP1]] ; %a = fcmp one float %y, %x %b = fcmp ord float %x, %y @@ -66,8 +66,8 @@ define i1 @t7(float %x, float %y) { ; CHECK-LABEL: @t7( -; CHECK-NEXT: [[A:%.*]] = fcmp uno float %x, %y -; CHECK-NEXT: ret i1 [[A]] +; CHECK-NEXT: [[TMP1:%.*]] = fcmp uno float %x, %y +; CHECK-NEXT: ret i1 [[TMP1]] ; %a = fcmp uno float %x, %y %b = fcmp ult float %x, %y @@ -102,3 +102,1728 @@ ret <2 x i1> %and } +define i1 @auto_gen_0(double %a, double %b) { +; CHECK-LABEL: @auto_gen_0( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp false double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_1(double %a, double %b) { +; CHECK-LABEL: @auto_gen_1( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp oeq double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_2(double %a, double %b) { +; CHECK-LABEL: @auto_gen_2( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oeq double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_3(double %a, double %b) { +; CHECK-LABEL: @auto_gen_3( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_4(double %a, double %b) { +; CHECK-LABEL: @auto_gen_4( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_5(double %a, double %b) { +; CHECK-LABEL: @auto_gen_5( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_6(double %a, double %b) { +; CHECK-LABEL: @auto_gen_6( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_7(double %a, double %b) { +; CHECK-LABEL: @auto_gen_7( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_8(double %a, double %b) { +; CHECK-LABEL: @auto_gen_8( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_9(double %a, double %b) { +; CHECK-LABEL: @auto_gen_9( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_10(double %a, double %b) { +; CHECK-LABEL: @auto_gen_10( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_11(double %a, double %b) { +; CHECK-LABEL: @auto_gen_11( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_12(double %a, double %b) { +; CHECK-LABEL: @auto_gen_12( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_13(double %a, double %b) { +; CHECK-LABEL: @auto_gen_13( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_14(double %a, double %b) { +; CHECK-LABEL: @auto_gen_14( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_15(double %a, double %b) { +; CHECK-LABEL: @auto_gen_15( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_16(double %a, double %b) { +; CHECK-LABEL: @auto_gen_16( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_17(double %a, double %b) { +; CHECK-LABEL: @auto_gen_17( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_18(double %a, double %b) { +; CHECK-LABEL: @auto_gen_18( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_19(double %a, double %b) { +; CHECK-LABEL: @auto_gen_19( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_20(double %a, double %b) { +; CHECK-LABEL: @auto_gen_20( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_21(double %a, double %b) { +; CHECK-LABEL: @auto_gen_21( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_22(double %a, double %b) { +; CHECK-LABEL: @auto_gen_22( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_23(double %a, double %b) { +; CHECK-LABEL: @auto_gen_23( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_24(double %a, double %b) { +; CHECK-LABEL: @auto_gen_24( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_25(double %a, double %b) { +; CHECK-LABEL: @auto_gen_25( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_26(double %a, double %b) { +; CHECK-LABEL: @auto_gen_26( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_27(double %a, double %b) { +; CHECK-LABEL: @auto_gen_27( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_28(double %a, double %b) { +; CHECK-LABEL: @auto_gen_28( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_29(double %a, double %b) { +; CHECK-LABEL: @auto_gen_29( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_30(double %a, double %b) { +; CHECK-LABEL: @auto_gen_30( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_31(double %a, double %b) { +; CHECK-LABEL: @auto_gen_31( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_32(double %a, double %b) { +; CHECK-LABEL: @auto_gen_32( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_33(double %a, double %b) { +; CHECK-LABEL: @auto_gen_33( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_34(double %a, double %b) { +; CHECK-LABEL: @auto_gen_34( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_35(double %a, double %b) { +; CHECK-LABEL: @auto_gen_35( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_36(double %a, double %b) { +; CHECK-LABEL: @auto_gen_36( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_37(double %a, double %b) { +; CHECK-LABEL: @auto_gen_37( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_38(double %a, double %b) { +; CHECK-LABEL: @auto_gen_38( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_39(double %a, double %b) { +; CHECK-LABEL: @auto_gen_39( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_40(double %a, double %b) { +; CHECK-LABEL: @auto_gen_40( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_41(double %a, double %b) { +; CHECK-LABEL: @auto_gen_41( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_42(double %a, double %b) { +; CHECK-LABEL: @auto_gen_42( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_43(double %a, double %b) { +; CHECK-LABEL: @auto_gen_43( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_44(double %a, double %b) { +; CHECK-LABEL: @auto_gen_44( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_45(double %a, double %b) { +; CHECK-LABEL: @auto_gen_45( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_46(double %a, double %b) { +; CHECK-LABEL: @auto_gen_46( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_47(double %a, double %b) { +; CHECK-LABEL: @auto_gen_47( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_48(double %a, double %b) { +; CHECK-LABEL: @auto_gen_48( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_49(double %a, double %b) { +; CHECK-LABEL: @auto_gen_49( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_50(double %a, double %b) { +; CHECK-LABEL: @auto_gen_50( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_51(double %a, double %b) { +; CHECK-LABEL: @auto_gen_51( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_52(double %a, double %b) { +; CHECK-LABEL: @auto_gen_52( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_53(double %a, double %b) { +; CHECK-LABEL: @auto_gen_53( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_54(double %a, double %b) { +; CHECK-LABEL: @auto_gen_54( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_55(double %a, double %b) { +; CHECK-LABEL: @auto_gen_55( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_56(double %a, double %b) { +; CHECK-LABEL: @auto_gen_56( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_57(double %a, double %b) { +; CHECK-LABEL: @auto_gen_57( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_58(double %a, double %b) { +; CHECK-LABEL: @auto_gen_58( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_59(double %a, double %b) { +; CHECK-LABEL: @auto_gen_59( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_60(double %a, double %b) { +; CHECK-LABEL: @auto_gen_60( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_61(double %a, double %b) { +; CHECK-LABEL: @auto_gen_61( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_62(double %a, double %b) { +; CHECK-LABEL: @auto_gen_62( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_63(double %a, double %b) { +; CHECK-LABEL: @auto_gen_63( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_64(double %a, double %b) { +; CHECK-LABEL: @auto_gen_64( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_65(double %a, double %b) { +; CHECK-LABEL: @auto_gen_65( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_66(double %a, double %b) { +; CHECK-LABEL: @auto_gen_66( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_67(double %a, double %b) { +; CHECK-LABEL: @auto_gen_67( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_68(double %a, double %b) { +; CHECK-LABEL: @auto_gen_68( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_69(double %a, double %b) { +; CHECK-LABEL: @auto_gen_69( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_70(double %a, double %b) { +; CHECK-LABEL: @auto_gen_70( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_71(double %a, double %b) { +; CHECK-LABEL: @auto_gen_71( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_72(double %a, double %b) { +; CHECK-LABEL: @auto_gen_72( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_73(double %a, double %b) { +; CHECK-LABEL: @auto_gen_73( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_74(double %a, double %b) { +; CHECK-LABEL: @auto_gen_74( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_75(double %a, double %b) { +; CHECK-LABEL: @auto_gen_75( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_76(double %a, double %b) { +; CHECK-LABEL: @auto_gen_76( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_77(double %a, double %b) { +; CHECK-LABEL: @auto_gen_77( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_78(double %a, double %b) { +; CHECK-LABEL: @auto_gen_78( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_79(double %a, double %b) { +; CHECK-LABEL: @auto_gen_79( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_80(double %a, double %b) { +; CHECK-LABEL: @auto_gen_80( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_81(double %a, double %b) { +; CHECK-LABEL: @auto_gen_81( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_82(double %a, double %b) { +; CHECK-LABEL: @auto_gen_82( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_83(double %a, double %b) { +; CHECK-LABEL: @auto_gen_83( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_84(double %a, double %b) { +; CHECK-LABEL: @auto_gen_84( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_85(double %a, double %b) { +; CHECK-LABEL: @auto_gen_85( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_86(double %a, double %b) { +; CHECK-LABEL: @auto_gen_86( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_87(double %a, double %b) { +; CHECK-LABEL: @auto_gen_87( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_88(double %a, double %b) { +; CHECK-LABEL: @auto_gen_88( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_89(double %a, double %b) { +; CHECK-LABEL: @auto_gen_89( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_90(double %a, double %b) { +; CHECK-LABEL: @auto_gen_90( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_91(double %a, double %b) { +; CHECK-LABEL: @auto_gen_91( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_92(double %a, double %b) { +; CHECK-LABEL: @auto_gen_92( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_93(double %a, double %b) { +; CHECK-LABEL: @auto_gen_93( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_94(double %a, double %b) { +; CHECK-LABEL: @auto_gen_94( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_95(double %a, double %b) { +; CHECK-LABEL: @auto_gen_95( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_96(double %a, double %b) { +; CHECK-LABEL: @auto_gen_96( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_97(double %a, double %b) { +; CHECK-LABEL: @auto_gen_97( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_98(double %a, double %b) { +; CHECK-LABEL: @auto_gen_98( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_99(double %a, double %b) { +; CHECK-LABEL: @auto_gen_99( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_100(double %a, double %b) { +; CHECK-LABEL: @auto_gen_100( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_101(double %a, double %b) { +; CHECK-LABEL: @auto_gen_101( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_102(double %a, double %b) { +; CHECK-LABEL: @auto_gen_102( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_103(double %a, double %b) { +; CHECK-LABEL: @auto_gen_103( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_104(double %a, double %b) { +; CHECK-LABEL: @auto_gen_104( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_105(double %a, double %b) { +; CHECK-LABEL: @auto_gen_105( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_106(double %a, double %b) { +; CHECK-LABEL: @auto_gen_106( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_107(double %a, double %b) { +; CHECK-LABEL: @auto_gen_107( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_108(double %a, double %b) { +; CHECK-LABEL: @auto_gen_108( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_109(double %a, double %b) { +; CHECK-LABEL: @auto_gen_109( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_110(double %a, double %b) { +; CHECK-LABEL: @auto_gen_110( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_111(double %a, double %b) { +; CHECK-LABEL: @auto_gen_111( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_112(double %a, double %b) { +; CHECK-LABEL: @auto_gen_112( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_113(double %a, double %b) { +; CHECK-LABEL: @auto_gen_113( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_114(double %a, double %b) { +; CHECK-LABEL: @auto_gen_114( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_115(double %a, double %b) { +; CHECK-LABEL: @auto_gen_115( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_116(double %a, double %b) { +; CHECK-LABEL: @auto_gen_116( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_117(double %a, double %b) { +; CHECK-LABEL: @auto_gen_117( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_118(double %a, double %b) { +; CHECK-LABEL: @auto_gen_118( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_119(double %a, double %b) { +; CHECK-LABEL: @auto_gen_119( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp uno double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_120(double %a, double %b) { +; CHECK-LABEL: @auto_gen_120( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_121(double %a, double %b) { +; CHECK-LABEL: @auto_gen_121( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_122(double %a, double %b) { +; CHECK-LABEL: @auto_gen_122( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_123(double %a, double %b) { +; CHECK-LABEL: @auto_gen_123( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_124(double %a, double %b) { +; CHECK-LABEL: @auto_gen_124( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_125(double %a, double %b) { +; CHECK-LABEL: @auto_gen_125( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_126(double %a, double %b) { +; CHECK-LABEL: @auto_gen_126( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_127(double %a, double %b) { +; CHECK-LABEL: @auto_gen_127( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_128(double %a, double %b) { +; CHECK-LABEL: @auto_gen_128( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_129(double %a, double %b) { +; CHECK-LABEL: @auto_gen_129( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_130(double %a, double %b) { +; CHECK-LABEL: @auto_gen_130( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_131(double %a, double %b) { +; CHECK-LABEL: @auto_gen_131( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_132(double %a, double %b) { +; CHECK-LABEL: @auto_gen_132( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_133(double %a, double %b) { +; CHECK-LABEL: @auto_gen_133( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_134(double %a, double %b) { +; CHECK-LABEL: @auto_gen_134( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP1:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[CMP1]] +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp uno double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_135(double %a, double %b) { +; CHECK-LABEL: @auto_gen_135( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp true double %a, %b + %retval = and i1 %cmp, %cmp1 + ret i1 %retval +} Index: test/Transforms/InstCombine/or-fcmp.ll =================================================================== --- test/Transforms/InstCombine/or-fcmp.ll +++ test/Transforms/InstCombine/or-fcmp.ll @@ -54,3 +54,1729 @@ %c = or i1 %a, %b ret i1 %c } + +define i1 @auto_gen_0(double %a, double %b) { +; CHECK-LABEL: @auto_gen_0( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 false +; +bb: + %cmp = fcmp false double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_1(double %a, double %b) { +; CHECK-LABEL: @auto_gen_1( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp oeq double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_2(double %a, double %b) { +; CHECK-LABEL: @auto_gen_2( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oeq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oeq double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_3(double %a, double %b) { +; CHECK-LABEL: @auto_gen_3( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_4(double %a, double %b) { +; CHECK-LABEL: @auto_gen_4( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_5(double %a, double %b) { +; CHECK-LABEL: @auto_gen_5( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ogt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ogt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_6(double %a, double %b) { +; CHECK-LABEL: @auto_gen_6( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_7(double %a, double %b) { +; CHECK-LABEL: @auto_gen_7( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_8(double %a, double %b) { +; CHECK-LABEL: @auto_gen_8( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_9(double %a, double %b) { +; CHECK-LABEL: @auto_gen_9( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp oge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp oge double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_10(double %a, double %b) { +; CHECK-LABEL: @auto_gen_10( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_11(double %a, double %b) { +; CHECK-LABEL: @auto_gen_11( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_12(double %a, double %b) { +; CHECK-LABEL: @auto_gen_12( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_13(double %a, double %b) { +; CHECK-LABEL: @auto_gen_13( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_14(double %a, double %b) { +; CHECK-LABEL: @auto_gen_14( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp olt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp olt double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_15(double %a, double %b) { +; CHECK-LABEL: @auto_gen_15( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_16(double %a, double %b) { +; CHECK-LABEL: @auto_gen_16( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_17(double %a, double %b) { +; CHECK-LABEL: @auto_gen_17( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_18(double %a, double %b) { +; CHECK-LABEL: @auto_gen_18( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_19(double %a, double %b) { +; CHECK-LABEL: @auto_gen_19( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_20(double %a, double %b) { +; CHECK-LABEL: @auto_gen_20( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ole double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ole double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_21(double %a, double %b) { +; CHECK-LABEL: @auto_gen_21( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_22(double %a, double %b) { +; CHECK-LABEL: @auto_gen_22( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_23(double %a, double %b) { +; CHECK-LABEL: @auto_gen_23( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_24(double %a, double %b) { +; CHECK-LABEL: @auto_gen_24( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_25(double %a, double %b) { +; CHECK-LABEL: @auto_gen_25( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_26(double %a, double %b) { +; CHECK-LABEL: @auto_gen_26( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_27(double %a, double %b) { +; CHECK-LABEL: @auto_gen_27( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp one double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp one double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_28(double %a, double %b) { +; CHECK-LABEL: @auto_gen_28( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_29(double %a, double %b) { +; CHECK-LABEL: @auto_gen_29( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_30(double %a, double %b) { +; CHECK-LABEL: @auto_gen_30( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_31(double %a, double %b) { +; CHECK-LABEL: @auto_gen_31( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_32(double %a, double %b) { +; CHECK-LABEL: @auto_gen_32( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_33(double %a, double %b) { +; CHECK-LABEL: @auto_gen_33( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_34(double %a, double %b) { +; CHECK-LABEL: @auto_gen_34( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_35(double %a, double %b) { +; CHECK-LABEL: @auto_gen_35( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ord double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ord double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_36(double %a, double %b) { +; CHECK-LABEL: @auto_gen_36( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_37(double %a, double %b) { +; CHECK-LABEL: @auto_gen_37( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_38(double %a, double %b) { +; CHECK-LABEL: @auto_gen_38( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_39(double %a, double %b) { +; CHECK-LABEL: @auto_gen_39( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_40(double %a, double %b) { +; CHECK-LABEL: @auto_gen_40( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_41(double %a, double %b) { +; CHECK-LABEL: @auto_gen_41( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_42(double %a, double %b) { +; CHECK-LABEL: @auto_gen_42( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_43(double %a, double %b) { +; CHECK-LABEL: @auto_gen_43( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_44(double %a, double %b) { +; CHECK-LABEL: @auto_gen_44( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ueq double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_45(double %a, double %b) { +; CHECK-LABEL: @auto_gen_45( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_46(double %a, double %b) { +; CHECK-LABEL: @auto_gen_46( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_47(double %a, double %b) { +; CHECK-LABEL: @auto_gen_47( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_48(double %a, double %b) { +; CHECK-LABEL: @auto_gen_48( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_49(double %a, double %b) { +; CHECK-LABEL: @auto_gen_49( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_50(double %a, double %b) { +; CHECK-LABEL: @auto_gen_50( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_51(double %a, double %b) { +; CHECK-LABEL: @auto_gen_51( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_52(double %a, double %b) { +; CHECK-LABEL: @auto_gen_52( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_53(double %a, double %b) { +; CHECK-LABEL: @auto_gen_53( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_54(double %a, double %b) { +; CHECK-LABEL: @auto_gen_54( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ugt double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_55(double %a, double %b) { +; CHECK-LABEL: @auto_gen_55( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_56(double %a, double %b) { +; CHECK-LABEL: @auto_gen_56( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_57(double %a, double %b) { +; CHECK-LABEL: @auto_gen_57( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_58(double %a, double %b) { +; CHECK-LABEL: @auto_gen_58( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_59(double %a, double %b) { +; CHECK-LABEL: @auto_gen_59( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_60(double %a, double %b) { +; CHECK-LABEL: @auto_gen_60( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_61(double %a, double %b) { +; CHECK-LABEL: @auto_gen_61( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_62(double %a, double %b) { +; CHECK-LABEL: @auto_gen_62( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_63(double %a, double %b) { +; CHECK-LABEL: @auto_gen_63( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_64(double %a, double %b) { +; CHECK-LABEL: @auto_gen_64( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_65(double %a, double %b) { +; CHECK-LABEL: @auto_gen_65( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uge double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_66(double %a, double %b) { +; CHECK-LABEL: @auto_gen_66( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_67(double %a, double %b) { +; CHECK-LABEL: @auto_gen_67( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_68(double %a, double %b) { +; CHECK-LABEL: @auto_gen_68( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_69(double %a, double %b) { +; CHECK-LABEL: @auto_gen_69( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_70(double %a, double %b) { +; CHECK-LABEL: @auto_gen_70( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_71(double %a, double %b) { +; CHECK-LABEL: @auto_gen_71( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_72(double %a, double %b) { +; CHECK-LABEL: @auto_gen_72( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_73(double %a, double %b) { +; CHECK-LABEL: @auto_gen_73( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_74(double %a, double %b) { +; CHECK-LABEL: @auto_gen_74( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_75(double %a, double %b) { +; CHECK-LABEL: @auto_gen_75( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_76(double %a, double %b) { +; CHECK-LABEL: @auto_gen_76( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_77(double %a, double %b) { +; CHECK-LABEL: @auto_gen_77( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ult double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_78(double %a, double %b) { +; CHECK-LABEL: @auto_gen_78( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_79(double %a, double %b) { +; CHECK-LABEL: @auto_gen_79( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_80(double %a, double %b) { +; CHECK-LABEL: @auto_gen_80( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_81(double %a, double %b) { +; CHECK-LABEL: @auto_gen_81( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_82(double %a, double %b) { +; CHECK-LABEL: @auto_gen_82( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_83(double %a, double %b) { +; CHECK-LABEL: @auto_gen_83( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_84(double %a, double %b) { +; CHECK-LABEL: @auto_gen_84( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_85(double %a, double %b) { +; CHECK-LABEL: @auto_gen_85( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_86(double %a, double %b) { +; CHECK-LABEL: @auto_gen_86( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_87(double %a, double %b) { +; CHECK-LABEL: @auto_gen_87( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_88(double %a, double %b) { +; CHECK-LABEL: @auto_gen_88( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_89(double %a, double %b) { +; CHECK-LABEL: @auto_gen_89( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_90(double %a, double %b) { +; CHECK-LABEL: @auto_gen_90( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp ule double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_91(double %a, double %b) { +; CHECK-LABEL: @auto_gen_91( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_92(double %a, double %b) { +; CHECK-LABEL: @auto_gen_92( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_93(double %a, double %b) { +; CHECK-LABEL: @auto_gen_93( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_94(double %a, double %b) { +; CHECK-LABEL: @auto_gen_94( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_95(double %a, double %b) { +; CHECK-LABEL: @auto_gen_95( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_96(double %a, double %b) { +; CHECK-LABEL: @auto_gen_96( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_97(double %a, double %b) { +; CHECK-LABEL: @auto_gen_97( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_98(double %a, double %b) { +; CHECK-LABEL: @auto_gen_98( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_99(double %a, double %b) { +; CHECK-LABEL: @auto_gen_99( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_100(double %a, double %b) { +; CHECK-LABEL: @auto_gen_100( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_101(double %a, double %b) { +; CHECK-LABEL: @auto_gen_101( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_102(double %a, double %b) { +; CHECK-LABEL: @auto_gen_102( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_103(double %a, double %b) { +; CHECK-LABEL: @auto_gen_103( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_104(double %a, double %b) { +; CHECK-LABEL: @auto_gen_104( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp une double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_105(double %a, double %b) { +; CHECK-LABEL: @auto_gen_105( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[CMP:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[CMP]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_106(double %a, double %b) { +; CHECK-LABEL: @auto_gen_106( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_107(double %a, double %b) { +; CHECK-LABEL: @auto_gen_107( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_108(double %a, double %b) { +; CHECK-LABEL: @auto_gen_108( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_109(double %a, double %b) { +; CHECK-LABEL: @auto_gen_109( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_110(double %a, double %b) { +; CHECK-LABEL: @auto_gen_110( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_111(double %a, double %b) { +; CHECK-LABEL: @auto_gen_111( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_112(double %a, double %b) { +; CHECK-LABEL: @auto_gen_112( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_113(double %a, double %b) { +; CHECK-LABEL: @auto_gen_113( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ueq double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_114(double %a, double %b) { +; CHECK-LABEL: @auto_gen_114( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ugt double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_115(double %a, double %b) { +; CHECK-LABEL: @auto_gen_115( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uge double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_116(double %a, double %b) { +; CHECK-LABEL: @auto_gen_116( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ult double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_117(double %a, double %b) { +; CHECK-LABEL: @auto_gen_117( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp ule double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_118(double %a, double %b) { +; CHECK-LABEL: @auto_gen_118( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp une double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_119(double %a, double %b) { +; CHECK-LABEL: @auto_gen_119( +; CHECK-NEXT: bb: +; CHECK-NEXT: [[TMP0:%.*]] = fcmp uno double %a, %b +; CHECK-NEXT: ret i1 [[TMP0]] +; +bb: + %cmp = fcmp uno double %a, %b + %cmp1 = fcmp uno double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_120(double %a, double %b) { +; CHECK-LABEL: @auto_gen_120( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp false double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_121(double %a, double %b) { +; CHECK-LABEL: @auto_gen_121( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp oeq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_122(double %a, double %b) { +; CHECK-LABEL: @auto_gen_122( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ogt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_123(double %a, double %b) { +; CHECK-LABEL: @auto_gen_123( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp oge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_124(double %a, double %b) { +; CHECK-LABEL: @auto_gen_124( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp olt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_125(double %a, double %b) { +; CHECK-LABEL: @auto_gen_125( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ole double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_126(double %a, double %b) { +; CHECK-LABEL: @auto_gen_126( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp one double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_127(double %a, double %b) { +; CHECK-LABEL: @auto_gen_127( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ord double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_128(double %a, double %b) { +; CHECK-LABEL: @auto_gen_128( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ueq double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_129(double %a, double %b) { +; CHECK-LABEL: @auto_gen_129( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ugt double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_130(double %a, double %b) { +; CHECK-LABEL: @auto_gen_130( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp uge double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_131(double %a, double %b) { +; CHECK-LABEL: @auto_gen_131( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ult double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_132(double %a, double %b) { +; CHECK-LABEL: @auto_gen_132( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp ule double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_133(double %a, double %b) { +; CHECK-LABEL: @auto_gen_133( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp une double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_134(double %a, double %b) { +; CHECK-LABEL: @auto_gen_134( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp uno double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +} + +define i1 @auto_gen_135(double %a, double %b) { +; CHECK-LABEL: @auto_gen_135( +; CHECK-NEXT: bb: +; CHECK-NEXT: ret i1 true +; +bb: + %cmp = fcmp true double %a, %b + %cmp1 = fcmp true double %a, %b + %retval = or i1 %cmp, %cmp1 + ret i1 %retval +}