1 //===-- NativeRegisterContextFreeBSD_arm.h ----------------------*- C++ -*-===//
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
7 //===----------------------------------------------------------------------===//
11 #ifndef lldb_NativeRegisterContextFreeBSD_arm_h
12 #define lldb_NativeRegisterContextFreeBSD_arm_h
15 #include <sys/types.h>
16 #include <machine/reg.h>
17 #include <machine/vfp.h>
20 #include "Plugins/Process/FreeBSD/NativeRegisterContextFreeBSD.h"
21 #include "Plugins/Process/Utility/RegisterInfoPOSIX_arm.h"
25 namespace lldb_private
{
26 namespace process_freebsd
{
28 class NativeProcessFreeBSD
;
30 class NativeRegisterContextFreeBSD_arm
: public NativeRegisterContextFreeBSD
{
32 NativeRegisterContextFreeBSD_arm(const ArchSpec
&target_arch
,
33 NativeThreadProtocol
&native_thread
);
35 uint32_t GetRegisterSetCount() const override
;
37 uint32_t GetUserRegisterCount() const override
;
39 const RegisterSet
*GetRegisterSet(uint32_t set_index
) const override
;
41 Status
ReadRegister(const RegisterInfo
*reg_info
,
42 RegisterValue
®_value
) override
;
44 Status
WriteRegister(const RegisterInfo
*reg_info
,
45 const RegisterValue
®_value
) override
;
47 Status
ReadAllRegisterValues(lldb::WritableDataBufferSP
&data_sp
) override
;
49 Status
WriteAllRegisterValues(const lldb::DataBufferSP
&data_sp
) override
;
52 CopyHardwareWatchpointsFrom(NativeRegisterContextFreeBSD
&source
) override
;
55 std::array
<uint8_t, sizeof(reg
) + sizeof(vfp_state
)> m_reg_data
;
57 Status
ReadRegisterSet(uint32_t set
);
58 Status
WriteRegisterSet(uint32_t set
);
60 RegisterInfoPOSIX_arm
&GetRegisterInfo() const;
63 } // namespace process_freebsd
64 } // namespace lldb_private
66 #endif // #ifndef lldb_NativeRegisterContextFreeBSD_arm_h
68 #endif // defined (__arm__)