diff options
Diffstat (limited to 'lldb/source/Plugins/Process')
-rw-r--r-- | lldb/source/Plugins/Process/Utility/ARMDefines.h | 9 | ||||
-rw-r--r-- | lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp | 19 |
2 files changed, 21 insertions, 7 deletions
diff --git a/lldb/source/Plugins/Process/Utility/ARMDefines.h b/lldb/source/Plugins/Process/Utility/ARMDefines.h index 0ef8c61449a..3cc9d4674c3 100644 --- a/lldb/source/Plugins/Process/Utility/ARMDefines.h +++ b/lldb/source/Plugins/Process/Utility/ARMDefines.h @@ -79,6 +79,15 @@ static inline const char *ARMCondCodeToString(uint32_t CC) #define CPSR_Z_POS 30 #define CPSR_N_POS 31 +// CPSR mode definitions +#define CPSR_MODE_USR 0x10u +#define CPSR_MODE_FIQ 0x11u +#define CPSR_MODE_IRQ 0x12u +#define CPSR_MODE_SVC 0x13u +#define CPSR_MODE_ABT 0x17u +#define CPSR_MODE_UND 0x1bu +#define CPSR_MODE_SYS 0x1fu + // Masks for CPSR #define MASK_CPSR_MODE_MASK (0x0000001fu) #define MASK_CPSR_T (1u << CPSR_T_POS) diff --git a/lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp b/lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp index 351b6eb2bc9..3e9cef34c19 100644 --- a/lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp +++ b/lldb/source/Plugins/Process/gdb-remote/ThreadGDBRemote.cpp @@ -143,16 +143,21 @@ ThreadGDBRemote::GetUnwinder () { const ArchSpec target_arch (GetProcess().GetTarget().GetArchitecture ()); const llvm::Triple::ArchType machine = target_arch.GetMachine(); - if (machine == llvm::Triple::x86_64 || machine == llvm::Triple::x86) + switch (machine) { - m_unwinder_ap.reset (new UnwindLLDB (*this)); - } + case llvm::Triple::x86_64: + case llvm::Triple::x86: + case llvm::Triple::arm: + case llvm::Triple::thumb: + m_unwinder_ap.reset (new UnwindLLDB (*this)); + break; + + default: #if defined(__APPLE__) - else - { - m_unwinder_ap.reset (new UnwindMacOSXFrameBackchain (*this)); - } + m_unwinder_ap.reset (new UnwindMacOSXFrameBackchain (*this)); #endif + break; + } } return m_unwinder_ap.get(); } |