Lines Matching refs:Trunc
241 else if (auto *Trunc = dyn_cast<TruncInst>(V))
242 return EqualTypeSize(Trunc);
563 LLVM_DEBUG(dbgs() << "IR Promotion: Creating " << *TruncTy << " Trunc for "
566 auto *Trunc = dyn_cast<Instruction>(Builder.CreateTrunc(V, TruncTy));
567 if (Trunc)
568 NewInsts.insert(Trunc);
569 return Trunc;
582 if (Instruction *Trunc = InsertTrunc(Arg, Ty)) {
583 Trunc->moveBefore(Call);
584 Call->setArgOperand(i, Trunc);
593 if (Instruction *Trunc = InsertTrunc(Switch->getCondition(), Ty)) {
594 Trunc->moveBefore(Switch);
595 Switch->setCondition(Trunc);
603 if (Instruction *Trunc = InsertTrunc(I->getOperand(i), Ty)) {
604 Trunc->moveBefore(I);
605 I->setOperand(i, Trunc);
636 auto *Trunc = cast<TruncInst>(Src);
637 assert(Trunc->getOperand(0)->getType() == ExtTy &&
639 ReplaceAllUsersOfWith(ZExt, Trunc->getOperand(0));
658 auto *Trunc = cast<TruncInst>(V);
659 Builder.SetInsertPoint(Trunc);
660 IntegerType *SrcTy = cast<IntegerType>(Trunc->getOperand(0)->getType());
661 IntegerType *DestTy = cast<IntegerType>(TruncTysMap[Trunc][0]);
666 Value *Masked = Builder.CreateAnd(Trunc->getOperand(0), Mask);
671 ReplaceAllUsersOfWith(Trunc, Masked);
696 auto *Trunc = cast<TruncInst>(V);
697 TruncTysMap[Trunc].push_back(Trunc->getDestTy());
760 case Instruction::Trunc: