agx: Make partial DCE optional

Our dead code elimination pass does two things:

1. delete instructions that are entirely unnecessary
2. delete unnecessary destinations of necessary instructions

To deal with pass ordering issues, we sometimes want to do #1 without #2.

Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21674>
This commit is contained in:
Alyssa Rosenzweig
2023-03-03 00:12:00 -05:00
committed by Marge Bot
parent 16f8bfb042
commit 5ea9c2e634
4 changed files with 9 additions and 11 deletions
+1 -1
View File
@@ -29,7 +29,7 @@ static void
agx_optimize_and_dce(agx_context *ctx)
{
agx_optimizer(ctx);
agx_dce(ctx);
agx_dce(ctx, true);
}
#define CASE(instr, expected, size) \