9#ifndef lldb_NativeRegisterContextLinux_h
10#define lldb_NativeRegisterContextLinux_h
15#include "llvm/Support/Error.h"
19namespace process_linux {
21class NativeThreadLinux;
33 static std::unique_ptr<NativeRegisterContextLinux>
47 llvm::ArrayRef<uint8_t>
Insn;
51 llvm::ArrayRef<uint32_t>
Args;
67 virtual std::optional<MmapData>
GetMmapData() {
return std::nullopt; }
72 std::unique_ptr<MemoryTagManager>
manager;
78 virtual llvm::Expected<MemoryTaggingDetails>
80 return llvm::createStringError(
81 llvm::inconvertibleErrorCode(),
82 "Architecture does not support memory tagging");
100 unsigned int regset);
103 unsigned int regset);
138 static llvm::Expected<ArchSpec>
An architecture specification class.
const RegisterInfoInterface & GetRegisterInfoInterface() const
const RegisterInfo * GetRegisterInfoAtIndex(uint32_t reg_index) const override
virtual size_t GetGPRSize() const =0
virtual Status ReadRegisterSet(void *buf, size_t buf_size, unsigned int regset)
lldb::ByteOrder GetByteOrder() const
virtual llvm::Expected< MemoryTaggingDetails > GetMemoryTaggingDetails(int32_t type)
Return architecture specific data needed to use memory tags, if they are supported.
virtual Status WriteRegisterRaw(uint32_t reg_index, const RegisterValue ®_value)
virtual Status WriteRegisterSet(void *buf, size_t buf_size, unsigned int regset)
virtual Status ReadRegisterRaw(uint32_t reg_index, RegisterValue ®_value)
virtual void InvalidateAllRegisters()
virtual Status WriteFPR()
static std::unique_ptr< NativeRegisterContextLinux > CreateHostNativeRegisterContextLinux(const ArchSpec &target_arch, NativeThreadLinux &native_thread)
virtual uint32_t GetPtraceOffset(uint32_t reg_index)
NativeRegisterContextLinux(NativeThreadProtocol &thread)
virtual Status DoReadRegisterValue(uint32_t offset, const char *reg_name, uint32_t size, RegisterValue &value)
virtual size_t GetFPRSize()=0
virtual std::optional< MmapData > GetMmapData()
Return the architecture-specific data needed to make mmap syscalls, if they are supported.
static llvm::Expected< ArchSpec > DetermineArchitectureViaGPR(lldb::tid_t tid, size_t gpr64_size)
virtual Status WriteGPR()
static llvm::Expected< ArchSpec > DetermineArchitecture(lldb::tid_t tid)
virtual size_t GetGPRSize() const
virtual std::optional< SyscallData > GetSyscallData()
Return architecture-specific data needed to make inferior syscalls, if they are supported.
virtual Status DoWriteRegisterValue(uint32_t offset, const char *reg_name, const RegisterValue &value)
virtual void * GetGPRBuffer()=0
virtual void * GetFPRBuffer()=0
A class that represents a running process on the host machine.
ByteOrder
Byte ordering definitions.
uint32_t byte_offset
The byte offset in the register context data where this register's value is found.
int ptrace_write_req
ptrace operation number for memory tag read
std::unique_ptr< MemoryTagManager > manager
Object with tag handling utilities.
unsigned SysMmap
mmap syscall number.
unsigned SysMunmap
munmap syscall number
llvm::ArrayRef< uint8_t > Insn
The syscall instruction.
uint32_t Result
Register containing the syscall result.
llvm::ArrayRef< uint32_t > Args
Registers used for syscall arguments.