LLDB mainline
RegisterContextPOSIX_arm.h
Go to the documentation of this file.
1//===-- RegisterContextPOSIX_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 LLDB_SOURCE_PLUGINS_PROCESS_UTILITY_REGISTERCONTEXTPOSIX_ARM_H
10#define LLDB_SOURCE_PLUGINS_PROCESS_UTILITY_REGISTERCONTEXTPOSIX_ARM_H
11
15#include "lldb/Utility/Log.h"
16
18public:
21 std::unique_ptr<RegisterInfoPOSIX_arm> register_info);
22
24
25 void Invalidate();
26
27 void InvalidateAllRegisters() override;
28
29 size_t GetRegisterCount() override;
30
31 virtual size_t GetGPRSize();
32
33 virtual unsigned GetRegisterSize(unsigned reg);
34
35 virtual unsigned GetRegisterOffset(unsigned reg);
36
37 const lldb_private::RegisterInfo *GetRegisterInfoAtIndex(size_t reg) override;
38
39 size_t GetRegisterSetCount() override;
40
41 const lldb_private::RegisterSet *GetRegisterSet(size_t set) override;
42
43 const char *GetRegisterName(unsigned reg);
44
45protected:
46 std::unique_ptr<RegisterInfoPOSIX_arm> m_register_info_up;
47
49
50 bool IsGPR(unsigned reg);
51
52 bool IsFPR(unsigned reg);
53
54 size_t GetFPUSize() { return sizeof(RegisterInfoPOSIX_arm::FPU); }
55
56 virtual bool ReadGPR() = 0;
57 virtual bool ReadFPR() = 0;
58 virtual bool WriteGPR() = 0;
59 virtual bool WriteFPR() = 0;
60};
61
62#endif // LLDB_SOURCE_PLUGINS_PROCESS_UTILITY_REGISTERCONTEXTPOSIX_ARM_H
virtual bool ReadGPR()=0
virtual unsigned GetRegisterOffset(unsigned reg)
const lldb_private::RegisterInfo * GetRegisterInfoAtIndex(size_t reg) override
const char * GetRegisterName(unsigned reg)
const lldb_private::RegisterSet * GetRegisterSet(size_t set) override
std::unique_ptr< RegisterInfoPOSIX_arm > m_register_info_up
virtual bool WriteGPR()=0
virtual unsigned GetRegisterSize(unsigned reg)
virtual bool ReadFPR()=0
~RegisterContextPOSIX_arm() override
virtual bool WriteFPR()=0
virtual const lldb_private::RegisterInfo * GetRegisterInfo()
Every register is described in detail including its name, alternate name (optional),...
Registers are grouped into register sets.