aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChih-Min Chao <chihmin.chao@sifive.com>2019-09-16 00:33:43 -0700
committerChih-Min Chao <chihmin.chao@sifive.com>2019-10-29 21:19:10 -0700
commit530b2d1d582d7cef7ab415570e72d1c0994307a9 (patch)
treeedceff433003bf00aad23310ae116a092d659837
parenta6dfd4e40f81db14e58908e7ced34dbd729c15a2 (diff)
downloadspike-530b2d1d582d7cef7ab415570e72d1c0994307a9.zip
spike-530b2d1d582d7cef7ab415570e72d1c0994307a9.tar.gz
spike-530b2d1d582d7cef7ab415570e72d1c0994307a9.tar.bz2
rvv: fix floating-point exception for comparison
don't use quiet api Signed-off-by: Chih-Min Chao <chihmin.chao@sifive.com>
-rw-r--r--riscv/decode.h1
-rw-r--r--riscv/insns/vmfge_vf.h2
-rw-r--r--riscv/insns/vmfgt_vf.h2
-rw-r--r--riscv/insns/vmfle_vv.h2
-rw-r--r--riscv/insns/vmflt_vf.h2
-rw-r--r--riscv/insns/vmflt_vv.h2
6 files changed, 6 insertions, 5 deletions
diff --git a/riscv/decode.h b/riscv/decode.h
index 7ecd74f..39eb3ba 100644
--- a/riscv/decode.h
+++ b/riscv/decode.h
@@ -1673,6 +1673,7 @@ for (reg_t i = 0; i < vlmax; ++i) { \
#define VI_VFP_LOOP_CMP(BODY) \
VI_VFP_LOOP_CMP_BASE \
BODY; \
+ set_fp_exceptions; \
DEBUG_RVV_FP_VV; \
VI_VFP_LOOP_CMP_END \
diff --git a/riscv/insns/vmfge_vf.h b/riscv/insns/vmfge_vf.h
index 7eade89..52531cb 100644
--- a/riscv/insns/vmfge_vf.h
+++ b/riscv/insns/vmfge_vf.h
@@ -1,5 +1,5 @@
// vfge.vf vd, vs2, rs1
VI_VFP_LOOP_CMP
({
- res = f32_le_quiet(rs1, vs2);
+ res = f32_le(rs1, vs2);
})
diff --git a/riscv/insns/vmfgt_vf.h b/riscv/insns/vmfgt_vf.h
index 6115d06..46ec5d4 100644
--- a/riscv/insns/vmfgt_vf.h
+++ b/riscv/insns/vmfgt_vf.h
@@ -1,5 +1,5 @@
// vfgt.vf vd, vs2, rs1
VI_VFP_LOOP_CMP
({
- res = f32_lt_quiet(rs1, vs2);
+ res = f32_lt(rs1, vs2);
})
diff --git a/riscv/insns/vmfle_vv.h b/riscv/insns/vmfle_vv.h
index c716312..2268542 100644
--- a/riscv/insns/vmfle_vv.h
+++ b/riscv/insns/vmfle_vv.h
@@ -1,5 +1,5 @@
// vfle.vv vd, vs2, rs1
VI_VFP_LOOP_CMP
({
- res = f32_le_quiet(vs2, vs1);
+ res = f32_le(vs2, vs1);
})
diff --git a/riscv/insns/vmflt_vf.h b/riscv/insns/vmflt_vf.h
index af436e4..70847a1 100644
--- a/riscv/insns/vmflt_vf.h
+++ b/riscv/insns/vmflt_vf.h
@@ -1,5 +1,5 @@
// vflt.vf vd, vs2, rs1
VI_VFP_LOOP_CMP
({
- res = f32_lt_quiet(vs2, rs1);
+ res = f32_lt(vs2, rs1);
})
diff --git a/riscv/insns/vmflt_vv.h b/riscv/insns/vmflt_vv.h
index ded867d..97784c0 100644
--- a/riscv/insns/vmflt_vv.h
+++ b/riscv/insns/vmflt_vv.h
@@ -1,5 +1,5 @@
// vflt.vv vd, vs2, vs1
VI_VFP_LOOP_CMP
({
- res = f32_lt_quiet(vs2, vs1);
+ res = f32_lt(vs2, vs1);
})