From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6331 invoked by alias); 27 Jul 2013 19:53:54 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 6248 invoked by uid 48); 27 Jul 2013 19:53:51 -0000 From: "paolo.carlini at oracle dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/57994] Constant folding of infinity Date: Sat, 27 Jul 2013 19:53:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 4.9.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: paolo.carlini at oracle dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-07/txt/msg01336.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57994 --- Comment #5 from Paolo Carlini --- Today I was thinking that given that, per docs and testsuite (double checked yesterday) the mpfr functions are able to cope with +-Inf arguments to the mathematical functions and evaluate correctly, gating the various do_mpfr_* with !real_isnan instead of real_isfinite doesn't look like taking a big risk, now that we are in Stage 1. Alone that would help a lot of code (in particular, in the C++ library, which is the original motivating example). Note, I'm not thinking replacing real_isfinite in various other places, in particular not in do_mpc_* and its helpers (something for the future). Comments?