target/riscv: Include missing headers in '*internals.h'
cover target/riscv: Include missing headers in '*internals.h'
2 trivial RISC-V oriented patches extracted from a bigger series which refactor include/exec/ headers.
Philippe Mathieu-Daudé (2):
target/riscv: Include missing headers in 'vector_internals.h' target/riscv: Include missing headers in 'internals.h'
target/riscv/internals.h | 3 +++ target/riscv/vector_internals.h | 1 + 2 files changed, 4 insertions(+)
Signature · 1 line
2.45.2
PATCH 1/2 target/riscv: Include missing headers in 'vector_internals.h'
Rather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/vector_internals.h:36:12: error: call to undeclared function 'FIELD_EX32'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
36 | return FIELD_EX32(simd_data(desc), VDATA, NF);
| ^--- target/riscv/vector_internals.h | 1 + 1 file changed, 1 insertion(+)
target/riscv/vector_internals.h +1 -0
@@ -20,6 +20,7 @@#define TARGET_RISCV_VECTOR_INTERNALS_H #include "qemu/bitops.h" +#include "hw/registerfields.h" #include "cpu.h" #include "tcg/tcg-gvec-desc.h" #include "internals.h"
Signature · 1 line
2.45.2
Re: [PATCH 1/2] target/riscv: Include missing headers in 'vector_internals.h'
Quoted 9 lines · Philippe Mathieu-Daudé
Rather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/vector_internals.h:36:12: error: call to undeclared function 'FIELD_EX32'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]36 | return FIELD_EX32(simd_data(desc), VDATA, NF); | ^Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Quoted 15 lines
target/riscv/vector_internals.h | 1 + 1 file changed, 1 insertion(+)target/riscv/vector_internals.h +1
-0@@ -20,6 +20,7 @@#define TARGET_RISCV_VECTOR_INTERNALS_H #include "qemu/bitops.h" +#include "hw/registerfields.h" #include "cpu.h" #include "tcg/tcg-gvec-desc.h" #include "internals.h"
Re: [PATCH 1/2] target/riscv: Include missing headers in 'vector_internals.h'
In reply to Philippe Mathieu-DaudéQuoted 9 lines · Philippe Mathieu-Daudé
Rather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/vector_internals.h:36:12: error: call to undeclared function 'FIELD_EX32'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]36 | return FIELD_EX32(simd_data(desc), VDATA, NF); | ^Signed-off-by Philippe Mathieu-Daudé <[email protected]>
Alistair
Quoted 20 lines
--- target/riscv/vector_internals.h | 1 + 1 file changed, 1 insertion(+)target/riscv/vector_internals.h +1
-1@@ -20,6 +20,7 @@#define TARGET_RISCV_VECTOR_INTERNALS_H #include "qemu/bitops.h" +#include "hw/registerfields.h" #include "cpu.h" #include "tcg/tcg-gvec-desc.h" #include "internals.h" --2.45.2
PATCH 2/2 target/riscv: Include missing headers in 'internals.h'
In reply to Philippe Mathieu-DaudéRather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/internals.h:49:15: error: use of undeclared identifier 'PRV_S'
49 | ret = PRV_S;
| ^
target/riscv/internals.h:93:9: error: call to undeclared function 'env_archcpu'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
93 | if (env_archcpu(env)->cfg.ext_zfinx) {
| ^
target/riscv/internals.h:101:15: error: unknown type name 'float32'; did you mean 'float'?
101 | static inline float32 check_nanbox_s(CPURISCVState *env, uint64_t f)
| ^~~~~~~
| float--- target/riscv/internals.h | 3 +++ 1 file changed, 3 insertions(+)
target/riscv/internals.h +3 -0
@@ -19,7 +19,10 @@#ifndef RISCV_CPU_INTERNALS_H #define RISCV_CPU_INTERNALS_H +#include "exec/cpu-common.h" #include "hw/registerfields.h" +#include "fpu/softfloat-types.h" +#include "target/riscv/cpu_bits.h" /* * The current MMU Modes are:
Signature · 1 line
2.45.2
Re: [PATCH 2/2] target/riscv: Include missing headers in 'internals.h'
Quoted 14 lines · Philippe Mathieu-Daudé
Rather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/internals.h:49:15: error: use of undeclared identifier 'PRV_S'49 | ret = PRV_S; | ^ target/riscv/internals.h:93:9: error: call to undeclared function 'env_archcpu'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] 93 | if (env_archcpu(env)->cfg.ext_zfinx) { | ^ target/riscv/internals.h:101:15: error: unknown type name 'float32'; did you mean 'float'? 101 | static inline float32 check_nanbox_s(CPURISCVState *env, uint64_t f) | ^~~~~~~ | float
Quoted 2 lines
Signed-off-by Philippe Mathieu-Daudé <[email protected]>---
Quoted 18 lines
target/riscv/internals.h | 3 +++ 1 file changed, 3 insertions(+)target/riscv/internals.h +3
-0@@ -19,7 +19,10 @@#ifndef RISCV_CPU_INTERNALS_H #define RISCV_CPU_INTERNALS_H +#include "exec/cpu-common.h" #include "hw/registerfields.h" +#include "fpu/softfloat-types.h" +#include "target/riscv/cpu_bits.h" /* * The current MMU Modes are:
Re: [PATCH 2/2] target/riscv: Include missing headers in 'internals.h'
In reply to Philippe Mathieu-DaudéQuoted 15 lines · Philippe Mathieu-Daudé
Rather than relying on implicit includes, explicit them, in order to avoid when refactoring unrelated headers:
target/riscv/internals.h:49:15: error: use of undeclared identifier 'PRV_S'49 | ret = PRV_S; | ^ target/riscv/internals.h:93:9: error: call to undeclared function 'env_archcpu'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] 93 | if (env_archcpu(env)->cfg.ext_zfinx) { | ^ target/riscv/internals.h:101:15: error: unknown type name 'float32'; did you mean 'float'? 101 | static inline float32 check_nanbox_s(CPURISCVState *env, uint64_t f) | ^~~~~~~ | float
Quoted 1 line
Signed-off-by Philippe Mathieu-Daudé <[email protected]>
Alistair
Quoted 23 lines
--- target/riscv/internals.h | 3 +++ 1 file changed, 3 insertions(+)target/riscv/internals.h +3
-1@@ -19,7 +19,10 @@#ifndef RISCV_CPU_INTERNALS_H #define RISCV_CPU_INTERNALS_H +#include "exec/cpu-common.h" #include "hw/registerfields.h" +#include "fpu/softfloat-types.h" +#include "target/riscv/cpu_bits.h" /* * The current MMU Modes are: -- 2.45.2
Alistair Francis
AppliedQuoted 7 lines · Philippe Mathieu-Daudé
2 trivial RISC-V oriented patches extracted from a bigger series which refactor
include/exec/headers.Philippe Mathieu-Daudé (2):
target/riscv: Include missing headers in 'vector_internals.h' target/riscv: Include missing headers in 'internals.h'
Thanks!
Applied to riscv-to-apply.next
Alistair
Quoted 9 lines
target/riscv/internals.h | 3 +++ target/riscv/vector_internals.h | 1 + 2 files changed, 4 insertions(+)--
2.45.2