Without this, I get e.g. 'PerformPendingInstantiations' -> 'std::fill',
now I get 'std::fill<unsigned long *, int>'.
Differential Revision: https://reviews.llvm.org/D61822
llvm-svn: 360539
if (!shouldEmitFunction(GD))
return;
- llvm::TimeTraceScope TimeScope(
- "CodeGen Function", [&]() { return FD->getQualifiedNameAsString(); });
+ llvm::TimeTraceScope TimeScope("CodeGen Function", [&]() {
+ std::string Name;
+ llvm::raw_string_ostream OS(Name);
+ FD->getNameForDiagnostic(OS, getContext().getPrintingPolicy(),
+ /*Qualified=*/true);
+ return Name;
+ });
if (const auto *Method = dyn_cast<CXXMethodDecl>(D)) {
// Make sure to emit the definition(s) before we emit the thunks.
return true;
llvm::TimeTraceScope TimeScope("InstantiateClass", [&]() {
- return Instantiation->getQualifiedNameAsString();
+ std::string Name;
+ llvm::raw_string_ostream OS(Name);
+ Instantiation->getNameForDiagnostic(OS, getPrintingPolicy(),
+ /*Qualified=*/true);
+ return Name;
});
Pattern = PatternDef;
}
llvm::TimeTraceScope TimeScope("InstantiateFunction", [&]() {
- return Function->getQualifiedNameAsString();
+ std::string Name;
+ llvm::raw_string_ostream OS(Name);
+ Function->getNameForDiagnostic(OS, getPrintingPolicy(),
+ /*Qualified=*/true);
+ return Name;
});
// If we're performing recursive template instantiation, create our own