[llvm] [AArch64][MachineCombiner] Combine sequences of gather patterns (PR #152979)

Jonathan Cohen via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 17 01:57:04 PDT 2025


================
@@ -7412,11 +7413,347 @@ static bool getMiscPatterns(MachineInstr &Root,
   return false;
 }
 
+/// Check if there are any stores or calls between two instructions in the same
+/// basic block.
+static bool hasInterveningStoreOrCall(const MachineInstr *First,
----------------
jcohen-apple wrote:

Sure. I was reluctant to add it initially because I didn't want to add AliasAnalysis as a dependency of MachineCombiner just for this pattern, but it seems to catch all the problematic patterns without it. Updated with an additional commit.

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


More information about the llvm-commits mailing list