qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 25/72] softfloat: Rearrange FloatParts64


From: Richard Henderson
Subject: Re: [PATCH 25/72] softfloat: Rearrange FloatParts64
Date: Tue, 11 May 2021 10:04:15 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1

On 5/11/21 8:57 AM, Alex Bennée wrote:
+    union {
+        /* Routines that know the structure may reference the singular name. */
+        uint64_t frac;
+        /*
+         * Routines expanded with multiple structures reference "hi" and "lo".
+         * In this structure, the one word is both highest and lowest.
+         */
+        uint64_t frac_hi;
+        uint64_t frac_lo;

This confuses me. Is this because it could be frac_hi or frac_lo at the
"top" of the structure because of endian issues?

Nothing about endianness. There is exactly one element, so it is both the "first" and "last", both "high" and "low".

Generic code will examine the "high" word when looking at overflow and things related, and the "low" word when doing rounding.

This anonymous union gives the same element 3 different names.

r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]