1 //===-- SWIG Interface for SBMemoryRegionInfo -------------------*- 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 namespace lldb { 10 11 %feature("docstring", 12 "API clients can get information about memory regions in processes." 13 ) SBMemoryRegionInfo; 14 15 class SBMemoryRegionInfo 16 { 17 public: 18 19 SBMemoryRegionInfo (); 20 21 SBMemoryRegionInfo (const lldb::SBMemoryRegionInfo &rhs); 22 23 SBMemoryRegionInfo::SBMemoryRegionInfo(const char *name, lldb::addr_t begin, 24 lldb::addr_t end, uint32_t permissions, bool mapped, bool stack_memory); 25 26 ~SBMemoryRegionInfo (); 27 28 void 29 Clear(); 30 31 lldb::addr_t 32 GetRegionBase (); 33 34 lldb::addr_t 35 GetRegionEnd (); 36 37 bool 38 IsReadable (); 39 40 bool 41 IsWritable (); 42 43 bool 44 IsExecutable (); 45 46 bool 47 IsMapped (); 48 49 const char * 50 GetName (); 51 52 %feature("autodoc", " 53 GetRegionEnd(SBMemoryRegionInfo self) -> lldb::addr_t 54 Returns whether this memory region has a list of modified (dirty) 55 pages available or not. When calling GetNumDirtyPages(), you will 56 have 0 returned for both \"dirty page list is not known\" and 57 \"empty dirty page list\" (that is, no modified pages in this 58 memory region). You must use this method to disambiguate.") HasDirtyMemoryPageList; 59 bool 60 HasDirtyMemoryPageList(); 61 62 %feature("autodoc", " 63 GetNumDirtyPages(SBMemoryRegionInfo self) -> uint32_t 64 Return the number of dirty (modified) memory pages in this 65 memory region, if available. You must use the 66 SBMemoryRegionInfo::HasDirtyMemoryPageList() method to 67 determine if a dirty memory list is available; it will depend 68 on the target system can provide this information.") GetNumDirtyPages; 69 uint32_t 70 GetNumDirtyPages(); 71 72 %feature("autodoc", " 73 GetDirtyPageAddressAtIndex(SBMemoryRegionInfo self, uint32_t idx) -> lldb::addr_t 74 Return the address of a modified, or dirty, page of memory. 75 If the provided index is out of range, or this memory region 76 does not have dirty page information, LLDB_INVALID_ADDRESS 77 is returned.") GetDirtyPageAddressAtIndex; 78 addr_t 79 GetDirtyPageAddressAtIndex(uint32_t idx); 80 81 %feature("autodoc", " 82 GetPageSize(SBMemoryRegionInfo self) -> int 83 Return the size of pages in this memory region. 0 will be returned 84 if this information was unavailable.") GetPageSize(); 85 int 86 GetPageSize(); 87 88 bool 89 operator == (const lldb::SBMemoryRegionInfo &rhs) const; 90 91 bool 92 operator != (const lldb::SBMemoryRegionInfo &rhs) const; 93 94 bool 95 GetDescription (lldb::SBStream &description); 96 97 STRING_EXTENSION(SBMemoryRegionInfo) 98 }; 99 100 } // namespace lldb 101