LLDB  mainline
RegisterContextPOSIXProcessMonitor_powerpc.h
Go to the documentation of this file.
1 //===-- RegisterContextPOSIXProcessMonitor_powerpc.h -------------*- C++
2 //-*-===//
3 //
4 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
5 // See https://llvm.org/LICENSE.txt for license information.
6 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //
8 //===----------------------------------------------------------------------===//
9 
10 #ifndef liblldb_RegisterContextPOSIXProcessMonitor_powerpc_H_
11 #define liblldb_RegisterContextPOSIXProcessMonitor_powerpc_H_
12 
14 #include "RegisterContextPOSIX.h"
15 
19 public:
21  lldb_private::Thread &thread, uint32_t concrete_frame_idx,
23 
24 protected:
25  bool IsVMX();
26 
27  bool ReadGPR() override;
28 
29  bool ReadFPR() override;
30 
31  bool ReadVMX() override;
32 
33  bool WriteGPR() override;
34 
35  bool WriteFPR() override;
36 
37  bool WriteVMX() override;
38 
39  // lldb_private::RegisterContext
40  bool ReadRegister(const unsigned reg, lldb_private::RegisterValue &value);
41 
42  bool WriteRegister(const unsigned reg,
43  const lldb_private::RegisterValue &value);
44 
45  bool ReadRegister(const lldb_private::RegisterInfo *reg_info,
46  lldb_private::RegisterValue &value) override;
47 
48  bool WriteRegister(const lldb_private::RegisterInfo *reg_info,
49  const lldb_private::RegisterValue &value) override;
50 
51  bool ReadAllRegisterValues(lldb::DataBufferSP &data_sp) override;
52 
53  bool WriteAllRegisterValues(const lldb::DataBufferSP &data_sp) override;
54 
55  uint32_t SetHardwareWatchpoint(lldb::addr_t addr, size_t size, bool read,
56  bool write) override;
57 
58  bool ClearHardwareWatchpoint(uint32_t hw_index) override;
59 
60  bool HardwareSingleStep(bool enable) override;
61 
62  // POSIXBreakpointProtocol
63  bool UpdateAfterBreakpoint() override;
64 
65  unsigned GetRegisterIndexFromOffset(unsigned offset) override;
66 
67  bool IsWatchpointHit(uint32_t hw_index) override;
68 
69  bool ClearWatchpointHits() override;
70 
71  lldb::addr_t GetWatchpointAddress(uint32_t hw_index) override;
72 
73  bool IsWatchpointVacant(uint32_t hw_index) override;
74 
75  bool SetHardwareWatchpointWithIndex(lldb::addr_t addr, size_t size, bool read,
76  bool write, uint32_t hw_index) override;
77 
79 
80 private:
82 };
83 
84 #endif
Extends RegisterClass with a few virtual operations useful on POSIX.
Manages communication with the inferior (debugee) process.
bool ReadRegister(const unsigned reg, lldb_private::RegisterValue &value)
bool SetHardwareWatchpointWithIndex(lldb::addr_t addr, size_t size, bool read, bool write, uint32_t hw_index) override
unsigned GetRegisterIndexFromOffset(unsigned offset) override
Determines the index in lldb's register file given a kernel byte offset.
RegisterContextPOSIXProcessMonitor_powerpc(lldb_private::Thread &thread, uint32_t concrete_frame_idx, lldb_private::RegisterInfoInterface *register_info)
bool ReadRegister(const lldb_private::RegisterInfo *reg_info, lldb_private::RegisterValue &value) override
uint32_t SetHardwareWatchpoint(lldb::addr_t addr, size_t size, bool read, bool write) override
bool UpdateAfterBreakpoint() override
Updates the register state of the associated thread after hitting a breakpoint (if that make sense fo...
bool WriteAllRegisterValues(const lldb::DataBufferSP &data_sp) override
bool WriteRegister(const lldb_private::RegisterInfo *reg_info, const lldb_private::RegisterValue &value) override
bool WriteRegister(const unsigned reg, const lldb_private::RegisterValue &value)
RegisterInfo interface to patch RegisterInfo structure for archs.
uint64_t addr_t
Definition: lldb-types.h:83