[PATCH] D63489: [InstSimplify] LCSSA PHIs should not be simplified away
Alexander via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 18 07:55:27 PDT 2019
alex-t added a comment.
In D63489#1548288 <https://reviews.llvm.org/D63489#1548288>, @lebedev.ri wrote:
> > This causes generation of incorrect code in AMDGPU backend.
>
> This sounds like some other check is missing elsewhere?
> What happens if you feed it such an ir as-if after this transform, but manually written?
> ("that will result in broken asm/crashes" is hopefully not the answer)
>
> That being said, why is `LCSSAPass` not sufficient?
> It's already supposed to undo transforms like this.
Manually written IR w/o lcssa phis will result in syntactically correct asm and no crashes. In runtime we'll get incorrect result though :)
Adding LCSSA pass again later on is difficult in the sense of the pass dependencies.
So, it's better to fix the explicit bug in SimplifyPHI....
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D63489/new/
https://reviews.llvm.org/D63489
More information about the llvm-commits
mailing list