Home | History | Annotate | Download | only in CodeGen

Lines Matching refs:GD

252     const GlobalDecl &GD = *I;
253 const auto *D = cast<ValueDecl>(GD.getDecl());
255 StringRef MangledName = getMangledName(GD);
301 const GlobalDecl &GD = *I;
302 StringRef MangledName = getMangledName(GD);
528 StringRef CodeGenModule::getMangledName(GlobalDecl GD) {
529 StringRef &FoundStr = MangledDeclNames[GD.getCanonicalDecl()];
533 const auto *ND = cast<NamedDecl>(GD.getDecl());
539 getCXXABI().getMangleContext().mangleCXXCtor(D, GD.getCtorType(), Out);
541 getCXXABI().getMangleContext().mangleCXXDtor(D, GD.getDtorType(), Out);
552 Mangled.second = GD;
556 StringRef CodeGenModule::getBlockMangledName(GlobalDecl GD,
559 const Decl *D = GD.getDecl();
567 MangleCtx.mangleCtorBlock(CD, GD.getCtorType(), BD, Out);
569 MangleCtx.mangleDtorBlock(DD, GD.getDtorType(), BD, Out);
629 CodeGenModule::getFunctionLinkage(GlobalDecl GD) {
630 const auto *D = cast<FunctionDecl>(GD.getDecl());
636 GD.getDtorType())) {
821 void CodeGenModule::SetFunctionAttributes(GlobalDecl GD,
832 const auto *FD = cast<FunctionDecl>(GD.getDecl());
835 SetLLVMFunctionAttributes(FD, getTypes().arrangeGlobalDeclaration(GD), F);
840 if (getCXXABI().HasThisReturn(GD) &&
856 if (getCXXABI().useThunkForDtorVariant(Dtor, GD.getDtorType())) {
1060 GlobalDecl D = G.GD;
1209 void CodeGenModule::EmitGlobal(GlobalDecl GD) {
1210 const auto *Global = cast<ValueDecl>(GD.getDecl());
1219 return EmitAliasDefinition(GD);
1245 StringRef MangledName = getMangledName(GD);
1248 const CGFunctionInfo &FI = getTypes().arrangeGlobalDeclaration(GD);
1251 GetOrCreateLLVMFunction(MangledName, Ty, GD, /*ForVTable=*/false,
1267 EmitGlobalDefinition(GD);
1281 StringRef MangledName = getMangledName(GD);
1283 addDeferredDeclToEmit(GV, GD);
1288 DeferredDecls[MangledName] = GD;
1348 CodeGenModule::shouldEmitFunction(GlobalDecl GD) {
1349 if (getFunctionLinkage(GD) != llvm::Function::AvailableExternallyLinkage)
1351 const auto *F = cast<FunctionDecl>(GD.getDecl());
1378 void CodeGenModule::EmitGlobalDefinition(GlobalDecl GD, llvm::GlobalValue *GV) {
1379 const auto *D = cast<ValueDecl>(GD.getDecl());
1388 if (!shouldEmitFunction(GD))
1396 EmitCXXConstructor(CD, GD.getCtorType());
1398 EmitCXXDestructor(DD, GD.getDtorType());
1400 EmitGlobalFunctionDefinition(GD, GV);
1403 getVTables().EmitThunks(GD);
1408 return EmitGlobalFunctionDefinition(GD, GV);
1427 GlobalDecl GD, bool ForVTable,
1430 const Decl *D = GD.getDecl();
1466 SetFunctionAttributes(GD, F, IsIncompleteFunction);
1481 GD.getDtorType()))
1482 addDeferredDeclToEmit(F, GD);
1500 addDeferredDeclToEmit(F, GD);
1523 addDeferredDeclToEmit(F, GD.getWithDecl(FD));
1526 addDeferredDeclToEmit(F, GD.getWithDecl(FD));
1548 llvm::Constant *CodeGenModule::GetAddrOfFunction(GlobalDecl GD,
1554 Ty = getTypes().ConvertType(cast<ValueDecl>(GD.getDecl())->getType());
1556 StringRef MangledName = getMangledName(GD);
1557 return GetOrCreateLLVMFunction(MangledName, Ty, GD, ForVTable, DontDefer);
2246 void CodeGenModule::EmitGlobalFunctionDefinition(GlobalDecl GD,
2248 const auto *D = cast<FunctionDecl>(GD.getDecl());
2251 const CGFunctionInfo &FI = getTypes().arrangeGlobalDeclaration(GD);
2257 GetAddrOfFunction(GD, Ty, /*ForVTable=*/false, /*DontDefer*/ true);
2286 auto *NewFn = cast<llvm::Function>(GetAddrOfFunction(GD, Ty));
2318 setFunctionLinkage(GD, Fn);
2338 void CodeGenModule::EmitAliasDefinition(GlobalDecl GD) {
2339 const auto *D = cast<ValueDecl>(GD.getDecl());
2343 StringRef MangledName = getMangledName(GD);
2351 Aliases.push_back(GD);
2359 Aliasee = GetOrCreateLLVMFunction(AA->getAliasee(), DeclTy, GD,
3319 GlobalDecl GD = GlobalDecl(cast<VarDecl>(D));
3320 EmitGlobalDeclMetadata(CGM, GlobalMetadata, GD, GV);