LLDB mainline
|
An architecture specification class. More...
#include "lldb/Utility/ArchSpec.h"
Public Member Functions | |
ArchSpec () | |
Default constructor. | |
ArchSpec (const llvm::Triple &triple) | |
Constructor over triple. | |
ArchSpec (const char *triple_cstr) | |
ArchSpec (llvm::StringRef triple_str) | |
ArchSpec (ArchitectureType arch_type, uint32_t cpu_type, uint32_t cpu_subtype) | |
Constructor over architecture name. | |
~ArchSpec () | |
Destructor. | |
const char * | GetArchitectureName () const |
Returns a static string representing the current architecture. | |
bool | IsMIPS () const |
if MIPS architecture return true. | |
std::string | GetClangTargetCPU () const |
Returns a string representing current architecture as a target CPU for tools like compiler, disassembler etc. | |
std::string | GetTargetABI () const |
Return a string representing target application ABI. | |
void | Clear () |
Clears the object state. | |
uint32_t | GetAddressByteSize () const |
Returns the size in bytes of an address of the current architecture. | |
llvm::Triple::ArchType | GetMachine () const |
Returns a machine family for the current architecture. | |
bool | IsValid () const |
Tests if this ArchSpec is valid. | |
operator bool () const | |
bool | TripleVendorWasSpecified () const |
bool | TripleOSWasSpecified () const |
bool | TripleEnvironmentWasSpecified () const |
void | MergeFrom (const ArchSpec &other) |
Merges fields from another ArchSpec into this ArchSpec. | |
bool | SetArchitecture (ArchitectureType arch_type, uint32_t cpu, uint32_t sub, uint32_t os=0) |
Change the architecture object type, CPU type and OS type. | |
lldb::ByteOrder | GetByteOrder () const |
Returns the byte order for the architecture specification. | |
void | SetByteOrder (lldb::ByteOrder byte_order) |
Sets this ArchSpec's byte order. | |
uint32_t | GetMinimumOpcodeByteSize () const |
uint32_t | GetMaximumOpcodeByteSize () const |
Core | GetCore () const |
uint32_t | GetMachOCPUType () const |
uint32_t | GetMachOCPUSubType () const |
uint32_t | GetDataByteSize () const |
Architecture data byte width accessor. | |
uint32_t | GetCodeByteSize () const |
Architecture code byte width accessor. | |
llvm::Triple & | GetTriple () |
Architecture triple accessor. | |
const llvm::Triple & | GetTriple () const |
Architecture triple accessor. | |
void | DumpTriple (llvm::raw_ostream &s) const |
bool | SetTriple (const llvm::Triple &triple) |
Architecture triple setter. | |
bool | SetTriple (llvm::StringRef triple_str) |
lldb::ByteOrder | GetDefaultEndian () const |
Returns the default endianness of the architecture. | |
bool | CharIsSignedByDefault () const |
Returns true if 'char' is a signed type by default in the architecture false otherwise. | |
bool | IsMatch (const ArchSpec &rhs, MatchType match) const |
Compare this ArchSpec to another ArchSpec. | |
bool | IsExactMatch (const ArchSpec &rhs) const |
Shorthand for IsMatch(rhs, ExactMatch). | |
bool | IsCompatibleMatch (const ArchSpec &rhs) const |
Shorthand for IsMatch(rhs, CompatibleMatch). | |
bool | IsFullySpecifiedTriple () const |
bool | IsAlwaysThumbInstructions () const |
Detect whether this architecture uses thumb code exclusively. | |
uint32_t | GetFlags () const |
void | SetFlags (uint32_t flags) |
void | SetFlags (const std::string &elf_abi) |
Static Public Member Functions | |
static bool | ContainsOnlyArch (const llvm::Triple &normalized_triple) |
Returns true if the OS, vendor and environment fields of the triple are unset. | |
static void | ListSupportedArchNames (StringList &list) |
static void | AutoComplete (CompletionRequest &request) |
Protected Member Functions | |
void | UpdateCore () |
void | CoreUpdated (bool update_triple) |
Protected Attributes | |
llvm::Triple | m_triple |
Core | m_core = kCore_invalid |
lldb::ByteOrder | m_byte_order = lldb::eByteOrderInvalid |
uint32_t | m_flags = 0 |
An architecture specification class.
A class designed to be created from a cpu type and subtype, a string representation, or an llvm::Triple. Keeping all of the conversions of strings to architecture enumeration values confined to this class allows new architecture support to be added easily.
Definition at line 31 of file ArchSpec.h.
Enumerator | |
---|---|
eARM_abi_soft_float | |
eARM_abi_hard_float |
Definition at line 88 of file ArchSpec.h.
Definition at line 116 of file ArchSpec.h.
Enumerator | |
---|---|
eLoongArchSubType_unknown | |
eLoongArchSubType_loongarch32 | |
eLoongArchSubType_loongarch64 |
Definition at line 110 of file ArchSpec.h.
enum lldb_private::ArchSpec::MatchType : bool |
Enumerator | |
---|---|
CompatibleMatch | |
ExactMatch |
Definition at line 486 of file ArchSpec.h.
Enumerator | |
---|---|
eMIPS_ABI_FP_ANY | |
eMIPS_ABI_FP_DOUBLE | |
eMIPS_ABI_FP_SINGLE | |
eMIPS_ABI_FP_SOFT | |
eMIPS_ABI_FP_OLD_64 | |
eMIPS_ABI_FP_XX | |
eMIPS_ABI_FP_64 | |
eMIPS_ABI_FP_64A | |
eMIPS_ABI_FP_mask |
Definition at line 75 of file ArchSpec.h.
Definition at line 50 of file ArchSpec.h.
Definition at line 33 of file ArchSpec.h.
Definition at line 93 of file ArchSpec.h.
Enumerator | |
---|---|
eRISCVSubType_unknown | |
eRISCVSubType_riscv32 | |
eRISCVSubType_riscv64 |
Definition at line 104 of file ArchSpec.h.
|
default |
Default constructor.
Default constructor that initializes the object with invalid cpu type and subtype values.
|
explicit |
Constructor over triple.
Constructs an ArchSpec with properties consistent with the given Triple.
Definition at line 534 of file ArchSpec.cpp.
References SetTriple().
|
explicit |
Definition at line 527 of file ArchSpec.cpp.
References SetTriple().
|
explicit |
Definition at line 532 of file ArchSpec.cpp.
References SetTriple().
|
explicit |
Constructor over architecture name.
Constructs an ArchSpec with properties consistent with the given object type and architecture name.
Definition at line 536 of file ArchSpec.cpp.
References SetArchitecture().
|
default |
Destructor.
|
static |
Definition at line 272 of file ArchSpec.cpp.
References g_core_definitions, and lldb_private::CompletionRequest::TryCompleteCurrentArg().
Referenced by lldb_private::CommandCompletions::ArchitectureNames().
bool ArchSpec::CharIsSignedByDefault | ( | ) | const |
Returns true if 'char' is a signed type by default in the architecture false otherwise.
Definition at line 712 of file ArchSpec.cpp.
References m_triple.
Referenced by ParseLangArgs(), and SetupLangOpts().
void ArchSpec::Clear | ( | ) |
Clears the object state.
Clears the object state back to a default invalid state.
Definition at line 542 of file ArchSpec.cpp.
References lldb::eByteOrderInvalid, kCore_invalid, m_byte_order, m_core, m_flags, and m_triple.
Referenced by lldb_private::ModuleSpec::Clear(), lldb_private::ProcessInfo::Clear(), lldb_private::HostInfoBase::ComputeHostArchitectureSupport(), lldb_private::HostInfoMacOSX::ComputeHostArchitectureSupport(), lldb_private::Process::DidAttach(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidAttach(), GetFreeBSDProcessCPUType(), ProcessKDP::GetHostArchitecture(), GetMacOSXProcessCPUType(), GetNetBSDProcessCPUType(), GetOpenBSDProcessCPUType(), lldb_private::PlatformList::GetOrCreate(), lldb_private::Platform::IsCompatibleArchitecture(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::ResetDiscoverableSettings(), SetTriple(), and UpdateCore().
|
static |
Returns true if the OS, vendor and environment fields of the triple are unset.
The triple is expected to be normalized (llvm::Triple::normalize).
Definition at line 802 of file ArchSpec.cpp.
Referenced by lldb_private::HostInfoBase::GetAugmentedArchSpec(), and lldb_private::Platform::GetAugmentedArchSpec().
|
protected |
Definition at line 1066 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::default_byte_order, lldb::eByteOrderInvalid, FindCoreDefinition(), m_byte_order, m_core, m_triple, and lldb_private::CoreDefinition::name.
Referenced by MergeFrom(), and SetArchitecture().
void ArchSpec::DumpTriple | ( | llvm::raw_ostream & | s | ) | const |
Definition at line 1451 of file ArchSpec.cpp.
References GetTriple().
Referenced by lldb_private::TargetList::CreateTargetInternal(), lldb_private::ProcessInfo::Dump(), lldb_private::ProcessInstanceInfo::Dump(), lldb_private::ModuleSpec::Dump(), lldb_private::ProcessInstanceInfo::DumpAsTableRow(), DumpModuleArchitecture(), DumpTargetInfo(), and lldb_private::Platform::GetStatus().
uint32_t ArchSpec::GetAddressByteSize | ( | ) | const |
Returns the size in bytes of an address of the current architecture.
Definition at line 691 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::addr_byte_size, eMIPSABI_N32, eMIPSABI_O32, FindCoreDefinition(), m_core, m_flags, and lldb_private::CoreDefinition::machine.
Referenced by lldb_private::WatchpointAlgorithms::AtomizeWatchpointRequest(), ConvertPDBLocationToDWARFExpression(), CreateDWARFExpression(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), lldb_private::formatters::CXXFunctionPointerSummaryProvider(), lldb_private::Disassembler::DisassembleBytes(), lldb_private::IRExecutionUnit::DisassembleFunction(), CommandObjectMemoryRead::DoExecute(), CommandObjectMemoryWrite::DoExecute(), CommandObjectSourceInfo::DoExecute(), CommandObjectTargetModulesDumpObjfile::DoExecute(), CommandObjectTargetModulesDumpSymtab::DoExecute(), CommandObjectTargetModulesDumpSections::DoExecute(), CommandObjectTargetModulesDumpSymfile::DoExecute(), CommandObjectTargetModulesDumpLineTable::DoExecute(), CommandObjectTargetModulesDumpSeparateDebugInfoFiles::DoExecute(), CommandObjectTargetModulesList::DoExecute(), CommandObjectTargetModulesLookup::DoExecute(), DynamicLoaderMacOSXDYLD::DoInitialImageFetch(), lldb_private::Address::Dump(), lldb_private::AddressRange::Dump(), lldb_private::StackFrame::Dump(), DumpAddressAndContent(), CommandObjectSourceInfo::DumpLinesInFunctions(), OptionGroupReadMemory::FinalizeSettings(), lldb_private::EmulateInstruction::GetAddressByteSize(), lldb_private::NativeProcessProtocol::GetAddressByteSize(), lldb_private::Process::GetAddressByteSize(), lldb_private::breakpad::ObjectFileBreakpad::GetAddressByteSize(), ObjectFileCOFF::GetAddressByteSize(), lldb_private::ObjectFileJSON::GetAddressByteSize(), ObjectFilePlaceholder::GetAddressByteSize(), lldb_private::wasm::ObjectFileWasm::GetAddressByteSize(), GetByteOrderAndAddrSize(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), UnwindAssemblyInstEmulation::GetNonCallSiteUnwindPlanFromAssembly(), DynamicLoaderMacOS::GetNotificationFuncAddrFromImageInfos(), ABISysV_mips::GetReturnValueObjectImpl(), ABISysV_mips64::GetReturnValueObjectImpl(), ABISysV_ppc::GetReturnValueObjectImpl(), ABISysV_x86_64::GetReturnValueObjectImpl(), ABIWindows_x86_64::GetReturnValueObjectImpl(), lldb_private::Thread::GetSiginfoValue(), ELFLinuxPrStatus::GetSize(), ELFLinuxPrPsInfo::GetSize(), lldb_private::ClangExpressionDeclMap::GetTargetInfo(), lldb_private::Value::GetValueAsData(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), MakeLocationExpressionInternal(), DynamicLoaderMacOS::NotifyBreakpointHit(), lldb_private::Disassembler::ParseInstructions(), CommandObjectTargetModulesList::PrintModule(), DynamicLoaderMacOSXDYLD::ReadAllImageInfosStructure(), JITLoaderGDB::ReadJITDescriptor(), lldb_private::Target::ReadPointerFromMemory(), lldb_private::Target::ReadScalarIntegerFromMemory(), lldb_private::HostInfoAndroid::ResolveLibraryPath(), lldb_private::breakpad::SymbolFileBreakpad::SaveAsDWARF(), ObjectFileMachO::SaveCore(), DynamicLoaderDarwinKernel::SearchForKernelNearPC(), DynamicLoaderDarwinKernel::SearchForKernelViaExhaustiveSearch(), CommunicationKDP::SendRequestHostInfo(), lldb_private::process_linux::NativeProcessLinux::Syscall(), lldb_private::ValueObjectDynamicValue::UpdateValue(), lldb_private::ValueObjectMemory::UpdateValue(), lldb_private::ValueObjectVariable::UpdateValue(), lldb_private::ValueObject::ValueObject(), lldb_private::Watchpoint::Watchpoint(), and UnwindAssemblyInstEmulation::WriteMemory().
const char * ArchSpec::GetArchitectureName | ( | ) | const |
Returns a static string representing the current architecture.
Definition at line 552 of file ArchSpec.cpp.
References FindCoreDefinition(), m_core, and lldb_private::CoreDefinition::name.
Referenced by lldb_private::platform_android::PlatformAndroid::CreateInstance(), lldb_private::PlatformRemoteAppleBridge::CreateInstance(), lldb_private::PlatformRemoteAppleWatch::CreateInstance(), lldb_private::PlatformRemoteiOS::CreateInstance(), lldb_private::PlatformRemoteMacOSX::CreateInstance(), lldb_private::PlatformRemoteAppleTV::CreateInstance(), lldb_private::PlatformRemoteAppleXR::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), lldb_private::TargetList::CreateTargetInternal(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidLaunchOrAttach(), lldb_private::IRExecutionUnit::DisassembleFunction(), lldb_private::CommandObjectDisassemble::DoExecute(), lldb_private::minidump::ProcessMinidump::DoLoadCore(), ObjectFileELF::Dump(), ObjectFilePECOFF::Dump(), ObjectFileCOFF::Dump(), lldb_private::plugin::dwarf::ManualDWARFIndex::Dump(), lldb_private::wasm::ObjectFileWasm::Dump(), DumpModuleArchitecture(), DumpModuleSections(), lldb_private::OptionValueArch::DumpValue(), lldb_private::Disassembler::FindPlugin(), lldb_private::FormatEntity::Format(), lldb_private::DynamicLoaderDarwin::ImageInfo::GetArchitecture(), lldb::SBDebugger::GetDefaultArchitecture(), lldb_private::Module::GetDescription(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), ObjectFileELF::GetModuleSpecifications(), lldb_private::ModuleList::GetSharedModule(), lldb_private::SymbolLocatorDefault::LocateExecutableObjectFile(), lldb_private::SymbolLocatorDebugSymbols::LocateExecutableSymbolFile(), lldb_private::ModuleList::LogUUIDAndPaths(), lldb_private::Module::Module(), lldb_private::EmulateInstructionARM::SetArchitecture(), lldb_private::Target::SetArchitecture(), lldb_private::Target::SetDefaultArchitecture(), lldb_private::Target::SetExecutableModule(), lldb_private::Target::Target(), and lldb_private::Module::~Module().
lldb::ByteOrder ArchSpec::GetByteOrder | ( | ) | const |
Returns the byte order for the architecture specification.
Definition at line 738 of file ArchSpec.cpp.
References lldb::eByteOrderInvalid, GetDefaultEndian(), and m_byte_order.
Referenced by ConvertPDBLocationToDWARFExpression(), CreateDWARFExpression(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), lldb_private::Disassembler::DisassembleBytes(), CommandObjectMemoryRead::DoExecute(), CommandObjectMemoryWrite::DoExecute(), DynamicLoaderMacOSXDYLD::DoInitialImageFetch(), lldb_private::EmulateInstruction::GetByteOrder(), lldb_private::NativeProcessProtocol::GetByteOrder(), lldb_private::Process::GetByteOrder(), lldb_private::breakpad::ObjectFileBreakpad::GetByteOrder(), lldb_private::ObjectFileJSON::GetByteOrder(), ObjectFilePlaceholder::GetByteOrder(), lldb_private::wasm::ObjectFileWasm::GetByteOrder(), GetByteOrderAndAddrSize(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), ABISysV_mips::GetReturnValueObjectImpl(), ABISysV_mips64::GetReturnValueObjectImpl(), ABISysV_ppc::GetReturnValueObjectImpl(), ABISysV_x86_64::GetReturnValueObjectImpl(), ABIWindows_x86_64::GetReturnValueObjectImpl(), lldb_private::ClangExpressionDeclMap::GetTargetInfo(), lldb_private::Value::GetValueAsData(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerLLGS::Handle_P(), IsMatch(), MakeLocationExpressionInternal(), lldb_private::Disassembler::ParseInstructions(), DynamicLoaderMacOSXDYLD::ReadAllImageInfosStructure(), lldb_private::Target::ReadScalarIntegerFromMemory(), lldb_private::breakpad::SymbolFileBreakpad::SaveAsDWARF(), ObjectFileMachO::SaveCore(), CommunicationKDP::SendRequestHostInfo(), lldb_private::DynamicRegisterInfo::SetRegisterInfo(), lldb_private::ValueObjectDynamicValue::UpdateValue(), lldb_private::ValueObjectMemory::UpdateValue(), lldb_private::ValueObjectVariable::UpdateValue(), lldb_private::ValueObject::ValueObject(), and UnwindAssemblyInstEmulation::WriteMemory().
std::string ArchSpec::GetClangTargetCPU | ( | ) | const |
Returns a string representing current architecture as a target CPU for tools like compiler, disassembler etc.
Definition at line 597 of file ArchSpec.cpp.
References eCore_mips32, eCore_mips32el, eCore_mips32r2, eCore_mips32r2el, eCore_mips32r3, eCore_mips32r3el, eCore_mips32r5, eCore_mips32r5el, eCore_mips32r6, eCore_mips32r6el, eCore_mips64, eCore_mips64el, eCore_mips64r2, eCore_mips64r2el, eCore_mips64r3, eCore_mips64r3el, eCore_mips64r5, eCore_mips64r5el, eCore_mips64r6, eCore_mips64r6el, GetTriple(), IsMIPS(), and m_core.
Referenced by SetupTargetOpts().
uint32_t ArchSpec::GetCodeByteSize | ( | ) | const |
Architecture code byte width accessor.
Definition at line 679 of file ArchSpec.cpp.
Referenced by GetTargetByteSize().
|
inline |
Definition at line 429 of file ArchSpec.h.
References m_core.
Referenced by lldb_private::PlatformDarwin::ARMGetSupportedArchitectures(), lldb_private::EmulateInstructionRISCV::Decode(), lldb_private::StopInfoMachException::DeterminePtrauthFailure(), DisassemblerLLVMC::DisassemblerLLVMC(), EmulateInstructionMIPS::EmulateInstructionMIPS(), EmulateInstructionMIPS64::EmulateInstructionMIPS64(), lldb_private::DWARFExpression::Evaluate(), lldb_private::FuncUnwinders::GetDebugFrameAugmentedUnwindPlan(), lldb_private::FuncUnwinders::GetEHFrameAugmentedUnwindPlan(), lldb_private::PlatformMacOSX::GetSharedModule(), ELFLinuxPrStatus::GetSize(), ELFLinuxSigInfo::GetSize(), ELFLinuxPrPsInfo::GetSize(), lldb_private::PlatformRemoteAppleWatch::GetSupportedArchitectures(), lldb_private::PlatformRemoteAppleTV::GetSupportedArchitectures(), IsAlwaysThumbInstructions(), ABIMacOSX_arm::IsArmv7kProcess(), IsMatch(), MergeFrom(), lldb_private::operator<(), lldb_private::operator==(), ReadJITEntry(), lldb_private::process_gdb_remote::ProcessGDBRemote::SetThreadStopInfo(), and lldb_private::PlatformDarwin::x86GetSupportedArchitectures().
uint32_t ArchSpec::GetDataByteSize | ( | ) | const |
Architecture data byte width accessor.
Definition at line 675 of file ArchSpec.cpp.
Referenced by ConvertPDBLocationToDWARFExpression(), CreateDWARFExpression(), CommandObjectMemoryRead::DoExecute(), GetTargetByteSize(), and MakeLocationExpressionInternal().
ByteOrder ArchSpec::GetDefaultEndian | ( | ) | const |
Returns the default endianness of the architecture.
Definition at line 705 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::default_byte_order, lldb::eByteOrderInvalid, FindCoreDefinition(), and m_core.
Referenced by GetByteOrder().
|
inline |
Definition at line 521 of file ArchSpec.h.
References m_flags.
Referenced by ABISysV_riscv::CallFrameAddressIsValid(), ABISysV_riscv::CodeAddressIsValid(), DisassemblerLLVMC::DisassemblerLLVMC(), EmulateInstructionMIPS::EmulateInstructionMIPS(), EmulateInstructionMIPS64::EmulateInstructionMIPS64(), GetClangTargetABI(), lldb_private::ArchitectureMips::GetInstructionAtAddress(), ABISysV_mips::GetReturnValueObjectImpl(), ABISysV_mips64::GetReturnValueObjectImpl(), ABISysV_riscv::GetReturnValueObjectImpl(), ABISysV_riscv::GetReturnValueObjectSimple(), ObjectFileELF::GetSectionHeaderInfo(), lldb_private::Platform::GetSoftwareBreakpointTrapOpcode(), GetTargetABI(), ABISysV_arm::IsArmHardFloat(), MergeFrom(), ABISysV_riscv::RegisterIsCalleeSaved(), and SetFlags().
llvm::Triple::ArchType ArchSpec::GetMachine | ( | ) | const |
Returns a machine family for the current architecture.
Definition at line 683 of file ArchSpec.cpp.
References FindCoreDefinition(), m_core, and lldb_private::CoreDefinition::machine.
Referenced by MinidumpFileBuilder::AddThreadList(), ABISysV_riscv::CodeAddressIsValid(), ConvertPDBLocationToDWARFExpression(), lldb_private::ArchitectureAArch64::Create(), lldb_private::ArchitectureArm::Create(), lldb_private::PlatformRemoteAppleBridge::CreateInstance(), lldb_private::PlatformRemoteAppleWatch::CreateInstance(), lldb_private::PlatformRemoteiOS::CreateInstance(), lldb_private::PlatformRemoteAppleTV::CreateInstance(), lldb_private::PlatformRemoteAppleXR::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), UnwindAssembly_x86::CreateInstance(), ThreadElfCore::CreateRegisterContextForFrame(), ThreadFreeBSDKernel::CreateRegisterContextForFrame(), lldb_private::minidump::ThreadMinidump::CreateRegisterContextForFrame(), lldb_private::TargetThreadWindows::CreateRegisterContextForFrame(), lldb_private::StopInfoMachException::CreateStopReasonWithMachException(), InstructionLLVMC::Decode(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidLaunchOrAttach(), DynamicLoaderMacOSXDYLD::DoInitialImageFetch(), lldb_private::minidump::ProcessMinidump::DoLoadCore(), lldb_private::TargetThreadWindows::DoResume(), lldb_private::NativeThreadWindows::DoResume(), lldb_private::Address::Dump(), lldb_private::EmulateInstructionLoongArch::EmulateInstructionLoongArch(), lldb_private::DynamicRegisterInfo::Finalize(), lldb_private::StopInfoMachException::GetDescription(), DynamicLoaderPOSIXDYLD::GetEntryPoint(), lldb_private::process_gdb_remote::GetFallbackRegisters(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), GetRegisterInfoCount(), RegisterInfoPOSIX_loongarch64::GetRegisterInfoCount(), RegisterInfoPOSIX_riscv64::GetRegisterInfoCount(), GetRegisterInfoPtr(), RegisterInfoPOSIX_loongarch64::GetRegisterInfoPtr(), RegisterInfoPOSIX_riscv64::GetRegisterInfoPtr(), ABISysV_riscv::GetReturnValueObjectImpl(), ABISysV_riscv::GetReturnValueObjectSimple(), ObjectFileELF::GetSectionHeaderInfo(), GetSoftwareBreakpointSize(), lldb_private::Platform::GetSoftwareBreakpointTrapOpcode(), lldb_private::PlatformDarwin::GetSoftwareBreakpointTrapOpcode(), lldb_private::PlatformWindows::GetSoftwareBreakpointTrapOpcode(), lldb_private::ClangExpressionSourceCode::GetText(), GetUserRegisterInfoCount(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), lldb_private::x86AssemblyInspectionEngine::Initialize(), lldb_private::npdb::MakeVFrameRelLocationExpression(), ProcessElfCore::parseFreeBSDNotes(), ObjectFileELF::ParseSymbols(), ObjectFileELF::ParseSymtab(), PrivateGetRegisterCount(), PrivateGetRegisterInfoPtr(), PrivateGetUserRegisterCount(), RegisterContextCorePOSIX_mips64::ReadRegister(), RegisterContextPOSIX_s390x::RegisterContextPOSIX_s390x(), RegisterContextWindows_i386::RegisterContextWindows_i386(), RegisterContextWindows_x86_64::RegisterContextWindows_x86_64(), RegisterInfoPOSIX_arm64::RegisterInfoPOSIX_arm64(), ObjectFileMachO::SaveCore(), SetupTargetOpts(), lldb_private::process_linux::NativeProcessLinux::SupportHardwareSingleStepping(), DisassemblerLLVMC::SymbolLookup(), and lldb_private::process_gdb_remote::GDBRemoteRegisterContext::WriteAllRegisterValues().
uint32_t ArchSpec::GetMachOCPUSubType | ( | ) | const |
Definition at line 663 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::core, FindArchDefinitionEntry(), FindCoreDefinition(), g_macho_arch_def, LLDB_INVALID_CPUTYPE, m_core, and ArchDefinitionEntry::sub.
Referenced by lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), LaunchProcessPosixSpawn(), and ObjectFileMachO::SaveCore().
uint32_t ArchSpec::GetMachOCPUType | ( | ) | const |
Definition at line 651 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::core, ArchDefinitionEntry::cpu, FindArchDefinitionEntry(), FindCoreDefinition(), g_macho_arch_def, LLDB_INVALID_CPUTYPE, and m_core.
Referenced by ThreadMachCore::CalculateStopInfo(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), LaunchProcessPosixSpawn(), LaunchProcessXPC(), and ObjectFileMachO::SaveCore().
uint32_t ArchSpec::GetMaximumOpcodeByteSize | ( | ) | const |
Definition at line 934 of file ArchSpec.cpp.
References FindCoreDefinition(), m_core, and lldb_private::CoreDefinition::max_opcode_byte_size.
Referenced by CalculateDisass(), InstructionLLVMC::Decode(), OptionGroupReadMemory::FinalizeSettings(), lldb_private::StackFrame::GuessValueForAddress(), lldb_private::x86AssemblyInspectionEngine::instruction_length(), lldb_private::ThreadPlanStepInstruction::IsPlanStale(), and lldb_private::Disassembler::ParseInstructions().
uint32_t ArchSpec::GetMinimumOpcodeByteSize | ( | ) | const |
Definition at line 927 of file ArchSpec.cpp.
References FindCoreDefinition(), m_core, and lldb_private::CoreDefinition::min_opcode_byte_size.
Referenced by InstructionLLVMC::Decode().
std::string ArchSpec::GetTargetABI | ( | ) | const |
Return a string representing target application ABI.
Definition at line 561 of file ArchSpec.cpp.
References eMIPSABI_mask, eMIPSABI_N32, eMIPSABI_N64, eMIPSABI_O32, GetFlags(), and IsMIPS().
Referenced by lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), and ELFLinuxPrStatus::GetSize().
|
inline |
Architecture triple accessor.
Definition at line 450 of file ArchSpec.h.
References m_triple.
Referenced by MinidumpFileBuilder::AddHeaderAndCalculateDirectories(), lldb_private::DynamicLoaderDarwin::AddModulesUsingImageInfos(), MinidumpFileBuilder::AddThreadList(), lldb_private::AppleObjCDeclVendor::AppleObjCDeclVendor(), lldb_private::AppleObjCTypeEncodingParser::AppleObjCTypeEncodingParser(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::AvoidGPackets(), BuildProcessSection(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerLLGS::BuildTargetXml(), ProcessKDP::CanDebug(), DynamicLoaderDarwinKernel::CheckForKernelImageAtAddress(), DynamicLoaderFreeBSDKernel::CheckForKernelImageAtAddress(), lldb_private::Process::CompleteAttach(), lldb_private::HostInfoAndroid::ComputeHostArchitectureSupport(), lldb_private::HostInfoLinux::ComputeHostArchitectureSupport(), lldb_private::HostInfoMacOSX::ComputeHostArchitectureSupport(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::ConnectRemote(), lldb_private::ProcessLaunchInfo::ConvertArgumentsForLaunchingInShell(), lldb_private::UnixSignals::Create(), lldb_private::ArchitecturePPC64::Create(), RegisterContextCorePOSIX_arm64::Create(), lldb_private::ClangModulesDeclVendor::Create(), lldb_private::ItaniumABILanguageRuntime::CreateExceptionSearchFilter(), lldb_private::AppleObjCRuntime::CreateExceptionSearchFilter(), lldb_private::platform_android::PlatformAndroid::CreateInstance(), lldb_private::PlatformRemoteAppleBridge::CreateInstance(), lldb_private::PlatformRemoteAppleWatch::CreateInstance(), lldb_private::PlatformRemoteiOS::CreateInstance(), lldb_private::PlatformRemoteMacOSX::CreateInstance(), lldb_private::PlatformRemoteAppleTV::CreateInstance(), lldb_private::PlatformRemoteAppleXR::CreateInstance(), lldb_private::EmulateInstructionPPC64::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), DisassemblerLLVMC::CreateInstance(), lldb_private::EmulateInstructionARM::CreateInstance(), EmulateInstructionARM64::CreateInstance(), EmulateInstructionMIPS::CreateInstance(), EmulateInstructionMIPS64::CreateInstance(), lldb_private::TypeSystemClang::CreateInstance(), ABIMacOSX_arm64::CreateInstance(), ABISysV_arm64::CreateInstance(), ABISysV_arc::CreateInstance(), ABIMacOSX_arm::CreateInstance(), ABISysV_arm::CreateInstance(), ABISysV_hexagon::CreateInstance(), ABISysV_mips::CreateInstance(), ABISysV_mips64::CreateInstance(), ABISysV_msp430::CreateInstance(), ABISysV_ppc::CreateInstance(), ABISysV_ppc64::CreateInstance(), ABISysV_riscv::CreateInstance(), ABISysV_s390x::CreateInstance(), ABIMacOSX_i386::CreateInstance(), ABISysV_i386::CreateInstance(), ABISysV_x86_64::CreateInstance(), ABIWindows_x86_64::CreateInstance(), SystemRuntimeMacOSX::CreateInstance(), DynamicLoaderDarwinKernel::CreateInstance(), DynamicLoaderFreeBSDKernel::CreateInstance(), DynamicLoaderHexagonDYLD::CreateInstance(), DynamicLoaderMacOS::CreateInstance(), DynamicLoaderMacOSXDYLD::CreateInstance(), DynamicLoaderPOSIXDYLD::CreateInstance(), JITLoaderGDB::CreateInstance(), lldb_private::StructuredDataDarwinLog::CreateInstance(), lldb_private::wasm::DynamicLoaderWasmDYLD::CreateInstance(), lldb_private::DynamicLoaderWindowsDYLD::CreateInstance(), lldb_private::GNUstepObjCRuntime::CreateInstance(), lldb_private::OptionGroupPlatform::CreatePlatformWithOptions(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), ThreadElfCore::CreateRegisterContextForFrame(), lldb_private::minidump::ThreadMinidump::CreateRegisterContextForFrame(), lldb_private::PlatformQemuUser::DebugProcess(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::DecodeProcessInfoResponse(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidLaunchOrAttach(), lldb_private::Disassembler::Disassembler(), DisassemblerLLVMC::DisassemblerLLVMC(), lldb_private::Platform::DoConnectProcess(), CommandObjectProcessAttach::DoExecute(), ObjectFileMachO::Dump(), DumpTriple(), EmulateInstructionMIPS::EmulateInstructionMIPS(), EmulateInstructionMIPS64::EmulateInstructionMIPS64(), lldb_private::StructuredDataDarwinLog::FilterLaunchInfo(), lldb_private::DynamicRegisterInfo::Finalize(), lldb_private::Disassembler::FindPluginForTarget(), lldb_private::PlatformAppleSimulator::FindProcesses(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::FindProcesses(), lldb_private::DynamicLoaderDarwin::FindTargetModuleForImageInfo(), DisassemblerLLVMC::FlavorValidForArchSpec(), lldb_private::FormatEntity::Format(), ObjectFileMachO::GetAllArchSpecs(), lldb_private::Platform::GetAugmentedArchSpec(), lldb_private::Module::GetCacheKey(), GetClangTargetCPU(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), lldb::SBDebugger::GetDefaultArchitecture(), lldb_private::EmulateInstructionARM::GetFramePointerDWARFRegisterNumber(), lldb_private::EmulateInstructionARM::GetFramePointerRegisterNumber(), EmulateInstructionARM64::GetFramePointerRegisterNumber(), lldb_private::RegisterContextUnwind::GetFullUnwindPlanForFrame(), ProcessKDP::GetHostArchitecture(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), GetMacOSXProcessArgs(), lldb_private::platform_freebsd::PlatformFreeBSD::GetMmapArgumentList(), GetModuleConfig(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetModuleInfo(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::GetModuleSpec(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetModuleSpec(), ObjectFileELF::GetModuleSpecifications(), ObjectFilePECOFF::GetModuleSpecifications(), lldb_private::AppleObjCRuntime::GetObjCVersion(), ObjectFileELF::GetSectionHeaderInfo(), lldb_private::Thread::GetSiginfoValue(), GetSoftwareBreakpointSize(), lldb_private::Platform::GetStatus(), lldb_private::PlatformMacOSX::GetSupportedArchitectures(), lldb::SBPlatform::GetTriple(), lldb_private::Process::GetWatchpointReportedAfter(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_jModulesInfo(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), lldb_private::Module::Hash(), IsAlwaysThumbInstructions(), IsFullySpecifiedTriple(), isLoadBiasIncorrect(), IsMatch(), IsMIPS(), lldb_private::GNUstepObjCRuntime::IsModuleObjCLibrary(), lldb_private::PosixPlatformCommandOptionValidator::IsValid(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::LaunchGDBServer(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::LaunchProcess(), DynamicLoaderPOSIXDYLD::LoadAllCurrentModules(), DynamicLoaderPOSIXDYLD::LoadModuleAtAddress(), lldb_private::SymbolLocatorDefault::LocateExecutableSymbolFile(), lldb_private::ABI::MakeMCRegisterInfo(), lldb_private::Module::MergeArchitecture(), lldb_private::Target::MergeArchitecture(), MergeFrom(), DynamicLoaderMacOS::NotifyBreakpointHit(), DynamicLoaderMacOSXDYLD::NotifyBreakpointHit(), lldb_private::CommandObjectDisassemble::CommandOptions::OptionParsingStarting(), ObjectFileELF::ParseARMAttributes(), ParseLangArgs(), lldb_private::ParseMachCPUDashSubtypeTriple(), ParseModuleSpec(), lldb_private::platform_freebsd::PlatformFreeBSD::PlatformFreeBSD(), lldb_private::platform_linux::PlatformLinux::PlatformLinux(), lldb_private::platform_netbsd::PlatformNetBSD::PlatformNetBSD(), DYLDRendezvous::ReadSOEntryFromMemory(), lldb_private::AssertFrameRecognizer::RecognizeFrame(), ObjectFileELF::RefineModuleDetailsFromNote(), lldb_private::minidump::ProcessMinidump::RefreshStateAfterStop(), lldb_private::RegisterAssertFrameRecognizer(), RegisterContextCorePOSIX_arm64::RegisterContextCorePOSIX_arm64(), RegisterContextCorePOSIX_mips64::RegisterContextCorePOSIX_mips64(), RegisterContextCorePOSIX_powerpc::RegisterContextCorePOSIX_powerpc(), RegisterContextCorePOSIX_ppc64le::RegisterContextCorePOSIX_ppc64le(), RegisterContextCorePOSIX_riscv64::RegisterContextCorePOSIX_riscv64(), RegisterContextCorePOSIX_s390x::RegisterContextCorePOSIX_s390x(), RegisterContextCorePOSIX_x86_64::RegisterContextCorePOSIX_x86_64(), lldb_private::DebuggerStats::ReportStatistics(), ObjectFileMachO::SaveCore(), sdkSupportsBuiltinModules(), lldb_private::Target::SetArchitecture(), lldb_private::Target::SetDefaultArchitecture(), lldb_private::Target::SetExecutableModule(), lldb_private::EmulateInstructionARM::SetInstruction(), CommandObjectProcessLoad::CommandOptions::SetOptionValue(), lldb_private::EmulateInstructionARM::SetTargetTriple(), lldb_private::EmulateInstructionPPC64::SetTargetTriple(), EmulateInstructionARM64::SetTargetTriple(), EmulateInstructionMIPS::SetTargetTriple(), EmulateInstructionMIPS64::SetTargetTriple(), SetupTargetOpts(), DYLDRendezvous::SOEntryIsMainExecutable(), lldb_private::process_linux::NativeProcessLinux::SupportHardwareSingleStepping(), lldb_private::EmulateInstructionLoongArch::SupportsThisArch(), lldb_private::EmulateInstructionRISCV::SupportsThisArch(), lldb_private::Target::Target(), lldb_private::EmulateInstructionARM::TestEmulation(), lldb_private::DynamicLoaderDarwin::UpdateSpecialBinariesFromNewImageInfos(), lldb_private::DynamicLoaderDarwin::UseDYLDSPI(), lldb_private::process_gdb_remote::GDBRemoteRegisterContext::WriteAllRegisterValues(), and lldb_private::x86AssemblyInspectionEngine::x86AssemblyInspectionEngine().
|
inline |
Architecture triple accessor.
Definition at line 455 of file ArchSpec.h.
References m_triple.
bool ArchSpec::IsAlwaysThumbInstructions | ( | ) | const |
Detect whether this architecture uses thumb code exclusively.
Some embedded ARM chips (e.g. the ARM Cortex M0-7 line) can only execute the Thumb instructions, never Arm. We should normally pick up arm/thumbness from their the processor status bits (cpsr/xpsr) or hints on each function - but when doing bare-boards low level debugging (especially common with these embedded processors), we may not have those things easily accessible.
Definition at line 1424 of file ArchSpec.cpp.
References eCore_arm_armv6m, eCore_arm_armv7em, eCore_arm_armv7m, eCore_thumbv6m, eCore_thumbv7em, eCore_thumbv7m, GetCore(), and GetTriple().
Referenced by lldb_private::Disassembler::Disassembler(), DisassemblerLLVMC::DisassemblerLLVMC(), ObjectFileMachO::ParseSymtab(), lldb_private::EmulateInstructionARM::ReadInstruction(), lldb_private::EmulateInstructionARM::SetInstruction(), and lldb_private::EmulateInstructionARM::TestEmulation().
|
inline |
Shorthand for IsMatch(rhs, CompatibleMatch).
Definition at line 502 of file ArchSpec.h.
References CompatibleMatch, and IsMatch().
Referenced by lldb_private::ProcessInstanceInfoMatch::ArchitectureMatches(), DynamicLoaderDarwinKernel::CheckForKernelImageAtAddress(), DynamicLoaderFreeBSDKernel::CheckForKernelImageAtAddress(), lldb_private::Process::CompleteAttach(), lldb_private::TargetList::CreateTargetInternal(), lldb_private::SymbolLocatorDebugSymbols::DownloadObjectAndSymbolFile(), FileAtPathContainsArchAndUUID(), lldb_private::SymbolLocatorDebugSymbols::FindSymbolFileInBundle(), lldb_private::DynamicLoaderDarwin::ImageInfo::GetArchitecture(), ObjectFileMachO::GetArchitecture(), ObjectContainerUniversalMachO::GetObjectFile(), lldb_private::Module::MatchesModuleSpec(), lldb_private::Module::MergeArchitecture(), lldb_private::Target::MergeArchitecture(), MergeFrom(), ObjectFileMachO::ParseHeader(), lldb_private::process_gdb_remote::ProcessGDBRemote::ParsePythonTargetDefinition(), lldb_private::BreakpointLocationList::RemoveInvalidLocations(), lldb_private::Target::SetArchitecture(), and lldb_private::Module::SetArchitecture().
|
inline |
Shorthand for IsMatch(rhs, ExactMatch).
Definition at line 497 of file ArchSpec.h.
References ExactMatch, and IsMatch().
Referenced by lldb_private::Process::CompleteAttach(), CommandObjectProcessAttach::DoExecute(), ObjectContainerUniversalMachO::GetObjectFile(), and lldb_private::PlatformDarwin::x86GetSupportedArchitectures().
bool ArchSpec::IsFullySpecifiedTriple | ( | ) | const |
Definition at line 1409 of file ArchSpec.cpp.
References GetTriple(), TripleOSWasSpecified(), and TripleVendorWasSpecified().
Compare this ArchSpec to another ArchSpec.
match specifies the kind of matching that is to be done. CompatibleMatch requires only a compatible cpu type (e.g., armv7s is compatible with armv7). ExactMatch requires an exact match (armv7s is not an exact match with armv7).
Definition at line 972 of file ArchSpec.cpp.
References CompatibleMatch, cores_match(), ExactMatch, GetByteOrder(), GetCore(), GetTriple(), IsCompatibleEnvironment(), TripleOSWasSpecified(), and TripleVendorWasSpecified().
Referenced by lldb_private::Platform::IsCompatibleArchitecture(), IsCompatibleMatch(), and IsExactMatch().
bool ArchSpec::IsMIPS | ( | ) | const |
if MIPS architecture return true.
Definition at line 559 of file ArchSpec.cpp.
References GetTriple().
Referenced by lldb_private::ArchitectureMips::Create(), DisassemblerLLVMC::DisassemblerLLVMC(), ProcessElfCore::GetArchitecture(), GetClangTargetABI(), GetClangTargetCPU(), lldb_private::platform_linux::PlatformLinux::GetMmapArgumentList(), ObjectFileELF::GetSectionHeaderInfo(), ELFLinuxPrStatus::GetSize(), ELFLinuxSigInfo::GetSize(), ELFLinuxPrPsInfo::GetSize(), GetSoftwareBreakpointSize(), GetTargetABI(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::Handle_qHostInfo(), ELFLinuxPrPsInfo::Parse(), ObjectFileELF::ParseSymbols(), DYLDRendezvous::ReadSOEntryFromMemory(), ObjectFileELF::RefineModuleDetailsFromNote(), SetFlags(), lldb_private::process_freebsd::NativeProcessFreeBSD::SupportHardwareSingleStepping(), and lldb_private::process_linux::NativeProcessLinux::SupportHardwareSingleStepping().
|
inline |
Tests if this ArchSpec is valid.
Definition at line 348 of file ArchSpec.h.
References eCore_arm_generic, kNumCores, and m_core.
Referenced by lldb_private::ProcessInstanceInfoMatch::ArchitectureMatches(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::AvoidGPackets(), lldb_private::process_gdb_remote::ProcessGDBRemote::BuildDynamicRegisterInfo(), lldb_private::Process::CompleteAttach(), lldb_private::HostInfoAndroid::ComputeHostArchitectureSupport(), lldb_private::HostInfoLinux::ComputeHostArchitectureSupport(), lldb_private::platform_android::PlatformAndroid::CreateInstance(), lldb_private::PlatformRemoteAppleBridge::CreateInstance(), lldb_private::PlatformRemoteAppleWatch::CreateInstance(), lldb_private::PlatformRemoteiOS::CreateInstance(), lldb_private::PlatformRemoteMacOSX::CreateInstance(), lldb_private::PlatformRemoteAppleTV::CreateInstance(), lldb_private::PlatformRemoteAppleXR::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), lldb_private::TypeSystemClang::CreateInstance(), lldb_private::OptionGroupPlatform::CreatePlatformWithOptions(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse(), lldb_private::process_gdb_remote::GDBRemoteCommunicationServerCommon::CreateProcessInfoResponse_DebugServerStyle(), lldb_private::TargetList::CreateTargetInternal(), lldb::SBDebugger::CreateTargetWithFileAndArch(), lldb_private::Debugger::Debugger(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidLaunchOrAttach(), lldb_private::Platform::DoConnectProcess(), lldb_private::process_gdb_remote::ProcessGDBRemote::DoConnectRemote(), CommandObjectTargetModulesAdd::DoExecute(), lldb_private::CommandObjectDisassemble::DoExecute(), CommandObjectProcessAttach::DoExecute(), lldb_private::process_gdb_remote::ProcessGDBRemote::DoLaunch(), ProcessMachCore::DoLoadCore(), lldb_private::ProcessInstanceInfo::Dump(), lldb_private::ModuleSpec::Dump(), lldb_private::ProcessInstanceInfo::DumpAsTableRow(), DumpTargetInfo(), lldb_private::OptionValueArch::DumpValue(), ObjectContainerBSDArchive::Archive::FindCachedArchive(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::FindProcesses(), lldb_private::FormatEntity::Format(), lldb_private::minidump::MinidumpParser::GetArchitecture(), lldb_private::OptionGroupArchitecture::GetArchitecture(), lldb_private::ModuleSpec::GetArchitecturePtr(), lldb_private::Platform::GetAugmentedArchSpec(), lldb::SBDebugger::GetDefaultArchitecture(), lldb_private::Module::GetDescription(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetGDBServerRegisterInfoXMLAndProcess(), ObjectContainerBSDArchive::GetModuleSpecifications(), ObjectFileELF::GetModuleSpecifications(), ObjectContainerUniversalMachO::GetObjectFile(), lldb_private::PlatformList::GetOrCreate(), lldb_private::Platform::GetRemoteSharedModule(), lldb_private::ModuleList::GetSharedModule(), lldb_private::Platform::GetSoftwareBreakpointTrapOpcode(), lldb_private::PlatformWindows::GetSoftwareBreakpointTrapOpcode(), lldb_private::Platform::GetStatus(), lldb_private::Platform::GetSystemArchitecture(), lldb::SBPlatform::GetTriple(), lldb_private::Process::GetWatchpointReportedAfter(), lldb_private::Platform::IsCompatibleArchitecture(), lldb_private::Target::Launch(), lldb::SBTarget::Launch(), lldb_private::DynamicLoader::LoadBinaryWithUUIDAndAddress(), lldb_private::ProcessInstanceInfoMatch::MatchAllProcesses(), lldb_private::Module::MatchesModuleSpec(), lldb_private::Module::MergeArchitecture(), lldb_private::Target::MergeArchitecture(), lldb_private::Module::Module(), lldb_private::ModuleSpec::operator bool(), operator bool(), ObjectFileMachO::ParseHeader(), ObjectFileELF::ParseSymbols(), lldb_private::BreakpointLocationList::RemoveInvalidLocations(), lldb_private::Platform::ResolveExecutable(), SetArchitecture(), lldb_private::Target::SetArchitecture(), lldb_private::Module::SetArchitecture(), lldb::SBDebugger::SetDefaultArchitecture(), lldb_private::Target::SetExecutableModule(), lldb_private::Platform::SetSystemArchitecture(), SetTriple(), SetupTargetOpts(), shouldSkipSimulatorPlatform(), lldb_private::Target::Target(), and lldb_private::process_gdb_remote::GDBRemoteRegisterContext::WriteAllRegisterValues().
|
static |
Definition at line 267 of file ArchSpec.cpp.
References lldb_private::StringList::AppendString(), and g_core_definitions.
Referenced by lldb_private::arch_helper().
void ArchSpec::MergeFrom | ( | const ArchSpec & | other | ) |
Merges fields from another ArchSpec into this ArchSpec.
This will use the supplied ArchSpec to fill in any fields of the triple in this ArchSpec which were unspecified. This can be used to refine a generic ArchSpec with a more specific one. For example, if this ArchSpec's triple is something like i386-unknown-unknown-unknown, and we have a triple which is x64-pc-windows-msvc, then merging that triple into this one will result in the triple i386-pc-windows-msvc.
Definition at line 809 of file ArchSpec.cpp.
References CoreUpdated(), eCore_arm_generic, eCore_uknownMach64, GetCore(), GetFlags(), GetTriple(), IsCompatibleMatch(), m_core, SetFlags(), TripleEnvironmentWasSpecified(), TripleOSWasSpecified(), TripleVendorWasSpecified(), and UpdateCore().
Referenced by ProcessKDP::DoConnectRemote(), ProcessElfCore::DoLoadCore(), ProcessElfCore::GetArchitecture(), lldb_private::DynamicLoaderDarwin::ImageInfo::GetArchitecture(), lldb_private::Module::GetMemoryObjectFile(), lldb_private::Module::GetObjectFile(), lldb_private::Module::MergeArchitecture(), lldb_private::Target::MergeArchitecture(), and lldb_private::Target::SetArchitecture().
|
inlineexplicit |
Definition at line 351 of file ArchSpec.h.
References IsValid().
bool ArchSpec::SetArchitecture | ( | ArchitectureType | arch_type, |
uint32_t | cpu, | ||
uint32_t | sub, | ||
uint32_t | os = 0 |
||
) |
Change the architecture object type, CPU type and OS type.
[in] | arch_type | The object type of this ArchSpec. |
[in] | cpu | The required CPU type. |
[in] | os | The optional OS type The default value of 0 was chosen to from the ELF spec value ELFOSABI_NONE. ELF is the only one using this parameter. If another format uses this parameter and 0 does not work, use a value over 255 because in the ELF header this is value is only a byte. |
As a side effect, the vendor value is usually set to unknown. The exceptions are aarch64-apple-ios arm-apple-ios thumb-apple-ios x86-apple- x86_64-apple-
As a side effect, the os value is usually set to unknown The exceptions are --aix aarch64-apple-ios arm-apple-ios thumb-apple-ios powerpc-apple-darwin --freebsd --linux --netbsd --openbsd --solaris
Definition at line 851 of file ArchSpec.cpp.
References lldb_private::CoreDefinition::core, ArchDefinitionEntry::core, CoreUpdated(), lldb_private::eArchTypeCOFF, lldb_private::eArchTypeELF, lldb_private::eArchTypeMachO, FindArchDefinition(), FindArchDefinitionEntry(), FindCoreDefinition(), lldb_private::GetLog(), IsValid(), kCore_invalid, LLDB_LOGF, m_core, m_triple, lldb_private::CoreDefinition::machine, lldb_private::CoreDefinition::name, lldb_private::Platform, lldb_private::Process, and lldb_private::Target.
Referenced by ArchSpec(), lldb_private::HostInfoMacOSX::ComputeHostArchitectureSupport(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::DecodeProcessInfoResponse(), ObjectFileMachO::GetAllArchSpecs(), lldb_private::ObjectFilePDB::GetArchitecture(), ObjectFilePECOFF::GetArchitecture(), ObjectContainerUniversalMachO::GetArchitectureAtIndex(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), ProcessKDP::GetHostArchitecture(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), GetMacOSXProcessCPUType(), ObjectFileELF::GetModuleSpecifications(), ObjectFileELF::GetSectionHeaderInfo(), lldb_private::ParseMachCPUDashSubtypeTriple(), and CommunicationKDP::SendRequestHostInfo().
|
inline |
Sets this ArchSpec's byte order.
In the common case there is no need to call this method as the byte order can almost always be determined by the architecture. However, many CPU's are bi-endian (ARM, Alpha, PowerPC, etc) and the default/assumed byte order may be incorrect.
Definition at line 423 of file ArchSpec.h.
References m_byte_order.
void ArchSpec::SetFlags | ( | const std::string & | elf_abi | ) |
Definition at line 583 of file ArchSpec.cpp.
References eMIPSABI_N32, eMIPSABI_N64, eMIPSABI_O32, GetFlags(), IsMIPS(), and SetFlags().
|
inline |
Definition at line 523 of file ArchSpec.h.
References m_flags.
Referenced by lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), ObjectFileELF::GetSectionHeaderInfo(), MergeFrom(), ObjectFileELF::ParseARMAttributes(), and SetFlags().
bool ArchSpec::SetTriple | ( | const llvm::Triple & | triple | ) |
Architecture triple setter.
Configures this ArchSpec according to the given triple. If the triple has unknown components in all of the vendor, OS, and the optional environment field (i.e. "i386-unknown-unknown") then default values are taken from the host. Architecture and environment components are used to further resolve the CPU type and subtype, endian characteristics, etc.
Definition at line 747 of file ArchSpec.cpp.
References IsValid(), m_triple, and UpdateCore().
Referenced by ArchSpec(), lldb_private::HostInfoBase::ComputeHostArchitectureSupport(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::DecodeProcessInfoResponse(), lldb_private::process_gdb_remote::ProcessGDBRemote::DidLaunchOrAttach(), lldb_private::Disassembler::Disassembler(), lldb_private::minidump::MinidumpParser::GetArchitecture(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetCurrentProcessInfo(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetGDBServerRegisterInfoXMLAndProcess(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetHostInfo(), lldb_private::plugin::dwarf::SymbolFileDWARFDebugMap::GetModuleByCompUnitInfo(), lldb_private::process_gdb_remote::GDBRemoteCommunicationClient::GetModuleInfo(), lldb_private::ObjectFilePDB::GetModuleSpecifications(), ObjectFilePECOFF::GetModuleSpecifications(), ObjectContainerUniversalMachO::GetObjectFile(), ParseModuleSpec(), SetTriple(), lldb_private::OptionValueArch::SetValueFromString(), lldb_private::Instruction::TestEmulation(), and lldb_private::DynamicLoaderDarwin::UpdateSpecialBinariesFromNewImageInfos().
bool ArchSpec::SetTriple | ( | llvm::StringRef | triple_str | ) |
Definition at line 789 of file ArchSpec.cpp.
References Clear(), IsValid(), lldb_private::ParseMachCPUDashSubtypeTriple(), and SetTriple().
|
inline |
Definition at line 359 of file ArchSpec.h.
References m_triple.
Referenced by lldb_private::platform_android::PlatformAndroid::CreateInstance(), MergeFrom(), and shouldSkipSimulatorPlatform().
|
inline |
Definition at line 357 of file ArchSpec.h.
References m_triple.
Referenced by lldb_private::platform_gdb_server::PlatformRemoteGDBServer::CreateInstance(), lldb_private::PlatformRemoteMacOSX::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), lldb_private::TargetList::CreateTargetInternal(), ObjectFileELF::GetArchitecture(), IsFullySpecifiedTriple(), IsMatch(), and MergeFrom().
|
inline |
Definition at line 353 of file ArchSpec.h.
References m_triple.
Referenced by lldb_private::platform_android::PlatformAndroid::CreateInstance(), lldb_private::platform_gdb_server::PlatformRemoteGDBServer::CreateInstance(), lldb_private::PlatformRemoteAppleBridge::CreateInstance(), lldb_private::PlatformRemoteAppleWatch::CreateInstance(), lldb_private::PlatformRemoteiOS::CreateInstance(), lldb_private::PlatformRemoteMacOSX::CreateInstance(), lldb_private::PlatformRemoteAppleTV::CreateInstance(), lldb_private::PlatformRemoteAppleXR::CreateInstance(), lldb_private::PlatformAppleSimulator::CreateInstance(), lldb_private::TargetList::CreateTargetInternal(), IsFullySpecifiedTriple(), IsMatch(), and MergeFrom().
|
protected |
Definition at line 1049 of file ArchSpec.cpp.
References Clear(), lldb_private::CoreDefinition::core, lldb_private::CoreDefinition::default_byte_order, FindCoreDefinition(), m_byte_order, m_core, and m_triple.
Referenced by MergeFrom(), and SetTriple().
|
protected |
Definition at line 532 of file ArchSpec.h.
Referenced by Clear(), CoreUpdated(), GetByteOrder(), SetByteOrder(), and UpdateCore().
|
protected |
Definition at line 531 of file ArchSpec.h.
Referenced by Clear(), CoreUpdated(), GetAddressByteSize(), GetArchitectureName(), GetClangTargetCPU(), GetCore(), GetDefaultEndian(), GetMachine(), GetMachOCPUSubType(), GetMachOCPUType(), GetMaximumOpcodeByteSize(), GetMinimumOpcodeByteSize(), IsValid(), MergeFrom(), SetArchitecture(), and UpdateCore().
|
protected |
Definition at line 536 of file ArchSpec.h.
Referenced by Clear(), GetAddressByteSize(), GetFlags(), and SetFlags().
|
protected |
Definition at line 530 of file ArchSpec.h.
Referenced by CharIsSignedByDefault(), Clear(), CoreUpdated(), GetTriple(), SetArchitecture(), SetTriple(), TripleEnvironmentWasSpecified(), TripleOSWasSpecified(), TripleVendorWasSpecified(), and UpdateCore().