summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2015-03-26 23:45:40 +0000
committerChandler Carruth <chandlerc@gmail.com>2015-03-26 23:45:40 +0000
commit7bcfdd516c0f615a014e9013d329dc3c4706bb6b (patch)
tree079d01ce78fe751f31810c3b2a4ea0cfe9a56409
parent2a20e2705744b2e7c6e29542e8c50426a701aa95 (diff)
downloadbcm5719-llvm-7bcfdd516c0f615a014e9013d329dc3c4706bb6b.tar.gz
bcm5719-llvm-7bcfdd516c0f615a014e9013d329dc3c4706bb6b.zip
[Modules] Delete stale, pointless code. All tests still pass with this
logic removed. This logic was both inserting all builtins into the identifier table and ensuring they would get serialized. The first happens unconditionally now, and we always write out the entire identifier table. This code can simply go away. llvm-svn: 233331
-rw-r--r--clang/lib/Serialization/ASTWriter.cpp15
1 files changed, 0 insertions, 15 deletions
diff --git a/clang/lib/Serialization/ASTWriter.cpp b/clang/lib/Serialization/ASTWriter.cpp
index 24ba783c4ef..3f2c46d80ef 100644
--- a/clang/lib/Serialization/ASTWriter.cpp
+++ b/clang/lib/Serialization/ASTWriter.cpp
@@ -4335,21 +4335,6 @@ void ASTWriter::WriteASTCore(Sema &SemaRef,
if (Context.ExternCContext)
DeclIDs[Context.ExternCContext] = PREDEF_DECL_EXTERN_C_CONTEXT_ID;
- if (!Chain) {
- // Make sure that we emit IdentifierInfos (and any attached
- // declarations) for builtins. We don't need to do this when we're
- // emitting chained PCH files, because all of the builtins will be
- // in the original PCH file.
- // FIXME: Modules won't like this at all.
- IdentifierTable &Table = PP.getIdentifierTable();
- SmallVector<const char *, 32> BuiltinNames;
- if (!Context.getLangOpts().NoBuiltin) {
- Context.BuiltinInfo.GetBuiltinNames(BuiltinNames);
- }
- for (unsigned I = 0, N = BuiltinNames.size(); I != N; ++I)
- getIdentifierRef(&Table.get(BuiltinNames[I]));
- }
-
// Build a record containing all of the tentative definitions in this file, in
// TentativeDefinitions order. Generally, this record will be empty for
// headers.
OpenPOWER on IntegriCloud