[llvm] [AArch64] Enable GlobalMerge on externals (PR #158592)
Sjoerd Meijer via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 15 02:57:03 PDT 2025
================
@@ -694,12 +694,6 @@ bool AArch64PassConfig::addPreISel() {
// is disabled as we emit the .subsections_via_symbols directive which
// means that merging extern globals is not safe.
bool MergeExternalByDefault = !TM->getTargetTriple().isOSBinFormatMachO();
-
- // FIXME: extern global merging is only enabled when we optimise for size
- // because there are some regressions with it also enabled for performance.
----------------
sjoerdmeijer wrote:
I was going to ask about these "some regressions", but did a git blame first and noticed I contributed this, so yes, that's funny and I can't remember what they were. Does this ring a bell to you, @davemgreen ? If I had to take a guess, then I did some measurements on smaller A-cores, i.e. not the wide X or Neoverse cores we have today. You did mention that it didn't affect perf very much. I am fine with the change, but my only question out of curiousity is which cores you've tested.
https://github.com/llvm/llvm-project/pull/158592
More information about the llvm-commits
mailing list