Skip to content

Commit 3118efc

Browse files
committed
Clear RP trackers at beginning of analysis.
1 parent 4511613 commit 3118efc

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

llvm/lib/Target/AMDGPU/AMDGPURegPressAnalysis.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ AMDGPURegPressAnalysis::getPressure(const MachineBasicBlock *MBB) const {
3737
}
3838

3939
bool AMDGPURegPressAnalysis::runOnMachineFunction(MachineFunction &MF) {
40+
41+
// Reset trackers, or else they will carry across shaders in a pipeline.
42+
BlockPressure.clear();
43+
MaxPressure.clear();
44+
4045
if (skipFunction(MF.getFunction()))
4146
return false;
4247

0 commit comments

Comments
 (0)