nak: Allows predicate in legalize_ext_instr

With OpLd now having a predicate, we forgot to update legalize_ext_instr
to allow predicates for it.

We should really get ride of those functions but for now let's keep it
simple and sync the implementation to what SM20 backend have.

Signed-off-by: Mary Guillemard <mary@mary.zone>
Fixes: 9d90cbc314 ("nak: add input predicate to load_global_nv and OpLd")
Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40934>
This commit is contained in:
Mary Guillemard 2026-04-13 19:25:41 +02:00 committed by Marge Bot
parent 0f56fd0120
commit 3be57aa4c3
2 changed files with 2 additions and 2 deletions

View file

@ -2503,7 +2503,7 @@ fn legalize_ext_instr(op: &mut impl SrcsAsSlice, _b: &mut LegalizeBuilder) {
panic!("ALU srcs must be legalized explicitly");
}
SrcType::Pred => {
panic!("Predicates must be legalized explicitly");
assert!(src_is_reg(src, RegFile::Pred));
}
SrcType::Carry => {
panic!("Carry values must be legalized explicitly");

View file

@ -449,7 +449,7 @@ fn legalize_ext_instr(op: &mut impl SrcsAsSlice, _b: &mut LegalizeBuilder) {
panic!("ALU srcs must be legalized explicitly");
}
SrcType::Pred => {
panic!("Predicates must be legalized explicitly");
assert!(src_is_reg(src, RegFile::Pred));
}
SrcType::Carry => {
panic!("Carry values must be legalized explicitly");