From d285c63417ae2398d3321d14a54bb0c898e9838d Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Tue, 12 Apr 2022 21:41:34 -0400 Subject: [PATCH] agx: Add phi pseudo instruction For SSA. Signed-off-by: Alyssa Rosenzweig Part-of: --- src/asahi/compiler/agx_opcodes.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/asahi/compiler/agx_opcodes.py b/src/asahi/compiler/agx_opcodes.py index da4b48b6f5e..cb98bf6fc18 100644 --- a/src/asahi/compiler/agx_opcodes.py +++ b/src/asahi/compiler/agx_opcodes.py @@ -255,3 +255,7 @@ op("or", _, srcs = 2) op("p_combine", _, srcs = 4) op("p_split", _, srcs = 1, dests = 4) op("p_extract", _, srcs = 1, imms = [COMPONENT]) + +# Phis are special-cased in the IR as they (uniquely) can take an unbounded +# number of source. +op("phi", _, srcs = 0)