Page MenuHomePhabricator

[AMDGPU] Avoid unnecessary graph visits during WQM marking
ClosedPublic

Authored by critson on Mar 17 2021, 4:24 AM.

Details

Summary

Avoid revisiting nodes with the same set of defined lanes by
using a unified visited set which integrates lanes into the key.
This retains the intent of the original code by still revisiting
a subgraph if a different set of lanes is defined and hence
marking might progress differently.

Note: default size of the visited set has been confirmed to
cover >99% of invocations in large array of test shaders.

Diff Detail

Event Timeline

critson created this revision.Mar 17 2021, 4:24 AM
critson requested review of this revision.Mar 17 2021, 4:24 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 17 2021, 4:24 AM
foad added a comment.Mar 17 2021, 4:40 AM

Looks reasonable.

llvm/lib/Target/AMDGPU/SIWholeQuadMode.cpp
350

Remove = VisitKey?

critson updated this revision to Diff 331232.Mar 17 2021, 4:59 AM
  • Address reviewer comments.
piotr accepted this revision.Mar 17 2021, 6:37 AM
This revision is now accepted and ready to land.Mar 17 2021, 6:37 AM