LLDB mainline
Namespaces | Macros | Enumerations | Functions | Variables
Debugger.cpp File Reference
#include "lldb/Core/Debugger.h"
#include "lldb/Breakpoint/Breakpoint.h"
#include "lldb/Core/DebuggerEvents.h"
#include "lldb/Core/FormatEntity.h"
#include "lldb/Core/Mangled.h"
#include "lldb/Core/ModuleList.h"
#include "lldb/Core/ModuleSpec.h"
#include "lldb/Core/PluginManager.h"
#include "lldb/Core/Progress.h"
#include "lldb/Core/StreamAsynchronousIO.h"
#include "lldb/DataFormatters/DataVisualization.h"
#include "lldb/Expression/REPL.h"
#include "lldb/Host/File.h"
#include "lldb/Host/FileSystem.h"
#include "lldb/Host/HostInfo.h"
#include "lldb/Host/StreamFile.h"
#include "lldb/Host/Terminal.h"
#include "lldb/Host/ThreadLauncher.h"
#include "lldb/Interpreter/CommandInterpreter.h"
#include "lldb/Interpreter/CommandReturnObject.h"
#include "lldb/Interpreter/OptionValue.h"
#include "lldb/Interpreter/OptionValueLanguage.h"
#include "lldb/Interpreter/OptionValueProperties.h"
#include "lldb/Interpreter/OptionValueSInt64.h"
#include "lldb/Interpreter/OptionValueString.h"
#include "lldb/Interpreter/Property.h"
#include "lldb/Interpreter/ScriptInterpreter.h"
#include "lldb/Symbol/Function.h"
#include "lldb/Symbol/Symbol.h"
#include "lldb/Symbol/SymbolContext.h"
#include "lldb/Target/Language.h"
#include "lldb/Target/Process.h"
#include "lldb/Target/StructuredDataPlugin.h"
#include "lldb/Target/Target.h"
#include "lldb/Target/TargetList.h"
#include "lldb/Target/Thread.h"
#include "lldb/Target/ThreadList.h"
#include "lldb/Utility/AnsiTerminal.h"
#include "lldb/Utility/Event.h"
#include "lldb/Utility/LLDBLog.h"
#include "lldb/Utility/Listener.h"
#include "lldb/Utility/Log.h"
#include "lldb/Utility/State.h"
#include "lldb/Utility/Stream.h"
#include "lldb/Utility/StreamString.h"
#include "lldb/lldb-enumerations.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/iterator.h"
#include "llvm/Support/DynamicLibrary.h"
#include "llvm/Support/FileSystem.h"
#include "llvm/Support/Process.h"
#include "llvm/Support/ThreadPool.h"
#include "llvm/Support/Threading.h"
#include "llvm/Support/raw_ostream.h"
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <list>
#include <memory>
#include <mutex>
#include <optional>
#include <set>
#include <string>
#include <system_error>
#include <unistd.h>
#include "CoreProperties.inc"
#include "CorePropertiesEnum.inc"

Go to the source code of this file.


namespace  lldb_private
 A class that represents a running process on the host machine.


#define LLDB_PROPERTIES_debugger
#define LLDB_PROPERTIES_debugger




static FileSystem::EnumerateDirectoryResult LoadPluginCallback (void *baton, llvm::sys::fs::file_type ft, llvm::StringRef path)
static int OpenPipe (int fds[2], std::size_t size)
static void PrivateReportProgress (Debugger &debugger, uint64_t progress_id, std::string title, std::string details, uint64_t completed, uint64_t total, bool is_debugger_specific, uint32_t progress_broadcast_bit)
static void PrivateReportDiagnostic (Debugger &debugger, DiagnosticEventData::Type type, std::string message, bool debugger_specific)
static std::shared_ptr< LogHandlerCreateLogHandler (LogHandlerKind log_handler_kind, int fd, bool should_close, size_t buffer_size)


static lldb::user_id_t g_unique_id = 1
static size_t g_debugger_event_thread_stack_bytes = 8 * 1024 * 1024
static std::recursive_mutex * g_debugger_list_mutex_ptr
static Debugger::DebuggerListg_debugger_list_ptr
static llvm::DefaultThreadPool * g_thread_pool = nullptr
static constexpr OptionEnumValueElement g_show_disassembly_enum_values []
static constexpr OptionEnumValueElement g_language_enumerators []
static constexpr OptionEnumValueElement g_dwim_print_verbosities []
static constexpr OptionEnumValueElement s_stop_show_column_values []

Macro Definition Documentation

◆ LLDB_PROPERTIES_debugger [1/2]

#define LLDB_PROPERTIES_debugger

Definition at line 194 of file Debugger.cpp.

◆ LLDB_PROPERTIES_debugger [2/2]

#define LLDB_PROPERTIES_debugger

Definition at line 194 of file Debugger.cpp.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

Definition at line 193 of file Debugger.cpp.

Function Documentation

◆ CreateLogHandler()

static std::shared_ptr< LogHandler > CreateLogHandler ( LogHandlerKind  log_handler_kind,
int  fd,
bool  should_close,
size_t  buffer_size 

◆ LoadPluginCallback()

static FileSystem::EnumerateDirectoryResult LoadPluginCallback ( void *  baton,
llvm::sys::fs::file_type  ft,
llvm::StringRef  path 

◆ OpenPipe()

static int OpenPipe ( int  fds[2],
std::size_t  size 

Definition at line 977 of file Debugger.cpp.

Referenced by lldb_private::Debugger::SetInputString().

◆ PrivateReportDiagnostic()

static void PrivateReportDiagnostic ( Debugger debugger,
DiagnosticEventData::Type  type,
std::string  message,
bool  debugger_specific 

◆ PrivateReportProgress()

static void PrivateReportProgress ( Debugger debugger,
uint64_t  progress_id,
std::string  title,
std::string  details,
uint64_t  completed,
uint64_t  total,
bool  is_debugger_specific,
uint32_t  progress_broadcast_bit 

Variable Documentation

◆ g_debugger_event_thread_stack_bytes

size_t g_debugger_event_thread_stack_bytes = 8 * 1024 * 1024

Definition at line 99 of file Debugger.cpp.

Referenced by lldb_private::Debugger::StartEventHandlerThread().

◆ g_debugger_list_mutex_ptr

std::recursive_mutex* g_debugger_list_mutex_ptr

◆ g_debugger_list_ptr

Debugger::DebuggerList* g_debugger_list_ptr

◆ g_dwim_print_verbosities

constexpr OptionEnumValueElement g_dwim_print_verbosities[]
Initial value:
= {
"Use no verbosity when running dwim-print."},
"Use partial verbosity when running dwim-print - display a message when "
"`expression` evaluation is used."},
"Use full verbosity when running dwim-print."},
@ eDWIMPrintVerbosityFull
Always print a message indicating how dwim-print is evaluating its expression.
@ eDWIMPrintVerbosityNone
Run dwim-print with no verbosity.
@ eDWIMPrintVerbosityExpression
Print a message when dwim-print uses expression evaluation.

Definition at line 152 of file Debugger.cpp.

◆ g_language_enumerators

constexpr OptionEnumValueElement g_language_enumerators[]
Initial value:
= {
"Disable scripting languages.",
"Select python as the default scripting language.",
"Select the lldb default as the default scripting language.",
@ eScriptLanguageDefault
@ eScriptLanguageNone
@ eScriptLanguagePython

Definition at line 134 of file Debugger.cpp.

◆ g_show_disassembly_enum_values

constexpr OptionEnumValueElement g_show_disassembly_enum_values[]
Initial value:
= {
"Never show disassembly when displaying a stop context.",
"Show disassembly when there is no debug information.",
"Show disassembly when there is no source information, or the source "
"file "
"is missing when displaying a stop context.",
"Always show disassembly when displaying a stop context.",

Definition at line 109 of file Debugger.cpp.

◆ g_thread_pool

llvm::DefaultThreadPool* g_thread_pool = nullptr

◆ g_unique_id

lldb::user_id_t g_unique_id = 1

Definition at line 98 of file Debugger.cpp.

◆ s_stop_show_column_values

constexpr OptionEnumValueElement s_stop_show_column_values[]
Initial value:
= {
"Highlight the stop column with ANSI terminal codes when color/ANSI "
"mode is enabled; otherwise, fall back to using a text-only caret (^) "
"as if \"caret-only\" mode was selected.",
"Highlight the stop column with ANSI terminal codes when running LLDB "
"with color/ANSI enabled.",
"Highlight the stop column with a caret character (^) underneath the "
"stop column. This method introduces a new line in source listings "
"that display thread stop locations.",
"Do not highlight the stop column.",
@ eStopShowColumnAnsi
@ eStopShowColumnCaret
@ eStopShowColumnNone
@ eStopShowColumnAnsiOrCaret

Definition at line 162 of file Debugger.cpp.