aco: don't create sendmsg(dealloc_vgprs) if scratch is used
authorRhys Perry <pendingchaos02@gmail.com>
Fri, 11 Aug 2023 19:58:32 +0000 (20:58 +0100)
committerMarge Bot <emma+marge@anholt.net>
Tue, 15 Aug 2023 11:00:31 +0000 (11:00 +0000)
commitc9b177db0e51c96a297466ba2fc8a9b6a11e124f
treeff66a6805c6a4ed0f330a3ec0390ec60b194add9
parenta02b5138a71209526d38645a209d88ead4a0168f
aco: don't create sendmsg(dealloc_vgprs) if scratch is used

LLVM does something similar: https://reviews.llvm.org/D153295

fossil-db (gfx1100):
Totals from 21 (0.02% of 133461) affected shaders:
Instrs: 147428 -> 147396 (-0.02%)
CodeSize: 797188 -> 797060 (-0.02%)

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Fixes: 2930317cea53 ("aco/gfx11: deallocate VGPRs at the end of the shader")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24669>
src/amd/compiler/aco_ir.cpp
src/amd/compiler/aco_ir.h
src/amd/compiler/aco_live_var_analysis.cpp