[PATCH] D70340: Add a key method to Sema to optimize debug info size
Reid Kleckner via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Nov 18 15:59:23 PST 2019
rnk updated this revision to Diff 229943.
rnk added a comment.
- comment
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D70340/new/
https://reviews.llvm.org/D70340
Files:
clang/include/clang/Sema/Sema.h
clang/lib/Sema/Sema.cpp
Index: clang/lib/Sema/Sema.cpp
===================================================================
--- clang/lib/Sema/Sema.cpp
+++ clang/lib/Sema/Sema.cpp
@@ -189,6 +189,9 @@
SemaPPCallbackHandler->set(*this);
}
+// Anchor Sema's type info to this TU.
+void Sema::anchor() {}
+
void Sema::addImplicitTypedef(StringRef Name, QualType T) {
DeclarationName DN = &Context.Idents.get(Name);
if (IdResolver.begin(DN) == IdResolver.end())
Index: clang/include/clang/Sema/Sema.h
===================================================================
--- clang/include/clang/Sema/Sema.h
+++ clang/include/clang/Sema/Sema.h
@@ -332,6 +332,9 @@
Sema(const Sema &) = delete;
void operator=(const Sema &) = delete;
+ /// A key method to reduce duplicate type info from Sema.
+ virtual void anchor();
+
///Source of additional semantic information.
ExternalSemaSource *ExternalSource;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D70340.229943.patch
Type: text/x-patch
Size: 899 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20191118/3898f044/attachment.bin>
More information about the cfe-commits
mailing list