LLDB mainline
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/ProtocolServer.h"
#include "lldb/Core/StreamAsynchronousIO.h"
#include "lldb/Core/Telemetry.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/Version/Version.h"
#include "lldb/lldb-enumerations.h"
#include "llvm/ADT/STLExtras.h"
#include "llvm/ADT/StringRef.h"
#include "llvm/ADT/iterator.h"
#include "llvm/Config/llvm-config.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 <chrono>
#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.

Namespaces

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

Macros

#define LLDB_PROPERTIES_debugger
#define LLDB_PROPERTIES_debugger

Enumerations

enum  

Functions

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, Severity severity, std::string message, bool debugger_specific)
static std::shared_ptr< LogHandlerCreateLogHandler (LogHandlerKind log_handler_kind, int fd, bool should_close, size_t buffer_size)

Variables

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 195 of file Debugger.cpp.

◆ LLDB_PROPERTIES_debugger [2/2]

#define LLDB_PROPERTIES_debugger

Definition at line 195 of file Debugger.cpp.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

Definition at line 198 of file Debugger.cpp.

Function Documentation

◆ CreateLogHandler()

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

◆ LoadPluginCallback()

◆ OpenPipe()

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

Definition at line 1124 of file Debugger.cpp.

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

◆ PrivateReportDiagnostic()

◆ PrivateReportProgress()

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

Variable Documentation

◆ g_debugger_event_thread_stack_bytes

size_t g_debugger_event_thread_stack_bytes = 8 * 1024 * 1024
static

Definition at line 104 of file Debugger.cpp.

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

◆ g_debugger_list_mutex_ptr

◆ g_debugger_list_ptr

◆ g_dwim_print_verbosities

OptionEnumValueElement g_dwim_print_verbosities[]
staticconstexpr
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 157 of file Debugger.cpp.

◆ g_language_enumerators

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

Definition at line 139 of file Debugger.cpp.

◆ g_show_disassembly_enum_values

OptionEnumValueElement g_show_disassembly_enum_values[]
staticconstexpr
Initial value:
= {
{
"never",
"Never show disassembly when displaying a stop context.",
},
{
"no-debuginfo",
"Show disassembly when there is no debug information.",
},
{
"no-source",
"Show disassembly when there is no source information, or the source "
"file "
"is missing when displaying a stop context.",
},
{
"always",
"Always show disassembly when displaying a stop context.",
},
}
@ eStopDisassemblyTypeNever
@ eStopDisassemblyTypeNoSource
@ eStopDisassemblyTypeAlways
@ eStopDisassemblyTypeNoDebugInfo

Definition at line 114 of file Debugger.cpp.

◆ g_thread_pool

llvm::DefaultThreadPool* g_thread_pool = nullptr
static

◆ g_unique_id

◆ s_stop_show_column_values

OptionEnumValueElement s_stop_show_column_values[]
staticconstexpr
Initial value:
= {
{
"ansi-or-caret",
"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.",
},
{
"ansi",
"Highlight the stop column with ANSI terminal codes when running LLDB "
"with color/ANSI enabled.",
},
{
"caret",
"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.",
},
{
"none",
"Do not highlight the stop column.",
},
}
@ eStopShowColumnAnsi
@ eStopShowColumnCaret
@ eStopShowColumnNone
@ eStopShowColumnAnsiOrCaret

Definition at line 167 of file Debugger.cpp.