Home | History | Annotate | Download | only in InstCombine

Lines Matching full:sext

163     C = ConstantExpr::getIntegerCast(C, Ty, isSigned /*Sext or ZExt*/);
193 case Instruction::SExt:
203 Opc == Instruction::SExt);
281 // If this is a vector sext from a compare, then we don't want to break the
283 if (opc == Instruction::SExt && isa<CmpInst>(V) && Ty->isVectorTy())
409 case Instruction::SExt:
671 case Instruction::SExt: // zext(sext(x)) -> sext(x).
899 /// transformSExtICmp - Transform (sext icmp) to bitwise / integer operations
915 In = Builder->CreateIntCast(In, CI.getType(), true/*SExt*/);
924 // the icmp and sext into bitwise/integer operations.
944 // sext ((x & 2^n) == 0) -> (x >> n) - 1
945 // sext ((x & 2^n) != 2^n) -> (x >> n) - 1
956 "sext");
958 // sext ((x & 2^n) != 0) -> (x << bitwidth-n) a>> bitwidth-1
959 // sext ((x & 2^n) == 2^n) -> (x << bitwidth-n) a>> bitwidth-1
968 BitWidth - 1), "sext");
973 return CastInst::CreateIntegerCast(In, CI.getType(), true/*SExt*/);
1021 case Instruction::SExt: // sext(sext(x)) -> sext(x)
1022 case Instruction::ZExt: // sext(zext(x)) -> zext(x)
1023 case Instruction::Trunc: // sext(trunc(x)) -> trunc(x) or sext(x)
1061 // eliminated before we try to optimize this sext.
1098 return BinaryOperator::CreateAShr(Builder->CreateShl(Res, ShAmt, "sext"),
1102 // If this input is a trunc from our destination, then turn sext(trunc(x))
1111 Value *Res = Builder->CreateShl(TI->getOperand(0), ShAmt, "sext");
1121 // use a sext for the whole extension. Since we don't, look deeper and check
1127 // %d = sext i8 %c to i32