-
Notifications
You must be signed in to change notification settings - Fork 15.3k
[AMDGPU] Stop optimising readfirstlane in pass AMDGPUUniformIntrinsicCombine #166955
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -60,7 +60,6 @@ static bool optimizeUniformIntrinsic(IntrinsicInst &II, | |
|
|
||
| switch (IID) { | ||
| case Intrinsic::amdgcn_permlane64: | ||
| case Intrinsic::amdgcn_readfirstlane: | ||
| case Intrinsic::amdgcn_readlane: { | ||
| Value *Src = II.getArgOperand(0); | ||
| if (isDivergentUseWithNew(II.getOperandUse(0), UI, Tracker)) | ||
|
|
@@ -124,7 +123,6 @@ static bool runUniformIntrinsicCombine(Function &F, const UniformityInfo &UI) { | |
|
|
||
| switch (II->getIntrinsicID()) { | ||
| case Intrinsic::amdgcn_permlane64: | ||
| case Intrinsic::amdgcn_readfirstlane: | ||
| case Intrinsic::amdgcn_readlane: | ||
|
||
| case Intrinsic::amdgcn_ballot: | ||
| break; | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggest adding a comment here saying that we deliberately do not simplify readfirstlane with a uniform argument, so that frontends can use it to force a copy to SGPR and thereby prevent the backend from generating unwanted waterfall loops.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, will do that.