LLDB  mainline
SystemInitializerFull.cpp
Go to the documentation of this file.
1 //===-- SystemInitializerFull.cpp -------------------------------*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
10 
12 
13 #if !defined(LLDB_DISABLE_PYTHON)
15 #endif
16 
17 #include "lldb/Core/Debugger.h"
18 #include "lldb/Host/Host.h"
22 #include "lldb/Utility/Timer.h"
23 
94 
95 #if defined(__APPLE__)
106 #endif
108 
109 #if defined(__FreeBSD__)
111 #endif
112 
113 #if defined(_WIN32)
116 #endif
117 
118 #include "llvm/Support/TargetSelect.h"
119 
120 #pragma clang diagnostic push
121 #pragma clang diagnostic ignored "-Wglobal-constructors"
122 #include "llvm/ExecutionEngine/MCJIT.h"
123 #pragma clang diagnostic pop
124 
125 #include <string>
126 
127 using namespace lldb_private;
128 
130 
132 
135  return e;
136 
141 
144 
146 
147 #ifndef LLDB_DISABLE_PYTHON
149 #endif
150 
151 #if !defined(LLDB_DISABLE_PYTHON)
153 #endif
154 
163 #if defined(__APPLE__)
165  PlatformDarwinKernel::Initialize();
166 #endif
167 
168  // Initialize LLVM and Clang
169  llvm::InitializeAllTargets();
170  llvm::InitializeAllAsmPrinters();
171  llvm::InitializeAllTargetMCs();
172  llvm::InitializeAllDisassemblers();
173 
175 
189 
193 
195 
205 
213 
219 
226 
230 
231 #if defined(_WIN32)
233 #endif
234 #if defined(__FreeBSD__)
236 #endif
237 #if defined(__APPLE__)
246 #endif
247 
248  // This plugin is valid on any host that talks to a Darwin remote. It
249  // shouldn't be limited to __APPLE__.
251 
252  // Platform agnostic plugins
254 
261 
262  // Scan for any system or user LLDB plug-ins
264 
265  // The process settings need to know about installed plug-ins, so the
266  // Settings must be initialized
267  // AFTER PluginManager::Initialize is called.
268 
270 
271  return llvm::Error::success();
272 }
273 
275  static Timer::Category func_cat(LLVM_PRETTY_FUNCTION);
276  Timer scoped_timer(func_cat, LLVM_PRETTY_FUNCTION);
277 
279 
280  // Terminate and unload and loaded system or user LLDB plug-ins
282 
284 
288 
303 
320 
326 
333 
337 
338 #if defined(__APPLE__)
347 #endif
348 
349 #if defined(__FreeBSD__)
351 #endif
353 
357 
363 
364 #ifndef LLDB_DISABLE_PYTHON
366 #endif
367 
376 #if defined(__APPLE__)
378  PlatformDarwinKernel::Terminate();
379 #endif
380 
385 
388 
389  // Now shutdown the common parts, in reverse order.
391 }
static void Terminate()
static void Terminate()
static void Initialize()
static void Terminate()
static void Terminate()
Definition: ProcessKDP.cpp:103
static void Terminate()
Enumerations for broadcasting.
Definition: SBLaunchInfo.h:14
static void Initialize()
static void Initialize()
static void Terminate()
static void Initialize()
static void Terminate()
static void Terminate()
llvm::Error Error
static void Terminate()
static void Initialize()
static void Initialize()
static void Terminate()
static void Initialize()
A timer class that simplifies common timing metrics.
Definition: Timer.h:23
static void Terminate()
static void Initialize()
static void Initialize()
Definition: ProcessKDP.cpp:710
static void Initialize()
static void Terminate()
static void Initialize()
static void Initialize()
static void SettingsInitialize()
Definition: Debugger.cpp:592
static void SettingsTerminate()
Definition: Debugger.cpp:594
static void Initialize()
static void Terminate()
static void Initialize()
static void Initialize()
static void Terminate()
static void Terminate()
static void Initialize()
static void Initialize()
static void Terminate()
static void Initialize()
static void Terminate()
static void Terminate()
static void Initialize()
static void Terminate()
static void Terminate()
static void Terminate()
static void Terminate()
static void Initialize()
static void Terminate()
static void Terminate()
static void Initialize()
static void Terminate()
static void Initialize()
static void Initialize()
static void Terminate()
static void Initialize()
static void Initialize()
static void Terminate()
static void Initialize()
static void Initialize()