45#define LLDB_OPTIONS_thread_backtrace
46#include "CommandOptions.inc"
65 switch (short_option) {
67 if (option_arg.getAsInteger(0,
m_count)) {
69 error.SetErrorStringWithFormat(
70 "invalid integer value for option '%c': %s", short_option,
78 if (option_arg.getAsInteger(0,
m_start))
79 error.SetErrorStringWithFormat(
80 "invalid integer value for option '%c': %s", short_option,
88 error.SetErrorStringWithFormat(
89 "invalid boolean value for option '%c': %s", short_option,
93 llvm_unreachable(
"Unimplemented option");
105 return llvm::ArrayRef(g_thread_backtrace_options);
116 interpreter,
"thread backtrace",
117 "Show thread call stacks. Defaults to the current thread, thread "
118 "indexes can be specified as arguments.\n"
119 "Use the thread-index \"all\" to see all threads.\n"
120 "Use the thread-index \"unique\" to see threads grouped by unique "
122 "Use 'settings set frame-format' to customize the printing of "
123 "frames in the backtrace and 'settings set thread-format' to "
124 "customize the thread header.",
126 eCommandRequiresProcess | eCommandRequiresThread |
127 eCommandTryTargetAPILock | eCommandProcessMustBeLaunched |
128 eCommandProcessMustBePaused) {}
135 uint32_t idx)
override {
136 llvm::StringRef count_opt(
"--count");
137 llvm::StringRef start_opt(
"--start");
144 Args copy_args(current_args);
147 size_t count_idx = 0;
148 size_t start_idx = 0;
149 size_t count_val = 0;
150 size_t start_val = 0;
152 for (
size_t idx = 0; idx < num_entries; idx++) {
153 llvm::StringRef arg_string = copy_args[idx].ref();
154 if (arg_string.equals(
"-c") || count_opt.starts_with(arg_string)) {
156 if (idx == num_entries)
159 if (copy_args[idx].ref().getAsInteger(0, count_val))
161 }
else if (arg_string.equals(
"-s") || start_opt.starts_with(arg_string)) {
163 if (idx == num_entries)
166 if (copy_args[idx].ref().getAsInteger(0, start_val))
173 std::string new_start_val = llvm::formatv(
"{0}", start_val + count_val);
174 if (start_idx == 0) {
180 std::string repeat_command;
183 return repeat_command;
191 const std::vector<ConstString> &types =
193 for (
auto type : types) {
195 thread->shared_from_this(), type);
196 if (ext_thread_sp && ext_thread_sp->IsValid()) {
197 const uint32_t num_frames_with_source = 0;
198 const bool stop_format =
false;
202 num_frames_with_source, stop_format)) {
215 "thread disappeared while computing backtraces: 0x%" PRIx64
"\n",
220 Thread *thread = thread_sp.get();
228 const uint32_t num_frames_with_source = 0;
229 const bool stop_format =
true;
231 num_frames_with_source, stop_format, only_stacks)) {
233 "error displaying backtrace for thread: \"0x%4.4x\"\n",
239 "Interrupt skipped extended backtrace")) {
252#define LLDB_OPTIONS_thread_step_scope
253#include "CommandOptions.inc"
266 return llvm::ArrayRef(g_thread_step_scope_options);
272 const int short_option =
273 g_thread_step_scope_options[option_idx].short_option;
275 switch (short_option) {
278 bool avoid_no_debug =
281 error.SetErrorStringWithFormat(
282 "invalid boolean value for option '%c': %s", short_option,
291 bool avoid_no_debug =
294 error.SetErrorStringWithFormat(
295 "invalid boolean value for option '%c': %s", short_option,
304 error.SetErrorStringWithFormat(
305 "invalid integer value for option '%c': %s", short_option,
316 if (option_arg ==
"block") {
321 error.SetErrorStringWithFormat(
"invalid end line number '%s'",
322 option_arg.str().c_str());
336 llvm_unreachable(
"Unimplemented option");
351 if (process_sp && process_sp->GetSteppingRunsAllThreads())
375 const char *name,
const char *help,
380 eCommandRequiresProcess | eCommandRequiresThread |
381 eCommandTryTargetAPILock |
382 eCommandProcessMustBeLaunched |
383 eCommandProcessMustBePaused),
419 if (thread ==
nullptr) {
420 result.
AppendError(
"no selected thread in process");
425 uint32_t step_thread_idx;
427 if (!llvm::to_integer(thread_idx_cstr, step_thread_idx)) {
434 if (thread ==
nullptr) {
436 "Thread index %u is out of range (valid values are 0 - %u).\n",
437 step_thread_idx, num_threads);
446 }
else if (!
GetDebugger().GetScriptInterpreter()->CheckObjectExists(
449 "class for scripted step: \"%s\" does not exist.",
458 "end line option is only valid for step into");
462 const bool abort_other_plans =
false;
467 bool bool_stop_other_threads;
469 bool_stop_other_threads =
false;
473 bool_stop_other_threads =
true;
480 assert(frame !=
nullptr);
506 "Could not find the current block address.");
520 abort_other_plans, range,
533 false, abort_other_plans, bool_stop_other_threads, new_plan_status);
542 stop_other_threads, new_plan_status,
546 true, abort_other_plans, bool_stop_other_threads, new_plan_status);
549 false, abort_other_plans, bool_stop_other_threads, new_plan_status);
552 true, abort_other_plans, bool_stop_other_threads, new_plan_status);
555 abort_other_plans,
nullptr,
false, bool_stop_other_threads,
eVoteYes,
574 new_plan_sp->SetIsControllingPlan(
true);
575 new_plan_sp->SetOkayToDiscard(
false);
580 "step operation does not support iteration count.");
590 if (synchronous_execution)
595 if (!
error.Success()) {
604 process->
SyncIOHandler(iohandler_id, std::chrono::seconds(2));
606 if (synchronous_execution) {
636 interpreter,
"thread continue",
637 "Continue execution of the current target process. One "
638 "or more threads may be specified, by default all "
641 eCommandRequiresThread | eCommandTryTargetAPILock |
642 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {
652 if (process ==
nullptr) {
653 result.
AppendError(
"no process exists. Cannot continue");
665 std::lock_guard<std::recursive_mutex> guard(
668 std::vector<Thread *> resume_threads;
669 for (
auto &entry : command.
entries()) {
671 if (entry.ref().getAsInteger(0, thread_idx)) {
673 "invalid thread index argument: \"%s\".\n", entry.c_str());
680 resume_threads.push_back(thread);
688 if (resume_threads.empty()) {
689 result.
AppendError(
"no valid thread indexes were specified");
692 if (resume_threads.size() == 1)
697 for (uint32_t idx = 0; idx < num_threads; ++idx) {
700 std::vector<Thread *>::iterator this_thread_pos =
701 find(resume_threads.begin(), resume_threads.end(), thread);
703 if (this_thread_pos != resume_threads.end()) {
704 resume_threads.erase(this_thread_pos);
705 if (!resume_threads.empty())
710 const bool override_suspend =
true;
723 std::lock_guard<std::recursive_mutex> guard(
727 if (current_thread ==
nullptr) {
728 result.
AppendError(
"the process doesn't have a current thread");
732 for (uint32_t idx = 0; idx < num_threads; ++idx) {
734 if (thread == current_thread) {
736 " in process %" PRIu64
"\n",
738 const bool override_suspend =
true;
748 if (synchronous_execution)
754 if (
error.Success()) {
757 if (synchronous_execution) {
774 "Process cannot be continued from its current state (%s).\n",
782#define LLDB_OPTIONS_thread_until
783#include "CommandOptions.inc"
805 switch (short_option) {
815 error.SetErrorStringWithFormat(
"invalid thread index '%s'",
816 option_arg.str().c_str());
822 error.SetErrorStringWithFormat(
"invalid frame index '%s'",
823 option_arg.str().c_str());
831 if (
error.Success()) {
839 llvm_unreachable(
"Unimplemented option");
852 return llvm::ArrayRef(g_thread_until_options);
864 interpreter,
"thread until",
865 "Continue until a line number or address is reached by the "
866 "current or specified thread. Stops when returning from "
867 "the current function as a safety measure. "
868 "The target line number(s) are given as arguments, and if more "
870 " is provided, stepping will stop when the first one is hit.",
872 eCommandRequiresThread | eCommandTryTargetAPILock |
873 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {
888 if (process ==
nullptr) {
889 result.
AppendError(
"need a valid process to step");
892 std::vector<uint32_t> line_numbers;
896 for (
size_t i = 0; i < num_args; i++) {
897 uint32_t line_number;
903 line_numbers.push_back(line_number);
919 if (thread ==
nullptr) {
922 "Thread index %u is out of range (valid values are 0 - %u).\n",
927 const bool abort_other_plans =
false;
931 if (frame ==
nullptr) {
933 "Frame index %u is out of range for thread id %" PRIu64
".\n",
949 if (line_table ==
nullptr) {
951 "frame %u of thread id %" PRIu64
".\n",
958 std::vector<addr_t> address_list;
964 "function info - can't get until range.");
977 bool all_in_function =
true;
986 for (uint32_t line_number : line_numbers) {
989 uint32_t start_idx_ptr = index_ptr;
991 index_ptr, line_number,
nullptr, exact, &line_entry);
993 line_number = line_entry.
line;
995 start_idx_ptr = index_ptr;
996 while (start_idx_ptr <= end_ptr) {
998 start_idx_ptr, line_number,
nullptr, exact, &line_entry);
1006 address_list.push_back(address);
1008 all_in_function =
false;
1016 address_list.push_back(address);
1018 all_in_function =
false;
1021 if (address_list.empty()) {
1022 if (all_in_function)
1024 "No line entries matching until target.\n");
1027 "Until target outside of the current function.\n");
1033 abort_other_plans, &address_list.front(), address_list.size(),
1041 new_plan_sp->SetIsControllingPlan(
true);
1042 new_plan_sp->SetOkayToDiscard(
false);
1049 " has no debug information.\n",
1056 "Failed to set the selected thread to thread id %" PRIu64
".\n",
1063 if (synchronous_execution)
1068 if (
error.Success()) {
1071 if (synchronous_execution) {
1094#define LLDB_OPTIONS_thread_select
1095#include "CommandOptions.inc"
1111 const int short_option = g_thread_select_options[option_idx].short_option;
1112 switch (short_option) {
1116 return Status(
"Invalid thread ID: '%s'.", option_arg.str().c_str());
1122 llvm_unreachable(
"Unimplemented option");
1129 return llvm::ArrayRef(g_thread_select_options);
1137 "Change the currently selected thread.",
1138 "thread select <thread-index> (or -t <thread-id>)",
1139 eCommandRequiresProcess | eCommandTryTargetAPILock |
1140 eCommandProcessMustBeLaunched |
1141 eCommandProcessMustBePaused) {
1152 arg.push_back(thread_idx_arg);
1179 if (process ==
nullptr) {
1185 "'%s' takes exactly one thread index argument, or a thread ID "
1186 "option:\nUsage: %s\n",
1192 "and a thread index argument:\nUsage: %s\n",
1197 Thread *new_thread =
nullptr;
1206 if (new_thread ==
nullptr) {
1214 if (new_thread ==
nullptr) {
1235 interpreter,
"thread list",
1236 "Show a summary of each thread in the current target process. "
1237 "Use 'settings set thread-format' to customize the individual "
1240 eCommandRequiresProcess | eCommandTryTargetAPILock |
1241 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {}
1250 const bool only_threads_with_stop_reason =
false;
1251 const uint32_t start_frame = 0;
1252 const uint32_t num_frames = 0;
1253 const uint32_t num_frames_with_source = 0;
1255 process->
GetThreadStatus(strm, only_threads_with_stop_reason, start_frame,
1256 num_frames, num_frames_with_source,
false);
1261#define LLDB_OPTIONS_thread_info
1262#include "CommandOptions.inc"
1282 switch (short_option) {
1292 llvm_unreachable(
"Unimplemented option");
1298 return llvm::ArrayRef(g_thread_info_options);
1307 interpreter,
"thread info",
1308 "Show an extended summary of one or "
1309 "more threads. Defaults to the "
1312 eCommandRequiresProcess | eCommandTryTargetAPILock |
1313 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {
1338 Thread *thread = thread_sp.get();
1360 interpreter,
"thread exception",
1361 "Display the current exception object for a thread. Defaults to "
1362 "the current thread.",
1364 eCommandRequiresProcess | eCommandTryTargetAPILock |
1365 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {}
1387 ValueObjectSP exception_object_sp = thread_sp->GetCurrentException();
1388 if (exception_object_sp) {
1389 exception_object_sp->Dump(strm);
1392 ThreadSP exception_thread_sp = thread_sp->GetCurrentExceptionBacktrace();
1393 if (exception_thread_sp && exception_thread_sp->IsValid()) {
1394 const uint32_t num_frames_with_source = 0;
1395 const bool stop_format =
false;
1396 exception_thread_sp->GetStatus(strm, 0,
UINT32_MAX,
1397 num_frames_with_source, stop_format);
1408 interpreter,
"thread siginfo",
1409 "Display the current siginfo object for a thread. Defaults to "
1410 "the current thread.",
1412 eCommandRequiresProcess | eCommandTryTargetAPILock |
1413 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {}
1437 thread_sp->GetIndexID());
1440 ValueObjectSP exception_object_sp = thread_sp->GetSiginfoValue();
1441 if (exception_object_sp)
1442 exception_object_sp->Dump(strm);
1444 strm.
Printf(
"(no siginfo)\n");
1452#define LLDB_OPTIONS_thread_return
1453#include "CommandOptions.inc"
1472 switch (short_option) {
1480 error.SetErrorStringWithFormat(
1481 "invalid boolean value '%s' for 'x' option",
1482 option_arg.str().c_str());
1486 llvm_unreachable(
"Unimplemented option");
1496 return llvm::ArrayRef(g_thread_return_options);
1506 "Prematurely return from a stack frame, "
1507 "short-circuiting execution of newer frames "
1508 "and optionally yielding a specified value. Defaults "
1509 "to the exiting the current stack "
1512 eCommandRequiresFrame | eCommandTryTargetAPILock |
1513 eCommandProcessMustBeLaunched |
1514 eCommandProcessMustBePaused) {
1528 if (command.starts_with(
"-x")) {
1529 if (command.size() != 2U)
1530 result.
AppendWarning(
"Return values ignored when returning from user "
1531 "called expressions");
1536 if (!
error.Success()) {
1548 "Could not select 0th frame after unwinding expression.");
1557 uint32_t frame_idx = frame_sp->GetFrameIndex();
1559 if (frame_sp->IsInlined()) {
1560 result.
AppendError(
"Don't know how to return from inlined frames.");
1564 if (!command.empty()) {
1573 return_valobj_sp, options);
1575 if (return_valobj_sp)
1577 "Error evaluating result expression: %s",
1578 return_valobj_sp->GetError().AsCString());
1581 "Unknown error evaluating result expression.");
1588 const bool broadcast =
true;
1589 error = thread_sp->ReturnFromFrame(frame_sp, return_valobj_sp, broadcast);
1590 if (!
error.Success()) {
1592 "Error returning from frame %d of thread %d: %s.", frame_idx,
1593 thread_sp->GetIndexID(),
error.AsCString());
1604#define LLDB_OPTIONS_thread_jump
1605#include "CommandOptions.inc"
1628 switch (short_option) {
1632 return Status(
"only one source file expected.");
1636 return Status(
"invalid line number: '%s'.", option_arg.str().c_str());
1640 return Status(
"invalid line offset: '%s'.", option_arg.str().c_str());
1650 llvm_unreachable(
"Unimplemented option");
1656 return llvm::ArrayRef(g_thread_jump_options);
1668 interpreter,
"thread jump",
1669 "Sets the program counter to a new address.",
"thread jump",
1670 eCommandRequiresFrame | eCommandTryTargetAPILock |
1671 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused) {}
1696 if (!reg_ctx->
SetPC(callAddr)) {
1714 "No source file available for the current location.");
1718 std::string warnings;
1726 if (!warnings.empty())
1739#define LLDB_OPTIONS_thread_plan_list
1740#include "CommandOptions.inc"
1758 switch (short_option) {
1764 if (option_arg.getAsInteger(0, tid))
1765 return Status(
"invalid tid: '%s'.", option_arg.str().c_str());
1775 llvm_unreachable(
"Unimplemented option");
1789 return llvm::ArrayRef(g_thread_plan_list_options);
1801 interpreter,
"thread plan list",
1802 "Show thread plans for one or more threads. If no threads are "
1803 "specified, show the "
1804 "current thread. Use the thread-index \"all\" to see all threads.",
1806 eCommandRequiresProcess | eCommandRequiresThread |
1807 eCommandTryTargetAPILock | eCommandProcessMustBeLaunched |
1808 eCommandProcessMustBePaused) {}
1875 "Discards thread plans up to and including the "
1876 "specified index (see 'thread plan list'.) "
1877 "Only user visible plans can be discarded.",
1879 eCommandRequiresProcess | eCommandRequiresThread |
1880 eCommandTryTargetAPILock |
1881 eCommandProcessMustBeLaunched |
1882 eCommandProcessMustBePaused) {
1901 "thread plan index - but got %zu.",
1906 uint32_t thread_plan_idx;
1909 "Invalid thread index: \"%s\" - should be unsigned int.",
1914 if (thread_plan_idx == 0) {
1916 "You wouldn't really want me to discard the base thread plan.");
1924 "Could not find User thread plan with index %s.",
1934 "Removes any thread plans associated with "
1935 "currently unreported threads. "
1936 "Specify one or more TID's to remove, or if no "
1937 "TID's are provides, remove threads for all "
1938 "unreported threads",
1940 eCommandRequiresProcess |
1941 eCommandTryTargetAPILock |
1942 eCommandProcessMustBeLaunched |
1943 eCommandProcessMustBePaused) {
1960 std::lock_guard<std::recursive_mutex> guard(
1963 for (
size_t i = 0; i < num_args; i++) {
1986 interpreter,
"plan",
1987 "Commands for managing thread plans that control execution.",
1988 "thread plan <subcommand> [<subcommand objects]") {
2010 interpreter,
"trace thread export",
2011 "Commands for exporting traces of the threads in the current "
2012 "process to different formats.",
2013 "thread trace export <export-plugin> [<subcommand objects>]") {
2016 for (llvm::StringRef plugin_name =
2018 !plugin_name.empty();
2034 true, interpreter,
"thread trace start",
2035 "Start tracing threads with the corresponding trace "
2036 "plug-in for the current process.",
2037 "thread trace start [<trace-options>]") {}
2051 interpreter,
"thread trace stop",
2052 "Stop tracing threads, including the ones traced with the "
2053 "\"process trace start\" command."
2054 "Defaults to the current thread. Thread indices can be "
2055 "specified as arguments.\n Use the thread-index \"all\" to stop "
2057 "for all existing threads.",
2058 "thread trace stop [<thread-index> <thread-index> ...]",
2059 eCommandRequiresProcess | eCommandTryTargetAPILock |
2060 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused |
2061 eCommandProcessMustBeTraced) {}
2066 llvm::ArrayRef<lldb::tid_t> tids)
override {
2069 TraceSP trace_sp = process_sp->GetTarget().GetTrace();
2071 if (llvm::Error err = trace_sp->Stop(tids))
2086 uint32_t thread_idx;
2088 if (!llvm::to_integer(arg, thread_idx)) {
2100#define LLDB_OPTIONS_thread_trace_dump_function_calls
2101#include "CommandOptions.inc"
2116 switch (short_option) {
2131 llvm_unreachable(
"Unimplemented option");
2142 return llvm::ArrayRef(g_thread_trace_dump_function_calls_options);
2154 interpreter,
"thread trace dump function-calls",
2155 "Dump the traced function-calls for one thread. If no "
2156 "thread is specified, the current thread is used.",
2158 eCommandRequiresProcess | eCommandRequiresThread |
2159 eCommandTryTargetAPILock | eCommandProcessMustBeLaunched |
2160 eCommandProcessMustBePaused | eCommandProcessMustBeTraced) {
2176 llvm::Expected<TraceCursorSP> cursor_or_error =
2179 if (!cursor_or_error) {
2180 result.
AppendError(llvm::toString(cursor_or_error.takeError()));
2185 std::optional<StreamFile> out_file;
2205#define LLDB_OPTIONS_thread_trace_dump_instructions
2206#include "CommandOptions.inc"
2221 switch (short_option) {
2224 if (option_arg.empty() || option_arg.getAsInteger(0, count) ||
2226 error.SetErrorStringWithFormat(
2227 "invalid integer value for option '%s'",
2228 option_arg.str().c_str());
2239 if (option_arg.empty() || option_arg.getAsInteger(0, skip) || skip < 0)
2240 error.SetErrorStringWithFormat(
2241 "invalid integer value for option '%s'",
2242 option_arg.str().c_str());
2249 if (option_arg.empty() || option_arg.getAsInteger(0,
id))
2250 error.SetErrorStringWithFormat(
2251 "invalid integer value for option '%s'",
2252 option_arg.str().c_str());
2300 llvm_unreachable(
"Unimplemented option");
2313 return llvm::ArrayRef(g_thread_trace_dump_instructions_options);
2327 interpreter,
"thread trace dump instructions",
2328 "Dump the traced instructions for one thread. If no "
2329 "thread is specified, show the current thread.",
2331 eCommandRequiresProcess | eCommandRequiresThread |
2332 eCommandTryTargetAPILock | eCommandProcessMustBeLaunched |
2333 eCommandProcessMustBePaused | eCommandProcessMustBeTraced) {
2342 uint32_t index)
override {
2345 if (cmd.find(
" --continue") == std::string::npos)
2346 cmd +=
" --continue";
2365 llvm::Expected<TraceCursorSP> cursor_or_error =
2368 if (!cursor_or_error) {
2369 result.
AppendError(llvm::toString(cursor_or_error.takeError()));
2380 std::optional<StreamFile> out_file;
2408#define LLDB_OPTIONS_thread_trace_dump_info
2409#include "CommandOptions.inc"
2424 switch (short_option) {
2434 llvm_unreachable(
"Unimplemented option");
2445 return llvm::ArrayRef(g_thread_trace_dump_info_options);
2455 interpreter,
"thread trace dump info",
2456 "Dump the traced information for one or more threads. If no "
2457 "threads are specified, show the current thread. Use the "
2458 "thread-index \"all\" to see all threads.",
2460 eCommandRequiresProcess | eCommandTryTargetAPILock |
2461 eCommandProcessMustBeLaunched | eCommandProcessMustBePaused |
2462 eCommandProcessMustBeTraced) {}
2486 interpreter,
"dump",
2487 "Commands for displaying trace information of the threads "
2488 "in the current process.",
2489 "thread trace dump <subcommand> [<subcommand objects>]") {
2507 interpreter,
"trace",
2508 "Commands for operating on traces of the threads in the current "
2510 "thread trace <subcommand> [<subcommand objects>]") {
2529 "Commands for operating on "
2530 "one or more threads in "
2531 "the current process.",
2532 "thread <subcommand> [<subcommand-options>]") {
2555 interpreter,
"thread step-in",
2556 "Source level single step, stepping into calls. Defaults "
2557 "to current thread unless specified.",
2562 interpreter,
"thread step-out",
2563 "Finish executing the current stack frame and stop after "
2564 "returning. Defaults to current thread unless specified.",
2569 interpreter,
"thread step-over",
2570 "Source level single step, stepping over calls. Defaults "
2571 "to current thread unless specified.",
2576 interpreter,
"thread step-inst",
2577 "Instruction level single step, stepping into calls. "
2578 "Defaults to current thread unless specified.",
2583 interpreter,
"thread step-inst-over",
2584 "Instruction level single step, stepping over calls. "
2585 "Defaults to current thread unless specified.",
2591 interpreter,
"thread step-scripted",
2592 "Step as instructed by the script class passed in the -C option. "
2593 "You can also specify a dictionary of key (-k) and value (-v) pairs "
2594 "that will be used to populate an SBStructuredData Dictionary, which "
2595 "will be passed to the constructor of the class implementing the "
2596 "scripted step. See the Python Reference for more details.",
static ThreadSP GetSingleThreadFromArgs(ExecutionContext &exe_ctx, Args &args, CommandReturnObject &result)
static llvm::raw_ostream & error(Stream &strm)
#define INTERRUPT_REQUESTED(debugger,...)
This handy define will keep you from having to generate a report for the interruption by hand.
~CommandObjectMultiwordThreadPlan() override=default
CommandObjectMultiwordThreadPlan(CommandInterpreter &interpreter)
~CommandObjectMultiwordTraceDump() override=default
CommandObjectMultiwordTraceDump(CommandInterpreter &interpreter)
CommandObjectMultiwordTrace(CommandInterpreter &interpreter)
~CommandObjectMultiwordTrace() override=default
~CommandOptions() override=default
void OptionParsingStarting(ExecutionContext *execution_context) override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
bool m_extended_backtrace
Options * GetOptions() override
CommandObjectThreadBacktrace(CommandInterpreter &interpreter)
std::optional< std::string > GetRepeatCommand(Args ¤t_args, uint32_t idx) override
Get the command that appropriate for a "repeat" of the current command.
void DoExtendedBacktrace(Thread *thread, CommandReturnObject &result)
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
~CommandObjectThreadBacktrace() override=default
~CommandObjectThreadContinue() override=default
void DoExecute(Args &command, CommandReturnObject &result) override
CommandObjectThreadContinue(CommandInterpreter &interpreter)
CommandObjectThreadException(CommandInterpreter &interpreter)
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
~CommandObjectThreadException() override=default
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
~CommandOptions() override=default
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
void OptionParsingStarting(ExecutionContext *execution_context) override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
CommandObjectThreadInfo(CommandInterpreter &interpreter)
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
~CommandObjectThreadInfo() override=default
Options * GetOptions() override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
void OptionParsingStarting(ExecutionContext *execution_context) override
~CommandOptions() override=default
CommandObjectThreadJump(CommandInterpreter &interpreter)
void DoExecute(Args &args, CommandReturnObject &result) override
~CommandObjectThreadJump() override=default
Options * GetOptions() override
void DoExecute(Args &command, CommandReturnObject &result) override
~CommandObjectThreadList() override=default
CommandObjectThreadList(CommandInterpreter &interpreter)
void DoExecute(Args &args, CommandReturnObject &result) override
CommandObjectThreadPlanDiscard(CommandInterpreter &interpreter)
~CommandObjectThreadPlanDiscard() override=default
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
~CommandOptions() override=default
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
std::vector< lldb::tid_t > m_tids
void OptionParsingStarting(ExecutionContext *execution_context) override
Options * GetOptions() override
CommandObjectThreadPlanList(CommandInterpreter &interpreter)
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
~CommandObjectThreadPlanList() override=default
void DoExecute(Args &command, CommandReturnObject &result) override
CommandObjectThreadPlanPrune(CommandInterpreter &interpreter)
~CommandObjectThreadPlanPrune() override=default
void DoExecute(Args &args, CommandReturnObject &result) override
~CommandOptions() override=default
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
void OptionParsingStarting(ExecutionContext *execution_context) override
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
Options * GetOptions() override
CommandObjectThreadReturn(CommandInterpreter &interpreter)
void DoExecute(llvm::StringRef command, CommandReturnObject &result) override
~CommandObjectThreadReturn() override=default
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
~OptionGroupThreadSelect() override=default
OptionGroupThreadSelect()
void OptionParsingStarting(ExecutionContext *execution_context) override
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
void DoExecute(Args &command, CommandReturnObject &result) override
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
OptionGroupOptions m_option_group
CommandObjectThreadSelect(CommandInterpreter &interpreter)
~CommandObjectThreadSelect() override=default
OptionGroupThreadSelect m_options
Options * GetOptions() override
~CommandObjectThreadSiginfo() override=default
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
CommandObjectThreadSiginfo(CommandInterpreter &interpreter)
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
OptionGroupPythonClassWithDict m_class_options
~CommandObjectThreadStepWithTypeAndScope() override=default
OptionGroupOptions m_all_options
Options * GetOptions() override
void DoExecute(Args &command, CommandReturnObject &result) override
ThreadStepScopeOptionGroup m_options
CommandObjectThreadStepWithTypeAndScope(CommandInterpreter &interpreter, const char *name, const char *help, const char *syntax, StepType step_type, StepScope step_scope)
void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector) override
The default version handles argument definitions that have only one argument type,...
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
uint32_t m_step_thread_idx
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
void OptionParsingStarting(ExecutionContext *execution_context) override
~CommandOptions() override=default
std::vector< lldb::addr_t > m_until_addrs
Options * GetOptions() override
CommandObjectThreadUntil(CommandInterpreter &interpreter)
~CommandObjectThreadUntil() override=default
void DoExecute(Args &command, CommandReturnObject &result) override
TraceDumperOptions m_dumper_options
~CommandOptions() override=default
static const size_t kDefaultCount
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
void OptionParsingStarting(ExecutionContext *execution_context) override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
std::optional< FileSpec > m_output_file
void DoExecute(Args &args, CommandReturnObject &result) override
CommandObjectTraceDumpFunctionCalls(CommandInterpreter &interpreter)
~CommandObjectTraceDumpFunctionCalls() override=default
Options * GetOptions() override
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
void OptionParsingStarting(ExecutionContext *execution_context) override
~CommandOptions() override=default
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
~CommandObjectTraceDumpInfo() override=default
Options * GetOptions() override
bool HandleOneThread(lldb::tid_t tid, CommandReturnObject &result) override
CommandObjectTraceDumpInfo(CommandInterpreter &interpreter)
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
std::optional< FileSpec > m_output_file
~CommandOptions() override=default
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
TraceDumperOptions m_dumper_options
static const size_t kDefaultCount
void OptionParsingStarting(ExecutionContext *execution_context) override
CommandObjectTraceDumpInstructions(CommandInterpreter &interpreter)
Options * GetOptions() override
~CommandObjectTraceDumpInstructions() override=default
std::optional< std::string > GetRepeatCommand(Args ¤t_command_args, uint32_t index) override
Get the command that appropriate for a "repeat" of the current command.
void DoExecute(Args &args, CommandReturnObject &result) override
std::optional< lldb::user_id_t > m_last_id
CommandObjectTraceExport(CommandInterpreter &interpreter)
lldb::CommandObjectSP GetDelegateCommand(Trace &trace) override
CommandObjectTraceStart(CommandInterpreter &interpreter)
~CommandObjectTraceStop() override=default
bool DoExecuteOnThreads(Args &command, CommandReturnObject &result, llvm::ArrayRef< lldb::tid_t > tids) override
CommandObjectTraceStop(CommandInterpreter &interpreter)
void OptionParsingStarting(ExecutionContext *execution_context) override
LazyBool m_step_in_avoid_no_debug
~ThreadStepScopeOptionGroup() override=default
std::string m_avoid_regexp
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
std::string m_step_in_target
bool m_end_line_is_block_end
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
LazyBool m_step_out_avoid_no_debug
ThreadStepScopeOptionGroup()
A section + offset based address range class.
Address & GetBaseAddress()
Get accessor for the base address of the range.
bool ContainsLoadAddress(const Address &so_addr, Target *target) const
Check if a section offset so_addr when represented as a load address is contained within this object'...
lldb::addr_t GetByteSize() const
Get accessor for the byte size of this range.
A section + offset based address class.
lldb::addr_t GetLoadAddress(Target *target) const
Get the load address.
lldb::addr_t GetCallableLoadAddress(Target *target, bool is_indirect=false) const
Get the load address as a callable code load address.
lldb::SectionSP GetSection() const
Get const accessor for the section.
lldb::addr_t GetFileAddress() const
Get the file address.
lldb::addr_t GetOffset() const
Get the section relative offset value.
bool IsValid() const
Check if the object state is valid.
A command line argument class.
size_t GetArgumentCount() const
Gets the number of arguments left in this command object.
void ReplaceArgumentAtIndex(size_t idx, llvm::StringRef arg_str, char quote_char='\0')
Replaces the argument value at index idx to arg_str if idx is a valid argument index.
void AppendArgument(llvm::StringRef arg_str, char quote_char='\0')
Appends a new argument to the end of the list argument list.
llvm::ArrayRef< ArgEntry > entries() const
const char * GetArgumentAtIndex(size_t idx) const
Gets the NULL terminated C string argument pointer for the argument at index idx.
bool GetCommandString(std::string &command) const
bool GetQuotedCommandString(std::string &command) const
A class that describes a single lexical block.
bool GetRangeContainingAddress(const Address &addr, AddressRange &range)
static bool InvokeCommonCompletionCallbacks(CommandInterpreter &interpreter, uint32_t completion_mask, lldb_private::CompletionRequest &request, SearchFilter *searcher)
void DoExecute(Args &command, CommandReturnObject &result) override
Class similar to CommandObjectIterateOverThreads, but which performs an action on multiple threads at...
CommandObjectMultiwordThread(CommandInterpreter &interpreter)
~CommandObjectMultiwordThread() override
bool LoadSubCommand(llvm::StringRef cmd_name, const lldb::CommandObjectSP &command_obj) override
This class works by delegating the logic to the actual trace plug-in that can support the current pro...
std::vector< CommandArgumentData > CommandArgumentEntry
void AddSimpleArgumentList(lldb::CommandArgumentType arg_type, ArgumentRepetitionType repetition_type=eArgRepeatPlain)
ExecutionContext m_exe_ctx
std::vector< CommandArgumentEntry > m_arguments
CommandInterpreter & GetCommandInterpreter()
Target & GetSelectedTarget()
CommandInterpreter & m_interpreter
Thread * GetDefaultThread()
virtual void HandleArgumentCompletion(CompletionRequest &request, OptionElementVector &opt_element_vector)
The default version handles argument definitions that have only one argument type,...
virtual llvm::StringRef GetSyntax()
void AppendMessage(llvm::StringRef in_string)
void void AppendError(llvm::StringRef in_string)
void SetStatus(lldb::ReturnStatus status)
void AppendErrorWithFormat(const char *format,...) __attribute__((format(printf
void AppendMessageWithFormat(const char *format,...) __attribute__((format(printf
void SetDidChangeProcessState(bool b)
void void AppendWarning(llvm::StringRef in_string)
void SetError(const Status &error, const char *fallback_error_cstr=nullptr)
Stream & GetOutputStream()
uint32_t FindLineEntry(uint32_t start_idx, uint32_t line, const FileSpec *file_spec_ptr, bool exact, LineEntry *line_entry)
Find the line entry by line and optional inlined file spec.
LineTable * GetLineTable()
Get the line table for the compile unit.
"lldb/Utility/ArgCompletionRequest.h"
size_t GetCursorIndex() const
void SetUnwindOnError(bool unwind=false)
void SetUseDynamic(lldb::DynamicValueType dynamic=lldb::eDynamicCanRunTarget)
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
void SetFrameSP(const lldb::StackFrameSP &frame_sp)
Set accessor to set only the frame shared pointer.
bool HasThreadScope() const
Returns true the ExecutionContext object contains a valid target, process, and thread.
const lldb::TargetSP & GetTargetSP() const
Get accessor to get the target shared pointer.
const lldb::ProcessSP & GetProcessSP() const
Get accessor to get the process shared pointer.
StackFrame * GetFramePtr() const
Returns a pointer to the frame object.
const lldb::StackFrameSP & GetFrameSP() const
Get accessor to get the frame shared pointer.
Process & GetProcessRef() const
Returns a reference to the process object.
Target * GetTargetPtr() const
Returns a pointer to the target object.
const lldb::ThreadSP & GetThreadSP() const
Get accessor to get the thread shared pointer.
Process * GetProcessPtr() const
Returns a pointer to the process object.
RegisterContext * GetRegisterContext() const
Thread * GetThreadPtr() const
Returns a pointer to the thread object.
const FileSpec & GetFileSpecAtIndex(size_t idx) const
Get file at index.
void Clear()
Clears the file list.
size_t GetSize() const
Get the number of files in the file list.
bool AppendIfUnique(const FileSpec &file)
Append a FileSpec object if unique.
const AddressRange & GetAddressRange()
bool FindLineEntryByAddress(const Address &so_addr, LineEntry &line_entry, uint32_t *index_ptr=nullptr)
Find a line entry that contains the section offset address so_addr.
void Append(OptionGroup *group)
Append options from a OptionGroup class.
const std::string & GetName()
const StructuredData::DictionarySP GetStructuredData()
A command line option parsing protocol class.
std::vector< Option > m_getopt_table
static llvm::StringRef GetTraceExporterPluginNameAtIndex(uint32_t index)
static ThreadTraceExportCommandCreator GetThreadTraceExportCommandCreatorAtIndex(uint32_t index)
Return the callback used to create the CommandObject that will be listed under "thread trace export".
A plug-in interface definition class for debugging a process.
lldb::pid_t GetID() const
Returns the pid of the process or LLDB_INVALID_PROCESS_ID if there is no known pid.
ThreadList & GetThreadList()
Status Resume()
Resumes all of a process's threads as configured using the Thread run control functions.
void PruneThreadPlans()
Prune ThreadPlanStacks for all unreported threads.
bool PruneThreadPlansForTID(lldb::tid_t tid)
Prune ThreadPlanStacks for unreported threads.
bool DumpThreadPlansForTID(Stream &strm, lldb::tid_t tid, lldb::DescriptionLevel desc_level, bool internal, bool condense_trivial, bool skip_unreported_plans)
Dump the thread plans associated with thread with tid.
Status ResumeSynchronous(Stream *stream)
Resume a process, and wait for it to stop.
size_t GetThreadStatus(Stream &ostrm, bool only_threads_with_stop_reason, uint32_t start_frame, uint32_t num_frames, uint32_t num_frames_with_source, bool stop_format)
lldb::StateType GetState()
Get accessor for the current process state.
void GetStatus(Stream &ostrm)
uint32_t GetIOHandlerID() const
void DumpThreadPlans(Stream &strm, lldb::DescriptionLevel desc_level, bool internal, bool condense_trivial, bool skip_unreported_plans)
Dump all the thread plans for this process.
void SyncIOHandler(uint32_t iohandler_id, const Timeout< std::micro > &timeout)
Waits for the process state to be running within a given msec timeout.
This base class provides an interface to stack frames.
const SymbolContext & GetSymbolContext(lldb::SymbolContextItem resolve_scope)
Provide a SymbolContext for this StackFrame's current pc value.
bool HasDebugInformation()
Determine whether this StackFrame has debug information available or not.
const Address & GetFrameCodeAddress()
Get an Address for the current pc value in this StackFrame.
bool Fail() const
Test for error condition.
llvm::StringRef GetString() const
A stream class that can stream formatted output to a file.
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
Defines a symbol context baton that can be handed other debug core functions.
Function * function
The Function for a given query.
Block * block
The Block for a given query.
CompileUnit * comp_unit
The CompileUnit for a given query.
LineEntry line_entry
The LineEntry for a given query.
bool GetAddressRangeFromHereToEndLine(uint32_t end_line, AddressRange &range, Status &error)
A plug-in interface definition class for system runtimes.
virtual lldb::ThreadSP GetExtendedBacktraceThread(lldb::ThreadSP thread, ConstString type)
Return a Thread which shows the origin of this thread's creation.
virtual const std::vector< ConstString > & GetExtendedBacktraceTypes()
Return a list of thread origin extended backtraces that may be available.
lldb::ExpressionResults EvaluateExpression(llvm::StringRef expression, ExecutionContextScope *exe_scope, lldb::ValueObjectSP &result_valobj_sp, const EvaluateExpressionOptions &options=EvaluateExpressionOptions(), std::string *fixed_expression=nullptr, ValueObject *ctx_obj=nullptr)
uint32_t GetSize(bool can_update=true)
bool SetSelectedThreadByID(lldb::tid_t tid, bool notify=false)
lldb::ThreadSP FindThreadByIndexID(uint32_t index_id, bool can_update=true)
lldb::ThreadSP GetThreadAtIndex(uint32_t idx, bool can_update=true)
std::recursive_mutex & GetMutex() const override
lldb::ThreadSP FindThreadByID(lldb::tid_t tid, bool can_update=true)
void SetAvoidRegexp(const char *name)
virtual lldb::ThreadPlanSP QueueThreadPlanForStepOut(bool abort_other_plans, SymbolContext *addr_context, bool first_insn, bool stop_other_threads, Vote report_stop_vote, Vote report_run_vote, uint32_t frame_idx, Status &status, LazyBool step_out_avoids_code_without_debug_info=eLazyBoolCalculate)
Queue the plan used to step out of the function at the current PC of thread.
Status UnwindInnermostExpression()
Unwinds the thread stack for the innermost expression plan currently on the thread plan stack.
virtual lldb::StackFrameSP GetStackFrameAtIndex(uint32_t idx)
virtual lldb::ThreadPlanSP QueueThreadPlanForStepUntil(bool abort_other_plans, lldb::addr_t *address_list, size_t num_addresses, bool stop_others, uint32_t frame_idx, Status &status)
void AutoCompleteThreadPlans(CompletionRequest &request) const
Format the thread plan information for auto completion.
uint32_t GetIndexID() const
bool GetDescription(Stream &s, lldb::DescriptionLevel level, bool print_json_thread, bool print_json_stopinfo)
void SetResumeState(lldb::StateType state, bool override_suspend=false)
Sets the USER resume state for this thread.
lldb::StackFrameSP GetSelectedFrame(SelectMostRelevant select_most_relevant)
bool DiscardUserThreadPlansUpToIndex(uint32_t thread_index)
Discards the plans queued on the plan stack of the current thread up to and including the plan in tha...
uint32_t GetSelectedFrameIndex(SelectMostRelevant select_most_relevant)
lldb::ProcessSP GetProcess() const
virtual lldb::ThreadPlanSP QueueThreadPlanForStepInRange(bool abort_other_plans, const AddressRange &range, const SymbolContext &addr_context, const char *step_in_target, lldb::RunMode stop_other_threads, Status &status, LazyBool step_in_avoids_code_without_debug_info=eLazyBoolCalculate, LazyBool step_out_avoids_code_without_debug_info=eLazyBoolCalculate)
Queues the plan used to step through an address range, stepping into functions.
virtual lldb::ThreadPlanSP QueueThreadPlanForStepScripted(bool abort_other_plans, const char *class_name, StructuredData::ObjectSP extra_args_sp, bool stop_other_threads, Status &status)
virtual lldb::ThreadPlanSP QueueThreadPlanForStepSingleInstruction(bool step_over, bool abort_other_plans, bool stop_other_threads, Status &status)
Queues the plan used to step one instruction from the current PC of thread.
Status JumpToLine(const FileSpec &file, uint32_t line, bool can_leave_function, std::string *warnings=nullptr)
virtual lldb::ThreadPlanSP QueueThreadPlanForStepOverRange(bool abort_other_plans, const AddressRange &range, const SymbolContext &addr_context, lldb::RunMode stop_other_threads, Status &status, LazyBool step_out_avoids_code_without_debug_info=eLazyBoolCalculate)
Queues the plan used to step through an address range, stepping over function calls.
size_t GetStatus(Stream &strm, uint32_t start_frame, uint32_t num_frames, uint32_t num_frames_with_source, bool stop_format, bool only_stacks=false)
bool SetSelectedFrameByIndexNoisily(uint32_t frame_idx, Stream &output_stream)
Class used to dump the instructions of a TraceCursor using its current state and granularity.
std::optional< lldb::user_id_t > DumpInstructions(size_t count)
Dump count instructions of the thread trace starting at the current cursor position.
void DumpFunctionCalls()
Dump all function calls forwards chronologically and hierarchically.
A plug-in interface definition class for trace information.
virtual lldb::CommandObjectSP GetThreadTraceStartCommand(CommandInterpreter &interpreter)=0
Get the command handle for the "thread trace start" command.
#define LLDB_INVALID_LINE_NUMBER
#define LLDB_INVALID_THREAD_ID
#define LLDB_INVALID_INDEX32
#define LLDB_INVALID_ADDRESS
#define LLDB_INVALID_FRAME_ID
@ DoNoSelectMostRelevantFrame
A class that represents a running process on the host machine.
std::vector< OptionArgElement > OptionElementVector
const char * StateAsCString(lldb::StateType state)
Converts a StateType to a C string.
const char * toString(AppleArm64ExceptionClass EC)
lldb::CommandObjectSP(* ThreadTraceExportCommandCreator)(CommandInterpreter &interpreter)
@ eStepTypeTraceOver
Single step one instruction, stepping over.
@ eStepTypeOut
Single step out a specified context.
@ eStepTypeScripted
A step type implemented by the script interpreter.
@ eStepTypeInto
Single step into a specified context.
@ eStepTypeOver
Single step over a specified context.
@ eStepTypeTrace
Single step one instruction.
std::shared_ptr< lldb_private::Trace > TraceSP
std::shared_ptr< lldb_private::ThreadPlan > ThreadPlanSP
std::shared_ptr< lldb_private::StackFrame > StackFrameSP
DescriptionLevel
Description levels for "void GetDescription(Stream *, DescriptionLevel)" calls.
@ eDescriptionLevelVerbose
std::shared_ptr< lldb_private::Thread > ThreadSP
std::shared_ptr< lldb_private::CommandObject > CommandObjectSP
std::shared_ptr< lldb_private::ValueObject > ValueObjectSP
StateType
Process and Thread States.
@ eStateStopped
Process or thread is stopped and can be examined.
@ eStateSuspended
Process or thread is in a suspended state as far as the debugger is concerned while other processes o...
@ eStateRunning
Process or thread is running and can't be examined.
@ eStateCrashed
Process or thread has crashed and can be examined.
ExpressionResults
The results of expression evaluation.
std::shared_ptr< lldb_private::Process > ProcessSP
@ eReturnStatusSuccessContinuingNoResult
@ eReturnStatusSuccessFinishResult
@ eReturnStatusSuccessFinishNoResult
@ eArgTypeUnsignedInteger
@ eTraceCursorSeekTypeEnd
The end of the trace, i.e the most recent item.
std::shared_ptr< lldb_private::TraceCursor > TraceCursorSP
std::shared_ptr< lldb_private::Target > TargetSP
Used to build individual command argument lists.
ArgumentRepetitionType arg_repetition
lldb::CommandArgumentType arg_type
uint32_t arg_opt_set_association
This arg might be associated only with some particular option set(s).
A line table entry class.
AddressRange range
The section offset address range for this line entry.
uint32_t line
The source line number, or LLDB_INVALID_LINE_NUMBER if there is no line number information.
lldb::SupportFileSP file_sp
The source file, possibly mapped by the target.source-map setting.
static int64_t ToOptionEnum(llvm::StringRef s, const OptionEnumValues &enum_values, int32_t fail_value, Status &error)
static lldb::addr_t ToAddress(const ExecutionContext *exe_ctx, llvm::StringRef s, lldb::addr_t fail_value, Status *error_ptr)
Try to parse an address.
static bool ToBoolean(llvm::StringRef s, bool fail_value, bool *success_ptr)
Class that holds the configuration used by TraceDumper for traversing and dumping instructions.
bool show_control_flow_kind
For each instruction, print the instruction kind.
bool only_events
Dump events and none of the instructions.
bool show_timestamps
For each trace item, print the corresponding timestamp in nanoseconds if available.
std::optional< uint64_t > id
Optional custom id to start traversing from.
bool pretty_print_json
When dumping in JSON format, pretty print the output.
std::optional< size_t > skip
Optional number of instructions to skip from the starting position of the cursor.
bool json
Dump in json format.
bool show_events
Dump the events that happened between instructions.
bool raw
Dump only instruction addresses without disassembly nor symbol information.
bool forwards
If true, the cursor will be iterated forwards starting from the oldest instruction.
lldb::user_id_t GetID() const
Get accessor for the user ID.