9#ifndef LLDB_SOURCE_PLUGINS_TRACE_INTEL_PT_COMMANDOBJECTTRACESTARTINTELPT_H
10#define LLDB_SOURCE_PLUGINS_TRACE_INTEL_PT_COMMANDOBJECTTRACESTARTINTELPT_H
12#include "../../../../source/Commands/CommandObjectTrace.h"
19namespace trace_intel_pt {
43 interpreter,
"thread trace start",
44 "Start tracing one or more threads with intel-pt. "
45 "Defaults to the current thread. Thread indices can be "
46 "specified as arguments.\n Use the thread-index \"all\" to trace "
47 "all threads including future threads.",
48 "thread trace start [<thread-index> <thread-index> ...] "
49 "[<intel-pt-options>]",
50 lldb::eCommandRequiresProcess |
lldb::eCommandTryTargetAPILock |
51 lldb::eCommandProcessMustBeLaunched |
52 lldb::eCommandProcessMustBePaused),
59 llvm::ArrayRef<lldb::tid_t> tids)
override;
89 interpreter,
"process trace start",
90 "Start tracing this process with intel-pt, including future "
91 "threads. If --per-cpu-tracing is not provided, this traces each "
92 "thread independently, thus using a trace buffer per thread. "
93 "Threads traced with the \"thread trace start\" command are left "
94 "unaffected ant not retraced. This is the recommended option "
95 "unless the number of threads is huge. If --per-cpu-tracing is "
96 "passed, each cpu core is traced instead of each thread, which "
97 "uses a fixed number of trace buffers, but might result in less "
98 "data available for less frequent threads.",
99 "process trace start [<intel-pt-options>]",
100 lldb::eCommandRequiresProcess |
lldb::eCommandTryTargetAPILock |
101 lldb::eCommandProcessMustBeLaunched |
102 lldb::eCommandProcessMustBePaused),
114namespace ParsingUtils {
127std::optional<uint64_t>
A command line argument class.
Class similar to CommandObjectIterateOverThreads, but which performs an action on multiple threads at...
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
A command line option parsing protocol class.
llvm::ArrayRef< OptionDefinition > GetDefinitions() override
bool m_disable_cgroup_filtering
Status SetOptionValue(uint32_t option_idx, llvm::StringRef option_arg, ExecutionContext *execution_context) override
Set the value of an option.
uint64_t m_process_buffer_size_limit
void OptionParsingStarting(ExecutionContext *execution_context) override
std::optional< uint64_t > m_psb_period
uint64_t m_ipt_trace_size
Options * GetOptions() override
void DoExecute(Args &command, CommandReturnObject &result) override
CommandObjectProcessTraceStartIntelPT(TraceIntelPT &trace, CommandInterpreter &interpreter)
std::optional< uint64_t > m_psb_period
uint64_t m_ipt_trace_size
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.
void OptionParsingStarting(ExecutionContext *execution_context) override
CommandObjectThreadTraceStartIntelPT(TraceIntelPT &trace, CommandInterpreter &interpreter)
Options * GetOptions() override
bool DoExecuteOnThreads(Args &command, CommandReturnObject &result, llvm::ArrayRef< lldb::tid_t > tids) override
Method that handles the command after the main arguments have been parsed.
std::optional< uint64_t > ParseUserFriendlySizeExpression(llvm::StringRef size_expression)
Convert an integral size expression like 12KiB or 4MB into bytes.
A class that represents a running process on the host machine.