AMDGPU: Add a test to show bad compilation to set_inactive
authorRuiling Song <ruiling.song@amd.com>
Thu, 6 Apr 2023 06:04:50 +0000 (14:04 +0800)
committerRuiling Song <ruiling.song@amd.com>
Fri, 7 Apr 2023 01:10:43 +0000 (09:10 +0800)
commitfc06a429aae137c086ca45e3537eccb0e8128698
tree8440b5d28612798be2a7482bab90c6ffb54a3500
parentbf9de4cf131032502c8967a65283a461fe36520d
AMDGPU: Add a test to show bad compilation to set_inactive

The set_inactive was originally inside a if branch, but was incorrectly
hoisted out of the loop. So the lanes that were disabled later after the
if() branch inside the loop were not set correctly. It should stay in
the if branch.

Differential Revision: https://reviews.llvm.org/D147682
llvm/test/CodeGen/AMDGPU/should-not-hoist-set-inactive.ll [new file with mode: 0644]