[AMDGPU] Revert scheduling to reduce spilling
authorStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Fri, 3 Jan 2020 21:19:51 +0000 (13:19 -0800)
committerStanislav Mekhanoshin <Stanislav.Mekhanoshin@amd.com>
Fri, 3 Jan 2020 23:20:21 +0000 (15:20 -0800)
commit4aa7fb77527bee74e93e7cd8242f016c0f229236
treee50300add5ba657fb60cc92e2353958aa774e058
parentd2b19d455de22fe3c8aa192320e1ff9a4eb1a365
[AMDGPU] Revert scheduling to reduce spilling

We can revert region schedule if new schedule decreases occupancy.
However, if we already have only one wave we would accept any new
schedule even if it blows up register pressure. Such schedule may
result in quite heavy spilling which can be avoided if we reject
this new schedule.

Differential Revision: https://reviews.llvm.org/D72181
llvm/lib/Target/AMDGPU/GCNSchedStrategy.cpp