[AMDGPU] Consolidate one more getGeneration check
authorJay Foad <jay.foad@amd.com>
Tue, 29 Oct 2019 17:11:21 +0000 (17:11 +0000)
committerJay Foad <jay.foad@amd.com>
Wed, 30 Oct 2019 11:16:42 +0000 (11:16 +0000)
This one should have been done in r363902 when hasReadVCCZBug was
introduced.

llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp

index e84e948..6a688b7 100644 (file)
@@ -1393,7 +1393,7 @@ bool SIInsertWaitcnts::insertWaitcntInBlock(MachineFunction &MF,
       if (ScoreBrackets.getScoreLB(LGKM_CNT) <
               ScoreBrackets.getScoreUB(LGKM_CNT) &&
           ScoreBrackets.hasPendingEvent(SMEM_ACCESS)) {
-        if (ST->getGeneration() <= AMDGPUSubtarget::SEA_ISLANDS)
+        if (ST->hasReadVCCZBug())
           VCCZBugWorkAround = true;
       }
     }