Skip to content

Commit 2942133

Browse files
bcheng0127igcbot
authored andcommitted
Add registry key for adding send GRF read cycle in scheduling
Add the key so that scheduler can consider the GRF read latency for send instructions _OS_DESCRIPTION
1 parent 0250ae1 commit 2942133

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

IGC/Compiler/CISACodeGen/CISABuilder.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5152,6 +5152,11 @@ namespace IGC
51525152
SaveOption(vISA_EnableGroupScheduleForBC, true);
51535153
}
51545154

5155+
if (IGC_IS_FLAG_ENABLED(SchedWithSendSrcReadCycle))
5156+
{
5157+
SaveOption(vISA_schedWithSendSrcReadCycle, true);
5158+
}
5159+
51555160
if (IGC_IS_FLAG_ENABLED(CopyA0ToDBG0))
51565161
{
51575162
SaveOption(vISA_CopyA0ToDBG0, true);

IGC/common/igc_flags.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ DECLARE_IGC_REGKEY(DWORD,EnableIndirectInstEnd, 0, "Enable the indir
8989
DECLARE_IGC_REGKEY(DWORD,EnableSWSBTokenBarrier, 0, "Enable force specific instruction as a barrier for software scoreboard generation", true)
9090
DECLARE_IGC_REGKEY(DWORD,SWSBTokenNum, 0, "Total tokens used for SWSB.", true)
9191
DECLARE_IGC_REGKEY(bool, EnableGroupScheduleForBC, false, "Enable bank conflict reduction in scheduling.", true)
92+
DECLARE_IGC_REGKEY(bool, SchedWithSendSrcReadCycle, false, "Scheduling with GRF read cycle from send.", true)
9293
DECLARE_IGC_REGKEY(bool, EnableIGASWSB, false, "Use IGA for SWSB", true)
9394
DECLARE_IGC_REGKEY(bool, EnableSWSBStitch, false, "Insert dependence resolve for kernel stitching", true)
9495
DECLARE_IGC_REGKEY(bool, DisableRegDistDep, false, "distable regDist dependence", true)

visa/LocalScheduler/LocalScheduler_G4IR.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2985,6 +2985,9 @@ uint32_t DDD::getEdgeLatency_old(Node *node, DepType depT) const {
29852985
}
29862986

29872987
if (depT <= NODEP || depT >= CONTROL_FLOW_BARRIER) {
2988+
if (kernel->fg.builder->modelSendSrcReadLatency() && inst->isSend()) {
2989+
return LT.getSendSrcReadLatency(inst);
2990+
}
29882991
return node->getOccupancy();
29892992
}
29902993

0 commit comments

Comments
 (0)