public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
* middle-end/9009: floating-point negate and abs optimizations incorrect for ARM
@ 2002-12-19  9:36 rearnsha
  0 siblings, 0 replies; 2+ messages in thread
From: rearnsha @ 2002-12-19  9:36 UTC (permalink / raw)
  To: gcc-gnats; +Cc: roger


>Number:         9009
>Category:       middle-end
>Synopsis:       floating-point negate and abs optimizations incorrect for ARM
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Dec 19 09:36:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     Richard Earnshaw
>Release:        unknown-1.0
>Organization:
>Environment:
arm-elf cross
>Description:
Testsuite gcc.c-torture/exectue/930614-1.c fails after this patch:

2002-12-07  Roger Sayle  <roger@eyesopen.com>

        * real.h (real_format): Add signbit field.
        * real.c (ieee_single_format, ieee_double_format,
        ieee_extended_motorola_format, ieee_extended_intel_96_format,
        ieee_extended_intel_128_format, ibm_extended_format,
        ieee_quad_format, vax_f_format, vax_d_format,
        vax_g_format, i370_single_format, i370_double_format,
        c4x_single_format, c4x_extended_format, real_internal_format):
        Provide suitable signbit value, or -1 to avoid bit twiddling.

        * optabs.c (expand_unop): Try implementing negation of
        floating point modes by flipping the sign bit.
        (expand_abs): Try implementing abs of floating point modes
        by clearing the sign bit.

>How-To-Repeat:
Run the testsuite
>Fix:
The reason for the failure is that on an ARM little-endian system the floating-point sign bit is in the lowest addressed word (that is, the sign bit is at position 31 (not 63) when the floating point value is considered as a 'long long' (ARM FPA double format is motorola word order, even when the system is little-endian).

The code needs to take this into account (FLOAT_WORDS_BIG_ENDIAN != WORDS_BIG_ENDIAN) => the hi and lo fields should be swapped over.
>Release-Note:
>Audit-Trail:
>Unformatted:


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: middle-end/9009: floating-point negate and abs optimizations incorrect for ARM
@ 2002-12-19  9:37 rearnsha
  0 siblings, 0 replies; 2+ messages in thread
From: rearnsha @ 2002-12-19  9:37 UTC (permalink / raw)
  To: gcc-bugs, gcc-prs, nobody, rearnsha, roger

Synopsis: floating-point negate and abs optimizations incorrect for ARM

State-Changed-From-To: open->analyzed
State-Changed-By: rearnsha
State-Changed-When: Thu Dec 19 09:37:53 2002
State-Changed-Why:
    Analysis provided with report.  This is a regression introduced by the 3.4 BIB merge.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9009


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-12-19 17:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-19  9:36 middle-end/9009: floating-point negate and abs optimizations incorrect for ARM rearnsha
2002-12-19  9:37 rearnsha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).