[llvm] [AMDGPU] Rewrite GFX12 SGPR hazard handling to dedicated pass (PR #118750)
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 22 03:47:48 PST 2025
================
@@ -1670,6 +1672,8 @@ void GCNPassConfig::addPreEmitPass() {
// cases.
addPass(&PostRAHazardRecognizerID);
+ addPass(&AMDGPUWaitSGPRHazardsLegacyID);
----------------
jayfoad wrote:
> In theory InsertDelayAlu can adjust s_delay_alu settings based on presence of s_wait_alu instructions
Yes `AMDGPUInsertDelayAlu` does account for this, in that it knows that an extra `s_wait_alu` instruction will cause an extra single cycle issue delay which can avoid the need for an `s_delay_alu`. This does happen in some cases; see inline comment.
https://github.com/llvm/llvm-project/pull/118750
More information about the llvm-commits
mailing list