[llvm] [AMDGPU] NFC: Add flag to disable clustered low occupancy phase (PR #73025)
Jeffrey Byrnes via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 21 10:51:28 PST 2023
https://github.com/jrbyrnes created https://github.com/llvm/llvm-project/pull/73025
This will help users analyze whether high register usage is coming from inability of scheduler to reduce RP, or from sacrificing good RP to improve ILP.
>From e198485ea485da7b9604d96535d928863ecf09a1 Mon Sep 17 00:00:00 2001
From: Jeffrey Byrnes <Jeffrey.Byrnes at amd.com>
Date: Tue, 21 Nov 2023 09:43:15 -0800
Subject: [PATCH] [AMDGPU] NFC: Add flag to disable clusterd low occupancy
phase
---
llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp b/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
index c3d60b635d3240a..6c044cae0d17f5b 100644
--- a/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
+++ b/llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp
@@ -37,6 +37,13 @@ static cl::opt<bool> DisableUnclusterHighRP(
cl::desc("Disable unclustered high register pressure "
"reduction scheduling stage."),
cl::init(false));
+
+static cl::opt<bool> DisableClusteredLowOccupancy(
+ "amdgpu-disable-clustered-low-occupancy-reschedule", cl::Hidden,
+ cl::desc("Disable clustered low occupancy "
+ "rescheduling for ILP scheduling stage."),
+ cl::init(false));
+
static cl::opt<unsigned> ScheduleMetricBias(
"amdgpu-schedule-metric-bias", cl::Hidden,
cl::desc(
@@ -726,6 +733,9 @@ bool UnclusteredHighRPStage::initGCNSchedStage() {
}
bool ClusteredLowOccStage::initGCNSchedStage() {
+ if (DisableClusteredLowOccupancy)
+ return false;
+
if (!GCNSchedStage::initGCNSchedStage())
return false;
More information about the llvm-commits
mailing list