Go to the documentation of this file.
9 #ifndef LLDB_HOST_HOST_H
10 #define LLDB_HOST_HOST_H
24 #include <type_traits>
29 class ProcessLaunchInfo;
30 class ProcessInstanceInfo;
86 static llvm::Expected<HostThread>
160 typedef std::map<lldb::pid_t, bool>
TidMap;
187 const FileSpec &working_dir,
int *status_ptr,
190 bool run_in_shell =
true,
191 bool hide_stderr =
false);
203 const FileSpec &working_dir,
int *status_ptr,
206 bool run_in_shell =
true,
207 bool hide_stderr =
false);
217 int *status_ptr,
int *signo_ptr,
220 bool run_in_shell =
true,
221 bool hide_stderr =
false);
233 const FileSpec &working_dir,
int *status_ptr,
236 bool run_in_shell =
true,
237 bool hide_stderr =
false);
251 static std::unique_ptr<Connection>
265 bool isA(
const void *ClassID)
const override {
return ClassID == &
ID; }
279 llvm::StringRef Options);
283 #endif // LLDB_HOST_HOST_H
static bool ResolveExecutableInBundle(FileSpec &file)
When executable files may live within a directory, where the directory represents an executable bundl...
static uint32_t FindProcesses(const ProcessInstanceInfoMatch &match_info, ProcessInstanceInfoList &proc_infos)
static Status LaunchProcess(ProcessLaunchInfo &launch_info)
Launch the process specified in launch_info.
static std::unique_ptr< Connection > CreateDefaultConnection(llvm::StringRef url)
static bool GetBundleDirectory(const FileSpec &file, FileSpec &bundle_directory)
If you have an executable that is in a bundle and want to get back to the bundle directory from the p...
static void SystemLog(llvm::StringRef message)
Emit the given message to the operating system log.
static const char * GetSignalAsCString(int signo)
static WaitStatus Decode(int wstatus)
static bool classof(const LogHandler *obj)
bool operator==(const Address &lhs, const Address &rhs)
std::function< void(lldb::pid_t pid, int signal, int status)> MonitorChildProcessCallback
static Status RunShellCommand(llvm::StringRef command, const FileSpec &working_dir, int *status_ptr, int *signo_ptr, std::string *command_output, const Timeout< std::micro > &timeout, bool run_in_shell=true, bool hide_stderr=false)
Run a shell command.
void Emit(llvm::StringRef message) override
static bool IsInteractiveGraphicSession()
Check if we're running in an interactive graphical session.
bool isA(const void *ClassID) const override
virtual bool isA(const void *ClassID) const
static uint32_t FindProcessesImpl(const ProcessInstanceInfoMatch &match_info, ProcessInstanceInfoList &proc_infos)
std::pair< lldb::pid_t, bool > TidPair
string(SUBSTRING ${p} 10 -1 pStripped) if($
static Status ShellExpandArguments(ProcessLaunchInfo &launch_info)
Perform expansion of the command-line for this launch info This can potentially involve wildcard expa...
static llvm::Expected< HostThread > StartMonitoringChildProcess(const MonitorChildProcessCallback &callback, lldb::pid_t pid)
Start monitoring a child process.
static lldb::thread_t GetCurrentThread()
Get the thread token (the one returned by ThreadCreate when the thread was created) for the calling t...
bool operator!=(const Address &lhs, const Address &rhs)
static Environment GetEnvironment()
Log handler that emits log messages to the operating system log.
message(FATAL_ERROR "invalid libipt include path provided") endif() include_directories($
static bool GetProcessInfo(lldb::pid_t pid, ProcessInstanceInfo &proc_info)
static lldb::pid_t GetCurrentProcessID()
Get the process ID for the calling process.
WaitStatus(Type type, uint8_t status)
A class that represents a running process on the host machine.
static bool OpenFileInExternalEditor(const FileSpec &file_spec, uint32_t line_no)
static FileSpec GetModuleFileSpecForHostAddress(const void *host_addr)
Given an address in the current process (the process that is running the LLDB code),...
static bool FindProcessThreads(const lldb::pid_t pid, TidMap &tids_to_attach)
static void Kill(lldb::pid_t pid, int signo)
std::vector< ProcessInstanceInfo > ProcessInstanceInfoList
std::map< lldb::pid_t, bool > TidMap