aco: fix p_constaddr with a non-zero offset

Seems this broke a while ago and we never noticed.

Signed-off-by: Rhys Perry <pendingchaos02@gmail.com>
Reviewed-by: Daniel Schürmann <daniel@schuermann.dev>
Fixes: 0af7ff49fd ("aco: lower p_constaddr into separate instructions earlier")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16460>
This commit is contained in:
Rhys Perry
2022-05-11 19:23:00 +01:00
committed by Marge Bot
parent da49fee80f
commit bd8f8dda8c
3 changed files with 6 additions and 4 deletions
+1 -1
View File
@@ -222,7 +222,7 @@ BEGIN_TEST(assembler.long_jump.constaddr)
//! s_add_u32 s0, s0, 0xe0 ; 8000ff00 000000e0
bld.sop1(aco_opcode::p_constaddr_getpc, Definition(PhysReg(0), s2), Operand::zero());
bld.sop2(aco_opcode::p_constaddr_addlo, Definition(PhysReg(0), s1), bld.def(s1, scc),
Operand(PhysReg(0), s1), Operand::zero());
Operand(PhysReg(0), s1), Operand::zero(), Operand::zero());
program->blocks[2].linear_preds.push_back(0u);
program->blocks[2].linear_preds.push_back(1u);