From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9732 invoked by alias); 23 Sep 2012 21:14:20 -0000 Received: (qmail 9595 invoked by uid 48); 23 Sep 2012 21:13:56 -0000 From: "olegendo at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/54686] std::abs (long long) resorts to std::abs (double) if llabs is absent Date: Sun, 23 Sep 2012 21:14:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: olegendo at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Target CC Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 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 X-SW-Source: 2012-09/txt/msg01865.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54686 Oleg Endo changed: What |Removed |Added ---------------------------------------------------------------------------- Target| |sh*-*-* CC| |kkojima at gcc dot gnu.org --- Comment #6 from Oleg Endo 2012-09-23 21:13:55 UTC --- (In reply to comment #1) > Note that the abs(long) and abs(long long) overloads, which you probably want > around, are actually declared in , which you are not including > (-std=c++11 of course). Otherwise, , which is available only because > is included as an implementation detail, is fine per the Standard, any integer > is supposed to unconditionally become double. Brilliant! ;) > > But indeed you are right that long term you want to be non empty for > SH. That shouldn't be too hard to implement, there is already very solid > infrastructure for that (as an header installed by GCC, I mean). This is a > target issue, really. (In reply to comment #3) > Actually, is normally included by as an implementation > detail, thus I suspect the C++11 bits in are also disabled for this > target. Yeah, seems like that. > Looks like the target maintainers need some serious pinging ;) Probably this is due to newlib-bleh. I'm not testing sh-linux, but I would assume that glibc does the right thing there. Kaz, just in case, could you please check this on sh-linux?