[Lldb-commits] [lldb] r269416 - Remove ASTContexts from SystemInitializerCommon

Pavel Labath via lldb-commits lldb-commits at lists.llvm.org
Fri May 13 06:40:51 PDT 2016


Author: labath
Date: Fri May 13 08:40:51 2016
New Revision: 269416

URL: http://llvm.org/viewvc/llvm-project?rev=269416&view=rev
Log:
Remove ASTContexts from SystemInitializerCommon

Summary:
The AST contexts are not needed in the server components, and the clang context in particular
pulls in large parts of clang into the binary. Simply removing these two calls reduces the
lldb-server size by about 50%--80%, depending on the architecture and build type.

This should not impact the client parts as the same calls are already present in
SystemInitializerFull.

Reviewers: tberghammer, clayborg

Subscribers: lldb-commits

Differential Revision: http://reviews.llvm.org/D20236

Modified:
    lldb/trunk/source/Initialization/SystemInitializerCommon.cpp

Modified: lldb/trunk/source/Initialization/SystemInitializerCommon.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Initialization/SystemInitializerCommon.cpp?rev=269416&r1=269415&r2=269416&view=diff
==============================================================================
--- lldb/trunk/source/Initialization/SystemInitializerCommon.cpp (original)
+++ lldb/trunk/source/Initialization/SystemInitializerCommon.cpp Fri May 13 08:40:51 2016
@@ -13,8 +13,6 @@
 #include "lldb/Host/HostInfo.h"
 #include "lldb/Core/Log.h"
 #include "lldb/Core/Timer.h"
-#include "lldb/Symbol/GoASTContext.h"
-#include "lldb/Symbol/ClangASTContext.h"
 #include "Plugins/Instruction/ARM/EmulateInstructionARM.h"
 #include "Plugins/Instruction/MIPS/EmulateInstructionMIPS.h"
 #include "Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.h"
@@ -98,9 +96,6 @@ SystemInitializerCommon::Initialize()
     process_gdb_remote::ProcessGDBRemoteLog::Initialize();
 
     // Initialize plug-ins
-    ClangASTContext::Initialize();
-    GoASTContext::Initialize();
-
     ObjectContainerBSDArchive::Initialize();
     ObjectFileELF::Initialize();
     ObjectFilePECOFF::Initialize();
@@ -154,9 +149,6 @@ SystemInitializerCommon::Terminate()
     PlatformMacOSX::Terminate();
     PlatformRemoteiOS::Terminate();
 
-    ClangASTContext::Terminate();
-    GoASTContext::Terminate();
-
     EmulateInstructionARM::Terminate();
     EmulateInstructionMIPS::Terminate();
     EmulateInstructionMIPS64::Terminate();




More information about the lldb-commits mailing list