1 //===-- RegisterInfoPOSIX_arm.h ---------------------------------*- C++ -*-===// 2 // 3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 // See https://llvm.org/LICENSE.txt for license information. 5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 // 7 //===----------------------------------------------------------------------===// 8 9 #ifndef liblldb_RegisterInfoPOSIX_arm_h_ 10 #define liblldb_RegisterInfoPOSIX_arm_h_ 11 12 #include "RegisterInfoInterface.h" 13 #include "lldb/Target/RegisterContext.h" 14 #include "lldb/lldb-private.h" 15 16 class RegisterInfoPOSIX_arm : public lldb_private::RegisterInfoInterface { 17 public: 18 struct GPR { 19 uint32_t r[16]; // R0-R15 20 uint32_t cpsr; // CPSR 21 }; 22 23 struct QReg { 24 uint8_t bytes[16]; 25 }; 26 27 struct FPU { 28 union { 29 uint32_t s[32]; 30 uint64_t d[32]; 31 QReg q[16]; // the 128-bit NEON registers 32 } floats; 33 uint32_t fpscr; 34 }; 35 struct EXC { 36 uint32_t exception; 37 uint32_t fsr; /* Fault status */ 38 uint32_t far; /* Virtual Fault Address */ 39 }; 40 41 struct DBG { 42 uint32_t bvr[16]; 43 uint32_t bcr[16]; 44 uint32_t wvr[16]; 45 uint32_t wcr[16]; 46 }; 47 48 RegisterInfoPOSIX_arm(const lldb_private::ArchSpec &target_arch); 49 50 size_t GetGPRSize() const override; 51 52 const lldb_private::RegisterInfo *GetRegisterInfo() const override; 53 54 uint32_t GetRegisterCount() const override; 55 56 private: 57 const lldb_private::RegisterInfo *m_register_info_p; 58 uint32_t m_register_info_count; 59 }; 60 61 #endif // liblldb_RegisterInfoPOSIX_arm_h_ 62