target/loongarch: Use actual operand size with vbsrl check
authorBibo Mao <maobibo@loongson.cn>
Thu, 12 Dec 2024 08:22:34 +0000 (16:22 +0800)
committerBibo Mao <maobibo@loongson.cn>
Fri, 27 Dec 2024 03:32:33 +0000 (11:32 +0800)
commitd41989e7548397b469ec9c7be4cee699321a317e
tree2c4b058d06f324eb1c6411475f4ee71b37a3aeea
parent02ce6cea71be4f6774351f5e658d50044c5b53b2
target/loongarch: Use actual operand size with vbsrl check

Hardcoded 32 bytes is used for vbsrl emulation check, there is
problem when options lsx=on,lasx=off is used for vbsrl.v instruction
in TCG mode. It injects LASX exception rather LSX exception.

Here actual operand size is used.

Cc: qemu-stable@nongnu.org
Fixes: df97f338076 ("target/loongarch: Implement xvreplve xvinsve0 xvpickve")
Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
target/loongarch/tcg/insn_trans/trans_vec.c.inc