[llvm-branch-commits] [llvm] [PowerPC][GlobalMerge] Reduce TOC usage by merging internal and private global data (PR #101224)

Chen Zheng via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Tue Jul 30 18:41:33 PDT 2024


================
@@ -28,6 +28,10 @@ struct GlobalMergeOptions {
   bool MergeConst = false;
   /// Whether we should merge global variables that have external linkage.
   bool MergeExternal = true;
+  /// Whether we should merge global variables that have private linkage.
+  bool MergePrivateGlobals = false;
----------------
chenzheng1030 wrote:

+1

Like the internal global variables, private global variables should always be merged and should not be guarded under an option. You've already done this in https://github.com/llvm/llvm-project/pull/101222 :)

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


More information about the llvm-branch-commits mailing list