Skip to contentSkip to conversation

target/riscv: FCSR doesn't contain vxrm and vxsat

PATCH Applied LIU Zhiwei 3 participants 3 messages Jan 30, 2024 – Feb 5, 2024 RISC-V

lore
Share & tools
lore

LIU Zhiwei

author
#0 lore raw

PATCH 1/1 target/riscv: FCSR doesn't contain vxrm and vxsat

vxrm and vxsat have been moved into a special register vcsr since RVV v1.0. So remove them from FCSR for vector 1.0.

---
 target/riscv/cpu_bits.h | 8 --------
 1 file changed, 8 deletions(-)
target/riscv/cpu_bits.h +0 -8
index ebd7917d49..e116f6c252 100644
@@ -32,14 +32,6 @@
 #define FSR_NXA             (FPEXC_NX << FSR_AEXC_SHIFT)
 #define FSR_AEXC            (FSR_NVA | FSR_OFA | FSR_UFA | FSR_DZA | FSR_NXA)
 
-/* Vector Fixed-Point round model */
-#define FSR_VXRM_SHIFT      9
-#define FSR_VXRM            (0x3 << FSR_VXRM_SHIFT)
-
-/* Vector Fixed-Point saturation flag */
-#define FSR_VXSAT_SHIFT     8
-#define FSR_VXSAT           (0x1 << FSR_VXSAT_SHIFT)
-
 /* Control and Status Registers */
 
 /* User Trap Setup */
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 5 lines · LIU Zhiwei

vxrm and vxsat have been moved into a special register vcsr since RVV v1.0. So remove them from FCSR for vector 1.0.

---

Quoted 22 lines
  target/riscv/cpu_bits.h | 8 --------
  1 file changed, 8 deletions(-)
target/riscv/cpu_bits.h +0 -8
index ebd7917d49..e116f6c252 100644
@@ -32,14 +32,6 @@
  #define FSR_NXA             (FPEXC_NX << FSR_AEXC_SHIFT)
  #define FSR_AEXC            (FSR_NVA | FSR_OFA | FSR_UFA | FSR_DZA | FSR_NXA)
 
-/* Vector Fixed-Point round model */
-#define FSR_VXRM_SHIFT      9
-#define FSR_VXRM            (0x3 << FSR_VXRM_SHIFT)
-
-/* Vector Fixed-Point saturation flag */
-#define FSR_VXSAT_SHIFT     8
-#define FSR_VXSAT           (0x1 << FSR_VXSAT_SHIFT)
-
  /* Control and Status Registers */
 
  /* User Trap Setup */
#2 lore raw
In reply to LIU Zhiwei
Quoted 5 lines · LIU Zhiwei

vxrm and vxsat have been moved into a special register vcsr since RVV v1.0. So remove them from FCSR for vector 1.0.

Thanks!

Applied to riscv-to-apply.next

Alistair

Quoted 27 lines
---
 target/riscv/cpu_bits.h | 8 --------
 1 file changed, 8 deletions(-)
target/riscv/cpu_bits.h +0 -9
index ebd7917d49..e116f6c252 100644
@@ -32,14 +32,6 @@
 #define FSR_NXA             (FPEXC_NX << FSR_AEXC_SHIFT)
 #define FSR_AEXC            (FSR_NVA | FSR_OFA | FSR_UFA | FSR_DZA | FSR_NXA)
 
-/* Vector Fixed-Point round model */
-#define FSR_VXRM_SHIFT      9
-#define FSR_VXRM            (0x3 << FSR_VXRM_SHIFT)
-
-/* Vector Fixed-Point saturation flag */
-#define FSR_VXSAT_SHIFT     8
-#define FSR_VXSAT           (0x1 << FSR_VXSAT_SHIFT)
-
 /* Control and Status Registers */
 
 /* User Trap Setup */
--

2.25.1