[llvm] [AMDGPU] Clear load addresses between functions (PR #102515)

Alexis Engelke via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 8 11:15:25 PDT 2024


https://github.com/aengelke created https://github.com/llvm/llvm-project/pull/102515

SLoadAddresses previously held data across different functions and used these for dominance queries of blocks in different functions. This is not intended; clear the state at the end of the pass.

>From 70766b08a378f94de7fe2d49a15364c4595ebcaf Mon Sep 17 00:00:00 2001
From: Alexis Engelke <engelke at in.tum.de>
Date: Thu, 8 Aug 2024 18:13:29 +0000
Subject: [PATCH] [AMDGPU] Clear load addresses between functions

SLoadAddresses previously held data across different functions and used
these for dominance queries of blocks in different functions. This is
not intended; clear the state at the end of the pass.
---
 llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp b/llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
index 1315aa08557888..59a1eee8d4f91d 100644
--- a/llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
+++ b/llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
@@ -2611,6 +2611,7 @@ bool SIInsertWaitcnts::runOnMachineFunction(MachineFunction &MF) {
     Modified = true;
   }
   ReleaseVGPRInsts.clear();
+  SLoadAddresses.clear();
 
   return Modified;
 }



More information about the llvm-commits mailing list