This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [cli] Bug fix for 64-bit machines
- From: Andreas Schwab <schwab at redhat dot com>
- To: Erven Rohou <erven dot rohou at inria dot fr>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Tue, 09 Feb 2010 14:33:04 +0100
- Subject: Re: [cli] Bug fix for 64-bit machines
- References: <4B71614A.1030500@inria.fr>
Erven Rohou <erven.rohou@inria.fr> writes:
> Index: config/cil32/emit-cil.c
> ===================================================================
> --- config/cil32/emit-cil.c (revision 156424)
> +++ config/cil32/emit-cil.c (working copy)
> @@ -1560,6 +1560,10 @@
>
> real_to_target (buf, &d, TYPE_MODE (type));
> real_to_decimal (string, &d, sizeof (string), 0, 1);
> + /* On 64-bit machines, we need to drop high 32 bits to print the
> + value properly. real_to_target guarantees that only 32 bits are
> + set, no matter the size of the host long. */
> + buf[1] &= 0xffffffffl;
Why do you need to mask out the top 32 bits when real_to_target was
supposed to clear them already?
Andreas.
--
Andreas Schwab, schwab@redhat.com
GPG Key fingerprint = D4E8 DBE3 3813 BB5D FA84 5EC7 45C6 250E 6F00 984E
"And now for something completely different."