aco: Use std::vector for the underlying container of std::stack
authorTony Wasserka <tony.wasserka@gmx.de>
Sat, 10 Jul 2021 10:20:56 +0000 (12:20 +0200)
committerMarge Bot <eric+marge@anholt.net>
Fri, 1 Oct 2021 09:39:13 +0000 (09:39 +0000)
commit0812d440c7f6adbfe215f0373e241a7b65469415
treee18b55ac6c6c4a9d4b3eefda45ac277ce3f9a8d5
parentf81eb2a8276ea7ab7143e7e5de8457d4894b2901
aco: Use std::vector for the underlying container of std::stack

By default, std::stack uses std::deque to allocate its elements, which has
poor cache efficiency. std::vector makes appending elements more expensive
(due to potential reallocations), but in the changed contexts the element
count should always be low anyway.

Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11925>
src/amd/compiler/aco_insert_NOPs.cpp
src/amd/compiler/aco_insert_waitcnt.cpp
src/amd/compiler/aco_instruction_selection.cpp
src/amd/compiler/aco_spill.cpp