Lines Matching +full:ci +full:- +full:pass
1 //===-- PreISelIntrinsicLowering.cpp - Pre-ISel intrinsic lowering pass ---===//
8 //===----------------------------------------------------------------------===//
10 // This pass implements IR lowering for the llvm.load.relative intrinsic.
12 //===----------------------------------------------------------------------===//
21 #include "llvm/Pass.h"
33 Type *Int32PtrTy = Int32Ty->getPointerTo(); in lowerLoadRelative()
37 auto CI = dyn_cast<CallInst>(I->getUser()); in lowerLoadRelative() local
39 if (!CI || CI->getCalledValue() != &F) in lowerLoadRelative()
42 IRBuilder<> B(CI); in lowerLoadRelative()
44 B.CreateGEP(Int8Ty, CI->getArgOperand(0), CI->getArgOperand(1)); in lowerLoadRelative()
48 Value *ResultPtr = B.CreateGEP(Int8Ty, CI->getArgOperand(0), OffsetI32); in lowerLoadRelative()
50 CI->replaceAllUsesWith(ResultPtr); in lowerLoadRelative()
51 CI->eraseFromParent(); in lowerLoadRelative()
79 "pre-isel-intrinsic-lowering", "Pre-ISel Intrinsic Lowering",