Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Mar 2010 13:30:11 GMT
From:      Marius Strobl <marius@alchemy.franken.de>
To:        freebsd-sparc64@FreeBSD.org
Subject:   Re: sparc64/144900: [patch] SPARC64 Floating point fixes
Message-ID:  <201003211330.o2LDUBgA062577@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR sparc64/144900; it has been noted by GNATS.

From: Marius Strobl <marius@alchemy.franken.de>
To: Peter Jeremy <peterjeremy@acm.org>
Cc: FreeBSD-gnats-submit@freebsd.org
Subject: Re: sparc64/144900: [patch] SPARC64 Floating point fixes
Date: Sun, 21 Mar 2010 14:25:51 +0100

 On Sun, Mar 21, 2010 at 11:28:32AM +1100, Peter Jeremy wrote:
 > On 2010-Mar-20 21:49:41 +0100, Marius Strobl <marius@alchemy.franken.de> wrote:
 > >On Sat, Mar 20, 2010 at 08:11:20PM +1100, Peter Jeremy wrote:
 > >> - Parts of the emulator code must be compiled with no-strict-aliasing
 > >>   specified to function correctly.  CFLAGS is updated to include the
 > >>   relevant gcc option.  (This will add -fno-strict-aliasing to all of
 > >>   libc - which is excessive but I don't believe it's possible to compile
 > >>   only part of libc that way).
 > >
 > >Could you please elaborate on what exactly breaks when compiling
 > >with strict aliasing rules? I think there actually is a way to
 > >limit -no-strict-aliasing to the emulator part but I'd like to
 > >understand what's going on and make sure there's no way it can
 > >be solved by the code affected before turning it on.
 > 
 > OK.  I spent some time looking at fpu_explode.c and came up with the
 > attached patch which seems to remove the requirement for 
 > no-strict-aliasing (and I think the code looks cleaner as well).
 
 Thanks; I've decided to go that route instead of adding
 -fno-strict-aliasing as the code seems to be otherwise fine when
 it comes to strict aliasing rules, i.e. the type-punning used in
 fpu_qp.c is safe according to the GCC documentation.
 
 Marius
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201003211330.o2LDUBgA062577>