diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2024-12-11 15:31:04 +0000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2024-12-11 15:31:04 +0000 |
| commit | 1b2de0c3c08afdb27b24d9f03aa3ba7abca432c9 (patch) | |
| tree | a9c7d816276ea53be7e57d85077ed16cc5f21461 /rust/qemu-api/src | |
| parent | 47aa9001d8c88e75a20559d59f666878b77d1b16 (diff) | |
| download | focaccia-qemu-1b2de0c3c08afdb27b24d9f03aa3ba7abca432c9.tar.gz focaccia-qemu-1b2de0c3c08afdb27b24d9f03aa3ba7abca432c9.zip | |
fpu: Allow runtime choice of default NaN value
Currently we hardcode the default NaN value in parts64_default_nan() using a compile-time ifdef ladder. This is awkward for two cases: * for single-QEMU-binary we can't hard-code target-specifics like this * for Arm FEAT_AFP the default NaN value depends on FPCR.AH (specifically the sign bit is different) Add a field to float_status to specify the default NaN value; fall back to the old ifdef behaviour if these are not set. The default NaN value is specified by setting a uint8_t to a pattern corresponding to the sign and upper fraction parts of the NaN; the lower bits of the fraction are set from bit 0 of the pattern. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-id: 20241202131347.498124-35-peter.maydell@linaro.org
Diffstat (limited to 'rust/qemu-api/src')
0 files changed, 0 insertions, 0 deletions