Lines Matching refs:blockInfo

52                                         const CGBlockInfo &blockInfo,
57 const CGBlockInfo &blockInfo) { in buildCopyHelper() argument
58 return CodeGenFunction(CGM).GenerateCopyHelperFunction(blockInfo); in buildCopyHelper()
63 const CGBlockInfo &blockInfo) { in buildDisposeHelper() argument
64 return CodeGenFunction(CGM).GenerateDestroyHelperFunction(blockInfo); in buildDisposeHelper()
148 const CGBlockInfo &blockInfo) { in buildBlockDescriptor() argument
165 descName = getBlockDescriptorName(blockInfo, CGM); in buildBlockDescriptor()
182 elements.addInt(ulong, blockInfo.BlockSize.getQuantity()); in buildBlockDescriptor()
186 if (blockInfo.NeedsCopyDispose) { in buildBlockDescriptor()
188 llvm::Constant *copyHelper = buildCopyHelper(CGM, blockInfo); in buildBlockDescriptor()
192 llvm::Constant *disposeHelper = buildDisposeHelper(CGM, blockInfo); in buildBlockDescriptor()
204 CGM.getContext().getObjCEncodingForBlock(blockInfo.getBlockExpr()); in buildBlockDescriptor()
210 elements.add(CGM.getObjCRuntime().BuildGCBlockLayout(CGM, blockInfo)); in buildBlockDescriptor()
212 elements.add(CGM.getObjCRuntime().BuildRCBlockLayout(CGM, blockInfo)); in buildBlockDescriptor()
767 CGBlockInfo blockInfo(blockExpr->getBlockDecl(), CurFn->getName()); in EmitBlockLiteral() local
768 computeBlockInfo(CGM, this, blockInfo); in EmitBlockLiteral()
769 blockInfo.BlockExpression = blockExpr; in EmitBlockLiteral()
770 if (!blockInfo.CanBeGlobal) in EmitBlockLiteral()
771 blockInfo.LocalAddress = CreateTempAlloca(blockInfo.StructureType, in EmitBlockLiteral()
772 blockInfo.BlockAlign, "block"); in EmitBlockLiteral()
773 return EmitBlockLiteral(blockInfo); in EmitBlockLiteral()
776 llvm::Value *CodeGenFunction::EmitBlockLiteral(const CGBlockInfo &blockInfo) { in EmitBlockLiteral() argument
784 bool isLambdaConv = blockInfo.getBlockDecl()->isConversionFromLambda(); in EmitBlockLiteral()
788 CurGD, blockInfo, LocalDeclMap, isLambdaConv, blockInfo.CanBeGlobal); in EmitBlockLiteral()
792 if (blockInfo.CanBeGlobal) in EmitBlockLiteral()
793 return CGM.getAddrOfGlobalBlockIfEmitted(blockInfo.BlockExpression); in EmitBlockLiteral()
797 Address blockAddr = blockInfo.LocalAddress; in EmitBlockLiteral()
807 llvm::Constant *blockISA = blockInfo.NoEscape in EmitBlockLiteral()
813 descriptor = buildBlockDescriptor(CGM, blockInfo); in EmitBlockLiteral()
817 if (blockInfo.HasCapturedVariableLayout) in EmitBlockLiteral()
819 if (blockInfo.NeedsCopyDispose) in EmitBlockLiteral()
821 if (blockInfo.HasCXXObject) in EmitBlockLiteral()
823 if (blockInfo.UsesStret) in EmitBlockLiteral()
825 if (blockInfo.NoEscape) in EmitBlockLiteral()
856 llvm::ConstantInt::get(IntTy, blockInfo.BlockSize.getQuantity()), in EmitBlockLiteral()
859 llvm::ConstantInt::get(IntTy, blockInfo.BlockAlign.getQuantity()), in EmitBlockLiteral()
867 for (auto I : Helper->getCustomFieldValues(*this, blockInfo)) { in EmitBlockLiteral()
878 const BlockDecl *blockDecl = blockInfo.getBlockDecl(); in EmitBlockLiteral()
883 projectField(blockInfo.CXXThisIndex, "block.captured-this.addr"); in EmitBlockLiteral()
890 const CGBlockInfo::Capture &capture = blockInfo.getCapture(variable); in EmitBlockLiteral()
1014 if (!blockInfo.NoEscape && !blockInfo.NeedsCopyDispose) in EmitBlockLiteral()
1076 blockAddr.getPointer(), ConvertType(blockInfo.getBlockExpr()->getType())); in EmitBlockLiteral()
1079 CGM.getOpenCLRuntime().recordBlockInfo(blockInfo.BlockExpression, InvokeFn, in EmitBlockLiteral()
1080 result, blockInfo.StructureType); in EmitBlockLiteral()
1261 CGBlockInfo blockInfo(BE->getBlockDecl(), Name); in GetAddrOfGlobalBlock() local
1262 blockInfo.BlockExpression = BE; in GetAddrOfGlobalBlock()
1265 computeBlockInfo(*this, nullptr, blockInfo); in GetAddrOfGlobalBlock()
1271 GlobalDecl(), blockInfo, LocalDeclMap, in GetAddrOfGlobalBlock()
1279 const CGBlockInfo &blockInfo, in buildGlobalBlock() argument
1281 assert(blockInfo.CanBeGlobal); in buildGlobalBlock()
1285 assert(!CGM.getAddrOfGlobalBlockIfEmitted(blockInfo.BlockExpression) && in buildGlobalBlock()
1303 if (blockInfo.UsesStret) in buildGlobalBlock()
1311 fields.addInt(CGM.IntTy, blockInfo.BlockSize.getQuantity()); in buildGlobalBlock()
1312 fields.addInt(CGM.IntTy, blockInfo.BlockAlign.getQuantity()); in buildGlobalBlock()
1320 fields.add(buildBlockDescriptor(CGM, blockInfo)); in buildGlobalBlock()
1323 for (auto *I : Helper->getCustomFieldValues(CGM, blockInfo)) { in buildGlobalBlock()
1333 "__block_literal_global", blockInfo.BlockAlign, in buildGlobalBlock()
1361 CGM.getTypes().ConvertType(blockInfo.getBlockExpr()->getType()); in buildGlobalBlock()
1364 CGM.setAddrOfGlobalBlock(blockInfo.BlockExpression, Result); in buildGlobalBlock()
1367 blockInfo.BlockExpression, in buildGlobalBlock()
1413 GlobalDecl GD, const CGBlockInfo &blockInfo, const DeclMapTy &ldm, in GenerateBlockFunction() argument
1415 const BlockDecl *blockDecl = blockInfo.getBlockDecl(); in GenerateBlockFunction()
1419 CurEHLocation = blockInfo.getBlockExpr()->getEndLoc(); in GenerateBlockFunction()
1421 BlockInfo = &blockInfo; in GenerateBlockFunction()
1460 const FunctionProtoType *fnType = blockInfo.getBlockExpr()->getFunctionType(); in GenerateBlockFunction()
1464 blockInfo.UsesStret = true; in GenerateBlockFunction()
1477 buildGlobalBlock(CGM, blockInfo, in GenerateBlockFunction()
1484 blockInfo.getBlockExpr()->getBody()->getBeginLoc()); in GenerateBlockFunction()
1507 LoadBlockStruct(), blockInfo.CXXThisIndex, "block.captured-this"); in GenerateBlockFunction()
1514 const CGBlockInfo::Capture &capture = blockInfo.getCapture(variable); in GenerateBlockFunction()
1554 const CGBlockInfo::Capture &capture = blockInfo.getCapture(variable); in GenerateBlockFunction()
1563 variable, BlockPointerDbgLoc, Builder, blockInfo, in GenerateBlockFunction()
1864 CodeGenFunction::GenerateCopyHelperFunction(const CGBlockInfo &blockInfo) { in GenerateCopyHelperFunction() argument
1866 blockInfo.SortedCaptures, blockInfo.BlockAlign, in GenerateCopyHelperFunction()
1899 setBlockHelperAttributesVisibility(blockInfo.CapturesNonExternalType, Fn, FI, in GenerateCopyHelperFunction()
1905 src = Address(Builder.CreateLoad(src), blockInfo.StructureType, in GenerateCopyHelperFunction()
1906 blockInfo.BlockAlign); in GenerateCopyHelperFunction()
1909 dst = Address(Builder.CreateLoad(dst), blockInfo.StructureType, in GenerateCopyHelperFunction()
1910 blockInfo.BlockAlign); in GenerateCopyHelperFunction()
1912 for (auto &capture : blockInfo.SortedCaptures) { in GenerateCopyHelperFunction()
2051 CodeGenFunction::GenerateDestroyHelperFunction(const CGBlockInfo &blockInfo) { in GenerateDestroyHelperFunction() argument
2053 blockInfo.SortedCaptures, blockInfo.BlockAlign, in GenerateDestroyHelperFunction()
2083 setBlockHelperAttributesVisibility(blockInfo.CapturesNonExternalType, Fn, FI, in GenerateDestroyHelperFunction()
2091 src = Address(Builder.CreateLoad(src), blockInfo.StructureType, in GenerateDestroyHelperFunction()
2092 blockInfo.BlockAlign); in GenerateDestroyHelperFunction()
2096 for (auto &capture : blockInfo.SortedCaptures) { in GenerateDestroyHelperFunction()