Add vtype.vill FIELD macro definition
PATCH 1/1 target/riscv: add VILL field for vtype register macro definition
In reply to Chao Liu--- target/riscv/cpu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
target/riscv/cpu.h +2 -1
@@ -170,7 +170,8 @@ FIELD(VTYPE, VSEW, 3, 3) FIELD(VTYPE, VTA, 6, 1) FIELD(VTYPE, VMA, 7, 1) FIELD(VTYPE, VEDIV, 8, 2) -FIELD(VTYPE, RESERVED, 10, sizeof(target_ulong) * 8 - 11) +FIELD(VTYPE, RESERVED, 10, sizeof(target_ulong) * 8 - 12) +FIELD(VTYPE, VILL, 63, 1) typedef struct PMUCTRState { /* Current value of a counter */
Signature · 1 line
2.47.0
cover Add vtype.vill FIELD macro definition
Hi, all:
According to the "The RISC-V Instruction Set Manual Volume I: Unprivileged Architecture" Version 20240411, Section 31.3.4 "Vector type register, vtype", and Table 40 "vtype register layout", this patch adds the definition for the vill field of the vtype register. The bit position for vill is [63].
This change ensures that our implementation remains in line with the latest RISC-V specifications, thereby maintaining compatibility and correctness.
Chao Liu (1):
target/riscv: add VILL field for vtype register macro definition
target/riscv/cpu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Signature · 1 line
2.47.0
Re: [PATCH v1 1/1] target/riscv: add VILL field for vtype register macro definition
In reply to Chao LiuQuoted 10 lines · Chao Liu
Signed-off-by Chao Liu <[email protected]>--- target/riscv/cpu.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)target/riscv/cpu.h +0
-0
target/riscv/cpu.h FIELD(VTYPE, VSEW, 3, 3) · line 174
Quoted 6 lines
target/riscv/cpu.h +2
-1@@ -170,7 +170,8 @@ FIELD(VTYPE, VSEW, 3, 3) FIELD(VTYPE, VTA, 6, 1) FIELD(VTYPE, VMA, 7, 1) FIELD(VTYPE, VEDIV, 8, 2) -FIELD (VTYPE ,RESERVED ,10 ,sizeof (target_ulong) *8 -11 ) +FIELD(VTYPE, RESERVED, 10, sizeof(target_ulong) * 8 - 12) +FIELD (VTYPE ,VILL ,63 ,1 )
It's 63 for rv64, but it's 31 for rv32.
We handle this one manually.
r~