From 8169d709c4c300e79426fdc2310de138c76d6ace Mon Sep 17 00:00:00 2001 From: Karol Herbst Date: Thu, 27 May 2021 00:24:10 +0200 Subject: [PATCH] nv50/ir: don't optimize shl(mul_hi, a) to mul_hi Fixes shader_storage_buffer_object.advanced-unsizedArrayLength* CTS tests Signed-off-by: Karol Herbst Reviewed-by: Ilia Mirkin Part-of: --- src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp index 3b85151939d..4e50d954daf 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_peephole.cpp @@ -1493,6 +1493,8 @@ ConstantFolding::opnd(Instruction *i, ImmediateValue &imm0, int s) int muls; if (isFloatType(si->dType)) return false; + if (si->subOp) + return false; if (si->src(1).getImmediate(imm1)) muls = 1; else if (si->src(0).getImmediate(imm1))