mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
target/riscv: Add support for Zvfbfwma extension
Add trans_* and helper function for Zvfbfwma instructions. Signed-off-by: Weiwei Li <liweiwei@iscas.ac.cn> Signed-off-by: Junqiang Wang <wangjunqiang@iscas.ac.cn> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20230615063302.102409-5-liweiwei@iscas.ac.cn> Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
This commit is contained in:
parent
87b27bfca4
commit
adf772b0f7
4 changed files with 76 additions and 0 deletions
|
@ -3554,6 +3554,17 @@ RVVCALL(OPFVF3, vfwmacc_vf_w, WOP_UUU_W, H8, H4, fwmacc32)
|
|||
GEN_VEXT_VF(vfwmacc_vf_h, 4)
|
||||
GEN_VEXT_VF(vfwmacc_vf_w, 8)
|
||||
|
||||
static uint32_t fwmaccbf16(uint16_t a, uint16_t b, uint32_t d, float_status *s)
|
||||
{
|
||||
return float32_muladd(bfloat16_to_float32(a, s),
|
||||
bfloat16_to_float32(b, s), d, 0, s);
|
||||
}
|
||||
|
||||
RVVCALL(OPFVV3, vfwmaccbf16_vv, WOP_UUU_H, H4, H2, H2, fwmaccbf16)
|
||||
GEN_VEXT_VV_ENV(vfwmaccbf16_vv, 4)
|
||||
RVVCALL(OPFVF3, vfwmaccbf16_vf, WOP_UUU_H, H4, H2, fwmacc16)
|
||||
GEN_VEXT_VF(vfwmaccbf16_vf, 4)
|
||||
|
||||
static uint32_t fwnmacc16(uint16_t a, uint16_t b, uint32_t d, float_status *s)
|
||||
{
|
||||
return float32_muladd(float16_to_float32(a, true, s),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue