From bf9a822b87ff362805ffefb8f76eea3c46f606a1 Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Wed, 5 Feb 2020 12:18:33 -0300 Subject: shader/decode: Fix constant buffer offsets Some instances were using cbuf34.offset instead of cbuf34.GetOffset(). This returned the an invalid offset. Address those instances and rename offset to "shifted_offset" to avoid future bugs. --- src/video_core/shader/decode/bfi.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/video_core/shader/decode/bfi.cpp') diff --git a/src/video_core/shader/decode/bfi.cpp b/src/video_core/shader/decode/bfi.cpp index f992bbe2a..70d1c055b 100644 --- a/src/video_core/shader/decode/bfi.cpp +++ b/src/video_core/shader/decode/bfi.cpp @@ -21,7 +21,7 @@ u32 ShaderIR::DecodeBfi(NodeBlock& bb, u32 pc) { switch (opcode->get().GetId()) { case OpCode::Id::BFI_RC: return {GetRegister(instr.gpr39), - GetConstBuffer(instr.cbuf34.index, instr.cbuf34.offset)}; + GetConstBuffer(instr.cbuf34.index, instr.cbuf34.GetOffset())}; case OpCode::Id::BFI_IMM_R: return {Immediate(instr.alu.GetSignedImm20_20()), GetRegister(instr.gpr39)}; default: -- cgit v1.2.3