tcg/riscv: Implement vector cmp/cmpsel ops
authorTANG Tiancheng <tangtiancheng.ttc@alibaba-inc.com>
Mon, 7 Oct 2024 02:56:54 +0000 (10:56 +0800)
committerRichard Henderson <richard.henderson@linaro.org>
Tue, 22 Oct 2024 18:57:25 +0000 (11:57 -0700)
commita31768c0192a6f1f62d07c4985a77814be34a915
tree5924736e027687c72db5521dda3df2e85963e5c6
parent5a63f5998791460342ddc1fcd74db5909d00a2b9
tcg/riscv: Implement vector cmp/cmpsel ops

Extend comparison results from mask registers to SEW-width elements,
following recommendations in The RISC-V SPEC Volume I (Version 20240411).
This aligns with TCG's cmp_vec behavior by expanding compare results to
full element width: all 1s for true, all 0s for false.

Signed-off-by: TANG Tiancheng <tangtiancheng.ttc@alibaba-inc.com>
Reviewed-by: Liu Zhiwei <zhiwei_liu@linux.alibaba.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20241007025700.47259-7-zhiwei_liu@linux.alibaba.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
tcg/riscv/tcg-target-con-set.h
tcg/riscv/tcg-target-con-str.h
tcg/riscv/tcg-target.c.inc
tcg/riscv/tcg-target.h