Lines Matching refs:callSite
2569 llvm::CallSite callSite(user); in replaceUsesOfNonProtoConstant() local
2570 if (!callSite) continue; in replaceUsesOfNonProtoConstant()
2571 if (!callSite.isCallee(&*use)) continue; in replaceUsesOfNonProtoConstant()
2575 if (callSite->getType() != newRetTy && !callSite->use_empty()) in replaceUsesOfNonProtoConstant()
2580 llvm::AttributeSet oldAttrs = callSite.getAttributes(); in replaceUsesOfNonProtoConstant()
2590 if (callSite.arg_size() < newNumArgs) continue; in replaceUsesOfNonProtoConstant()
2598 if (callSite.getArgument(argNo)->getType() != ai->getType()) { in replaceUsesOfNonProtoConstant()
2619 newArgs.append(callSite.arg_begin(), callSite.arg_begin() + argNo); in replaceUsesOfNonProtoConstant()
2622 callSite.getOperandBundlesAsDefs(newBundles); in replaceUsesOfNonProtoConstant()
2625 if (callSite.isCall()) { in replaceUsesOfNonProtoConstant()
2627 callSite.getInstruction()); in replaceUsesOfNonProtoConstant()
2629 auto *oldInvoke = cast<llvm::InvokeInst>(callSite.getInstruction()); in replaceUsesOfNonProtoConstant()
2634 callSite.getInstruction()); in replaceUsesOfNonProtoConstant()
2639 newCall->takeName(callSite.getInstruction()); in replaceUsesOfNonProtoConstant()
2642 newCall.setCallingConv(callSite.getCallingConv()); in replaceUsesOfNonProtoConstant()
2645 if (!callSite->use_empty()) in replaceUsesOfNonProtoConstant()
2646 callSite->replaceAllUsesWith(newCall.getInstruction()); in replaceUsesOfNonProtoConstant()
2649 if (callSite->getDebugLoc()) in replaceUsesOfNonProtoConstant()
2650 newCall->setDebugLoc(callSite->getDebugLoc()); in replaceUsesOfNonProtoConstant()
2652 callSite->eraseFromParent(); in replaceUsesOfNonProtoConstant()