From: Richard Henderson Date: Fri, 27 Jun 2025 13:22:27 +0000 (-0700) Subject: tcg/riscv: Fix typo in tgen_extract X-Git-Tag: v10.1.0-rc0~39^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=169d253e1f25cc4adff6571e249222e422a4b07e;p=thirdparty%2Fqemu.git tcg/riscv: Fix typo in tgen_extract Fix the direction of the shift, introduced when converting the codebase to TCGOutOp* and small tgen_* helpers. Fixes: 5a4d034f3cb ("tcg: Convert extract to TCGOutOpExtract") Reported-by: Andrea Bolognani Signed-off-by: Richard Henderson Tested-by: Andrea Bolognani Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé --- diff --git a/tcg/riscv/tcg-target.c.inc b/tcg/riscv/tcg-target.c.inc index 1800fd5077e..31b9f7d87a0 100644 --- a/tcg/riscv/tcg-target.c.inc +++ b/tcg/riscv/tcg-target.c.inc @@ -2502,7 +2502,7 @@ static void tgen_extract(TCGContext *s, TCGType type, TCGReg a0, TCGReg a1, } } if (ofs + len == 32) { - tgen_shli(s, TCG_TYPE_I32, a0, a1, ofs); + tgen_shri(s, TCG_TYPE_I32, a0, a1, ofs); return; } if (len == 1) {