[Lldb-commits] [lldb] [lldb][NFC] Make the target's SectionLoadList private. (PR #113278)

Greg Clayton via lldb-commits lldb-commits at lists.llvm.org
Thu Oct 24 14:23:17 PDT 2024


================
@@ -1140,9 +1140,13 @@ class Target : public std::enable_shared_from_this<Target>,
                              Address &pointer_addr,
                              bool force_live_memory = false);
 
-  SectionLoadList &GetSectionLoadList() {
-    return m_section_load_history.GetCurrentSectionLoadList();
-  }
+  bool HasLoadedSections();
+
+  lldb::addr_t GetSectionLoadAddress(const lldb::SectionSP &section_sp);
+
+  void ClearSectionLoadList();
----------------
clayborg wrote:

`GetSectionLoadAddress(...)` is called all over the place, but `ClearSectionLoadList()` is called only by `DynamicLoaderMacOS`, but it should be able to be called by any dynamic loader, so I wouldn't want to limit the ability to call it. And we can't tie it to a dynamic loader as I could see us wanting to add a command that would call this function for symbolication purposes. 

https://github.com/llvm/llvm-project/pull/113278


More information about the lldb-commits mailing list