[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 05/76] target/arm: Use uint32_t in vfp_exceptbits_from_host()
From: |
Peter Maydell |
Subject: |
[PATCH 05/76] target/arm: Use uint32_t in vfp_exceptbits_from_host() |
Date: |
Fri, 24 Jan 2025 16:27:25 +0000 |
In vfp_exceptbits_from_host(), we accumulate the FPSR flags in
an "int", and our return type is also "int". However, the only
callsite returns the same information as a uint32_t, and
more generally we handle FPSR values in the code as uint32_t,
not int. Bring this function in to line with that convention.
There is no behaviour change because none of the FPSR bits
we set in this function are bit 31. The input argument to
the function remains 'int' because that is the return type
of the softfloat get_float_exception_flags().
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
target/arm/vfp_helper.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/target/arm/vfp_helper.c b/target/arm/vfp_helper.c
index fcc9e5d382e..afc41420eb1 100644
--- a/target/arm/vfp_helper.c
+++ b/target/arm/vfp_helper.c
@@ -34,9 +34,9 @@
#ifdef CONFIG_TCG
/* Convert host exception flags to vfp form. */
-static inline int vfp_exceptbits_from_host(int host_bits)
+static inline uint32_t vfp_exceptbits_from_host(int host_bits)
{
- int target_bits = 0;
+ uint32_t target_bits = 0;
if (host_bits & float_flag_invalid) {
target_bits |= FPSR_IOC;
--
2.34.1
- [PATCH 00/76] target/arm: Implement FEAT_AFP and FEAT_RPRES, Peter Maydell, 2025/01/24
- [PATCH 04/76] target/arm: Use FPSR_ constants in vfp_exceptbits_from_host(), Peter Maydell, 2025/01/24
- [PATCH 03/76] target/arm: arm_reset_sve_state() should set FPSR, not FPCR, Peter Maydell, 2025/01/24
- [PATCH 09/76] target/arm: Use fp_status_a32 in vfp_cmp helpers, Peter Maydell, 2025/01/24
- [PATCH 01/76] target/i386: Do not raise Invalid for 0 * Inf + QNaN, Peter Maydell, 2025/01/24
- [PATCH 05/76] target/arm: Use uint32_t in vfp_exceptbits_from_host(),
Peter Maydell <=
- [PATCH 13/76] target/arm: Define new fp_status_f16_a32 and fp_status_f16_a64, Peter Maydell, 2025/01/24
- [PATCH 02/76] tests/tcg/x86_64/fma: Test some x86 fused-multiply-add cases, Peter Maydell, 2025/01/24
- [PATCH 12/76] target/arm: Remove now-unused vfp.fp_status and FPST_FPCR, Peter Maydell, 2025/01/24
- [PATCH 10/76] target/arm: Use FPST_FPCR_A32 in A32 decoder, Peter Maydell, 2025/01/24