Home
last modified time | relevance | path

Searched refs:FTy (Results 1 – 25 of 60) sorted by relevance

123

/external/llvm/lib/Transforms/IPO/
DFunctionAttrs.cpp835 FunctionType *FTy = F.getFunctionType(); in inferPrototypeAttributes() local
842 if (FTy->getNumParams() != 1 || !FTy->getParamType(0)->isPointerTy()) in inferPrototypeAttributes()
850 if (FTy->getNumParams() != 2 || in inferPrototypeAttributes()
851 !FTy->getParamType(0)->isPointerTy() || in inferPrototypeAttributes()
852 !FTy->getParamType(1)->isIntegerTy()) in inferPrototypeAttributes()
864 if (FTy->getNumParams() < 2 || in inferPrototypeAttributes()
865 !FTy->getParamType(1)->isPointerTy()) in inferPrototypeAttributes()
877 if (FTy->getNumParams() < 2 || in inferPrototypeAttributes()
878 !FTy->getParamType(1)->isPointerTy()) in inferPrototypeAttributes()
885 if (FTy->getNumParams() != 3 || in inferPrototypeAttributes()
[all …]
DDeadArgumentElimination.cpp217 FunctionType *FTy = Fn.getFunctionType(); in DeleteDeadVarargs() local
219 std::vector<Type*> Params(FTy->param_begin(), FTy->param_end()); in DeleteDeadVarargs()
220 FunctionType *NFTy = FunctionType::get(FTy->getReturnType(), in DeleteDeadVarargs()
697 FunctionType *FTy = F->getFunctionType(); in RemoveDeadStuffFromFunction() local
708 SmallVector<bool, 10> ArgAlive(FTy->getNumParams(), false); in RemoveDeadStuffFromFunction()
737 Type *RetTy = FTy->getReturnType(); in RemoveDeadStuffFromFunction()
842 FunctionType *NFTy = FunctionType::get(NRetTy, Params, FTy->isVarArg()); in RemoveDeadStuffFromFunction()
845 if (NFTy == FTy) in RemoveDeadStuffFromFunction()
888 for (unsigned e = FTy->getNumParams(); i != e; ++I, ++i) in RemoveDeadStuffFromFunction()
DExtractGV.cpp129 if (FunctionType *FTy = dyn_cast<FunctionType>(Ty)) { in runOnModule() local
130 Declaration = Function::Create(FTy, GlobalValue::ExternalLinkage, in runOnModule()
/external/llvm/unittests/IR/
DVerifierTest.cpp27 FunctionType *FTy = FunctionType::get(Type::getVoidTy(C), /*isVarArg=*/false); in TEST() local
28 Function *F = cast<Function>(M.getOrInsertFunction("foo", FTy)); in TEST()
50 FunctionType *FTy = FunctionType::get(Type::getInt32Ty(C), /*isVarArg=*/false); in TEST() local
51 Function *F = cast<Function>(M.getOrInsertFunction("foo", FTy)); in TEST()
/external/llvm/lib/ExecutionEngine/JIT/
DJIT.cpp243 FunctionType *FTy = F->getFunctionType(); in runFunction() local
244 Type *RetTy = FTy->getReturnType(); in runFunction()
246 assert((FTy->getNumParams() == ArgValues.size() || in runFunction()
247 (FTy->isVarArg() && FTy->getNumParams() <= ArgValues.size())) && in runFunction()
249 assert(FTy->getNumParams() == ArgValues.size() && in runFunction()
257 if (FTy->getParamType(0)->isIntegerTy(32) && in runFunction()
258 FTy->getParamType(1)->isPointerTy() && in runFunction()
259 FTy->getParamType(2)->isPointerTy()) { in runFunction()
272 if (FTy->getParamType(0)->isIntegerTy(32) && in runFunction()
273 FTy->getParamType(1)->isPointerTy()) { in runFunction()
[all …]
/external/llvm/lib/Transforms/Instrumentation/
DGCOVProfiling.cpp669 FunctionType *FTy = FunctionType::get(Type::getVoidTy(*Ctx), false); in emitProfileArcs() local
670 Function *F = Function::Create(FTy, GlobalValue::InternalLinkage, in emitProfileArcs()
681 FTy = FunctionType::get(Type::getVoidTy(*Ctx), false); in emitProfileArcs()
683 PointerType::get(FTy, 0), in emitProfileArcs()
684 PointerType::get(FTy, 0) in emitProfileArcs()
686 FTy = FunctionType::get(Builder.getVoidTy(), Params, false); in emitProfileArcs()
690 Constant *GCOVInit = M->getOrInsertFunction("llvm_gcov_init", FTy); in emitProfileArcs()
757 FunctionType *FTy = FunctionType::get(Type::getVoidTy(*Ctx), Args, false); in getStartFileFunc() local
758 return M->getOrInsertFunction("llvm_gcda_start_file", FTy); in getStartFileFunc()
768 FunctionType *FTy = FunctionType::get(Type::getVoidTy(*Ctx), Args, false); in getIncrementIndirectCounterFunc() local
[all …]
/external/llvm/lib/ExecutionEngine/MCJIT/
DMCJIT.cpp438 FunctionType *FTy = F->getFunctionType(); in runFunction() local
439 Type *RetTy = FTy->getReturnType(); in runFunction()
441 assert((FTy->getNumParams() == ArgValues.size() || in runFunction()
442 (FTy->isVarArg() && FTy->getNumParams() <= ArgValues.size())) && in runFunction()
444 assert(FTy->getNumParams() == ArgValues.size() && in runFunction()
452 if (FTy->getParamType(0)->isIntegerTy(32) && in runFunction()
453 FTy->getParamType(1)->isPointerTy() && in runFunction()
454 FTy->getParamType(2)->isPointerTy()) { in runFunction()
467 if (FTy->getParamType(0)->isIntegerTy(32) && in runFunction()
468 FTy->getParamType(1)->isPointerTy()) { in runFunction()
[all …]
/external/clang/lib/CodeGen/
DCGDeclCXX.cpp231 llvm::FunctionType *FTy, in CreateGlobalInitOrDestructFunction() argument
234 llvm::Function::Create(FTy, llvm::GlobalValue::InternalLinkage, in CreateGlobalInitOrDestructFunction()
264 llvm::FunctionType *FTy = llvm::FunctionType::get(VoidTy, false); in EmitCXXGlobalVarDeclInitFunc() local
273 CreateGlobalInitOrDestructFunction(*this, FTy, FnName.str()); in EmitCXXGlobalVarDeclInitFunc()
323 llvm::FunctionType *FTy = llvm::FunctionType::get(VoidTy, false); in EmitCXXThreadLocalInitFunc() local
324 InitFn = CreateGlobalInitOrDestructFunction(*this, FTy, "__tls_init", in EmitCXXThreadLocalInitFunc()
348 llvm::FunctionType *FTy = llvm::FunctionType::get(VoidTy, false); in EmitCXXGlobalInitFunc() local
373 CreateGlobalInitOrDestructFunction(*this, FTy, in EmitCXXGlobalInitFunc()
397 *this, FTy, llvm::Twine("_GLOBAL__sub_I_", FileName)); in EmitCXXGlobalInitFunc()
410 llvm::FunctionType *FTy = llvm::FunctionType::get(VoidTy, false); in EmitCXXGlobalDtorFunc() local
[all …]
DCGException.cpp29 llvm::FunctionType *FTy = in getAllocateExceptionFn() local
32 return CGM.CreateRuntimeFunction(FTy, "__cxa_allocate_exception"); in getAllocateExceptionFn()
38 llvm::FunctionType *FTy = in getFreeExceptionFn() local
41 return CGM.CreateRuntimeFunction(FTy, "__cxa_free_exception"); in getFreeExceptionFn()
49 llvm::FunctionType *FTy = in getThrowFn() local
52 return CGM.CreateRuntimeFunction(FTy, "__cxa_throw"); in getThrowFn()
58 llvm::FunctionType *FTy = in getReThrowFn() local
61 return CGM.CreateRuntimeFunction(FTy, "__cxa_rethrow"); in getReThrowFn()
67 llvm::FunctionType *FTy = in getGetExceptionPtrFn() local
70 return CGM.CreateRuntimeFunction(FTy, "__cxa_get_exception_ptr"); in getGetExceptionPtrFn()
[all …]
DItaniumCXXABI.cpp384 llvm::FunctionType *FTy = in EmitLoadOfMemberFunctionPointer() local
437 VTable = Builder.CreateBitCast(VTable, FTy->getPointerTo()->getPointerTo()); in EmitLoadOfMemberFunctionPointer()
445 Builder.CreateIntToPtr(FnAsInt, FTy->getPointerTo(), "memptr.nonvirtualfn"); in EmitLoadOfMemberFunctionPointer()
449 llvm::PHINode *Callee = Builder.CreatePHI(FTy->getPointerTo(), 2); in EmitLoadOfMemberFunctionPointer()
871 llvm::FunctionType *FTy = llvm::FunctionType::get(Int8PtrTy, Args, false); in getItaniumDynamicCastFn() local
879 return CGF.CGM.CreateRuntimeFunction(FTy, "__dynamic_cast", Attrs); in getItaniumDynamicCastFn()
884 llvm::FunctionType *FTy = llvm::FunctionType::get(CGF.VoidTy, false); in getBadCastFn() local
885 return CGF.CGM.CreateRuntimeFunction(FTy, "__cxa_bad_cast"); in getBadCastFn()
942 llvm::FunctionType *FTy = llvm::FunctionType::get(CGF.VoidTy, false); in getBadTypeidFn() local
944 return CGF.CGM.CreateRuntimeFunction(FTy, "__cxa_bad_typeid"); in getBadTypeidFn()
[all …]
DCGObjCMac.cpp246 llvm::FunctionType *FTy = in getGetPropertyFn() local
250 return CGM.CreateRuntimeFunction(FTy, "objc_getProperty"); in getGetPropertyFn()
266 llvm::FunctionType *FTy = in getSetPropertyFn() local
271 return CGM.CreateRuntimeFunction(FTy, "objc_setProperty"); in getSetPropertyFn()
293 llvm::FunctionType *FTy = in getOptimizedSetPropertyFn() local
308 return CGM.CreateRuntimeFunction(FTy, name); in getOptimizedSetPropertyFn()
321 llvm::FunctionType *FTy = in getCopyStructFn() local
326 return CGM.CreateRuntimeFunction(FTy, "objc_copyStruct"); in getCopyStructFn()
341 llvm::FunctionType *FTy = in getCppAtomicObjectFunction() local
346 return CGM.CreateRuntimeFunction(FTy, "objc_copyCppObjectAtomic"); in getCppAtomicObjectFunction()
[all …]
DCGCXXABI.cpp84 llvm::FunctionType *FTy = CGM.getTypes().GetFunctionType( in EmitLoadOfMemberFunctionPointer() local
86 return llvm::Constant::getNullValue(FTy->getPointerTo()); in EmitLoadOfMemberFunctionPointer()
/external/llvm/lib/Target/R600/
DAMDGPUPromoteAlloca.cpp58 const FunctionType *FTy = F.getFunctionType(); in runOnFunction() local
66 for (unsigned i = 0, e = FTy->getNumParams(); i != e; ++i) { in runOnFunction()
67 const Type *ParamTy = FTy->getParamType(i); in runOnFunction()
285 FunctionType *FTy = FunctionType::get( in visitAlloca() local
291 "llvm.r600.read.local.size.y", FTy, AttrSet); in visitAlloca()
293 "llvm.r600.read.local.size.z", FTy, AttrSet); in visitAlloca()
295 "llvm.r600.read.tidig.x", FTy, AttrSet); in visitAlloca()
297 "llvm.r600.read.tidig.y", FTy, AttrSet); in visitAlloca()
299 "llvm.r600.read.tidig.z", FTy, AttrSet); in visitAlloca()
/external/llvm/lib/Analysis/
DTargetTransformInfo.cpp53 unsigned TargetTransformInfo::getCallCost(FunctionType *FTy, in getCallCost() argument
55 return PrevTTI->getCallCost(FTy, NumArgs); in getCallCost()
334 unsigned getCallCost(FunctionType *FTy, int NumArgs = -1) const override in getCallCost()
336 assert(FTy && "FunctionType must be provided to this routine."); in getCallCost()
345 NumArgs = FTy->getNumParams(); in getCallCost()
360 FunctionType *FTy = F->getFunctionType(); in getCallCost() local
361 SmallVector<Type *, 8> ParamTys(FTy->param_begin(), FTy->param_end()); in getCallCost()
362 return TopTTI->getIntrinsicCost(IID, FTy->getReturnType(), ParamTys); in getCallCost()
428 Type *FTy = CS.getCalledValue()->getType()->getPointerElementType(); in getUserCost() local
429 return TopTTI->getCallCost(cast<FunctionType>(FTy), CS.arg_size()); in getUserCost()
DMemoryBuiltins.cpp128 FunctionType *FTy = Callee->getFunctionType(); in getAllocationData() local
130 if (FTy->getReturnType() == Type::getInt8PtrTy(FTy->getContext()) && in getAllocationData()
131 FTy->getNumParams() == FnData->NumParams && in getAllocationData()
133 (FTy->getParamType(FstParam)->isIntegerTy(32) || in getAllocationData()
134 FTy->getParamType(FstParam)->isIntegerTy(64))) && in getAllocationData()
136 FTy->getParamType(SndParam)->isIntegerTy(32) || in getAllocationData()
137 FTy->getParamType(SndParam)->isIntegerTy(64))) in getAllocationData()
344 FunctionType *FTy = Callee->getFunctionType(); in isFreeCall() local
345 if (!FTy->getReturnType()->isVoidTy()) in isFreeCall()
347 if (FTy->getNumParams() != ExpectedNumParams) in isFreeCall()
[all …]
/external/llvm/unittests/Linker/
DLinkModulesTest.cpp26 FunctionType *FTy = FunctionType::get( in SetUp() local
28 F = Function::Create(FTy, Function::ExternalLinkage, "ba_func", M.get()); in SetUp()
127 FunctionType *FTy = FunctionType::get( in TEST_F() local
130 F = Function::Create(FTy, Function::InternalLinkage, "bar", InternalM); in TEST_F()
137 StructType *STy = StructType::create(Ctx, PointerType::get(FTy, 0)); in TEST_F()
/external/llvm/unittests/Analysis/
DMixedTBAATest.cpp35 FunctionType *FTy = FunctionType::get(Type::getVoidTy(C), in TEST_F() local
37 auto *F = cast<Function>(M.getOrInsertFunction("f", FTy)); in TEST_F()
DScalarEvolutionTest.cpp40 FunctionType *FTy = FunctionType::get(Type::getVoidTy(Context), in TEST_F() local
42 Function *F = cast<Function>(M.getOrInsertFunction("f", FTy)); in TEST_F()
94 FunctionType *FTy = FunctionType::get(Type::getVoidTy(Context), Types, false); in TEST_F() local
95 Function *F = cast<Function>(M.getOrInsertFunction("f", FTy)); in TEST_F()
/external/llvm/lib/CodeGen/
DDwarfEHPrepare.cpp124 FunctionType *FTy = FunctionType::get(Type::getVoidTy(Ctx), in InsertUnwindResumeCalls() local
127 RewindFunction = Fn.getParent()->getOrInsertFunction(RewindName, FTy); in InsertUnwindResumeCalls()
/external/llvm/lib/ExecutionEngine/Interpreter/
DExternalFunctions.cpp185 FunctionType *FTy = F->getFunctionType(); in ffiInvoke() local
201 Type *ArgTy = FTy->getParamType(ArgNo); in ffiInvoke()
213 Type *ArgTy = FTy->getParamType(ArgNo); in ffiInvoke()
218 Type *RetTy = FTy->getReturnType(); in ffiInvoke()
/external/llvm/lib/Transforms/InstCombine/
DInstCombineCalls.cpp1190 FunctionType *FTy = cast<FunctionType>(PTy->getElementType()); in visitCallSite() local
1191 if (FTy->isVarArg()) { in visitCallSite()
1192 int ix = FTy->getNumParams(); in visitCallSite()
1195 for (CallSite::arg_iterator I = CS.arg_begin() + FTy->getNumParams(), in visitCallSite()
1491 FunctionType *FTy = cast<FunctionType>(PTy->getElementType()); in transformCallThroughTrampoline() local
1570 NewAttrs.push_back(AttributeSet::get(FTy->getContext(), in transformCallThroughTrampoline()
1578 NewTypes.reserve(FTy->getNumParams()+1); in transformCallThroughTrampoline()
1584 FunctionType::param_iterator I = FTy->param_begin(), in transformCallThroughTrampoline()
1585 E = FTy->param_end(); in transformCallThroughTrampoline()
1604 FunctionType *NewFTy = FunctionType::get(FTy->getReturnType(), NewTypes, in transformCallThroughTrampoline()
[all …]
/external/llvm/lib/IR/
DAsmWriter.cpp213 FunctionType *FTy = cast<FunctionType>(Ty); in print() local
214 print(FTy->getReturnType(), OS); in print()
216 for (FunctionType::param_iterator I = FTy->param_begin(), in print()
217 E = FTy->param_end(); I != E; ++I) { in print()
218 if (I != FTy->param_begin()) in print()
222 if (FTy->isVarArg()) { in print()
223 if (FTy->getNumParams()) OS << ", "; in print()
1932 FunctionType *FTy = cast<FunctionType>(PTy->getElementType()); in printInstruction() local
1933 Type *RetTy = FTy->getReturnType(); in printInstruction()
1944 if (!FTy->isVarArg() && in printInstruction()
[all …]
DVerifier.cpp1533 FunctionType *FTy = cast<FunctionType>(FPTy->getElementType()); in VerifyCallSite() local
1536 if (FTy->isVarArg()) in VerifyCallSite()
1537 Assert1(CS.arg_size() >= FTy->getNumParams(), in VerifyCallSite()
1540 Assert1(CS.arg_size() == FTy->getNumParams(), in VerifyCallSite()
1544 for (unsigned i = 0, e = FTy->getNumParams(); i != e; ++i) in VerifyCallSite()
1545 Assert3(CS.getArgument(i)->getType() == FTy->getParamType(i), in VerifyCallSite()
1547 CS.getArgument(i), FTy->getParamType(i), I); in VerifyCallSite()
1555 VerifyFunctionAttrs(FTy, Attrs, I); in VerifyCallSite()
1561 Value *InAllocaArg = CS.getArgument(FTy->getNumParams() - 1); in VerifyCallSite()
1567 if (FTy->isVarArg()) { in VerifyCallSite()
[all …]
/external/llvm/lib/Bitcode/Reader/
DBitcodeReader.cpp1951 FunctionType *FTy = in ParseModule() local
1953 if (!FTy) in ParseModule()
1956 Function *Func = Function::Create(FTy, GlobalValue::ExternalLinkage, in ParseModule()
2768 FunctionType *FTy = !CalleeTy ? nullptr : in ParseFunctionBody() local
2772 if (!FTy || !NormalBB || !UnwindBB || in ParseFunctionBody()
2773 Record.size() < OpNum+FTy->getNumParams()) in ParseFunctionBody()
2777 for (unsigned i = 0, e = FTy->getNumParams(); i != e; ++i, ++OpNum) { in ParseFunctionBody()
2779 FTy->getParamType(i))); in ParseFunctionBody()
2784 if (!FTy->isVarArg()) { in ParseFunctionBody()
3057 FunctionType *FTy = nullptr; in ParseFunctionBody() local
[all …]
/external/llvm/unittests/ExecutionEngine/JIT/
DJITMemoryManagerTest.cpp24 FunctionType *FTy = in makeFakeFunction() local
26 return Function::Create(FTy, GlobalValue::ExternalLinkage); in makeFakeFunction()

123