public inbox for gsl-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Brian Gough <bjg@network-theory.co.uk>
To: gsl-discuss@sourceware.org
Subject: Re: Unwanted compiler optimization (was: Bug report and fix for adaptive step size control in ODE solving)
Date: Fri, 04 Jan 2008 10:44:00 -0000	[thread overview]
Message-ID: <877iipna4o.wl%bjg@network-theory.co.uk> (raw)
In-Reply-To: <9AFC9075-1EA3-4E26-9BE9-EB9C475FE3D9@fhi-berlin.mpg.de>

At Thu, 3 Jan 2008 10:00:54 +0100,
Jochen Küpper wrote:
> Is this an optimization that is considered valid even for floating- 
> point calculations in compiler building?

For general variables no, I don't think so - it only is used if there are
constants on both sides and -ffast-math/-funsafe-math-optimizations is
enabled.  e.g. x+1==1 is converted to x==0 and x+2=3 is converted to x==1.
If -ffast-math is not used any comparisons should not be modified.

  reply	other threads:[~2008-01-04 10:44 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-26 22:14 Bug report and fix for adaptive step size control in ODE solving Frank Reininghaus
2008-01-02 13:40 ` Kevin H. Hobbs
2008-01-02 14:18 ` Jochen Küpper
2008-01-02 18:51   ` Frank Reininghaus
2008-01-03  9:01     ` Unwanted compiler optimization (was: Bug report and fix for adaptive step size control in ODE solving) Jochen Küpper
2008-01-04 10:44       ` Brian Gough [this message]
2008-01-03  5:15 ` Bug report and fix for adaptive step size control in ODE solving Michael Stauffer
2008-01-03 15:54 ` Brian Gough
2008-01-04  9:46 ` Brian Gough

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877iipna4o.wl%bjg@network-theory.co.uk \
    --to=bjg@network-theory.co.uk \
    --cc=gsl-discuss@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).