[llvm] [IR]Support set/read/update the section prefix for global objects (PR #125757)

Ellis Hoag via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 4 17:49:04 PST 2025


================
@@ -124,6 +124,17 @@ class GlobalObject : public GlobalValue {
   /// appropriate default object file section.
   void setSection(StringRef S);
 
+  /// Set the section prefix for this global object.
+  void setSectionPrefix(StringRef Prefix);
+
+  /// Update the section prefix, unless the existing prefix is the same as
+  /// `KeepPrefix`.
+  void updateSectionPrefix(StringRef Prefix,
+                           std::optional<StringRef> KeepPrefix = std::nullopt);
----------------
ellishg wrote:

This function doesn't exist?

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


More information about the llvm-commits mailing list