* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
@ 2012-02-12 9:24 ` pinskia at gcc dot gnu.org
2014-10-31 4:01 ` pinskia at gcc dot gnu.org
` (8 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu.org @ 2012-02-12 9:24 UTC (permalink / raw)
To: gcc-bugs
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
AssignedTo|unassigned at gcc dot |pinskia at gcc dot gnu.org
|gnu.org |
--- Comment #15 from Andrew Pinski <pinskia at gcc dot gnu.org> 2012-02-12 09:23:28 UTC ---
I will implement this combing in forwprop (since that is where we are doing all
the combing optimizations now).
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
2012-02-12 9:24 ` [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level pinskia at gcc dot gnu.org
@ 2014-10-31 4:01 ` pinskia at gcc dot gnu.org
2014-12-01 14:15 ` rguenth at gcc dot gnu.org
` (7 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: pinskia at gcc dot gnu.org @ 2014-10-31 4:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
Bug 14541 depends on bug 15459, which changed state.
Bug 15459 Summary: [meta-bug] there should be a tree combiner like the rtl one
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=15459
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
2012-02-12 9:24 ` [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level pinskia at gcc dot gnu.org
2014-10-31 4:01 ` pinskia at gcc dot gnu.org
@ 2014-12-01 14:15 ` rguenth at gcc dot gnu.org
2014-12-02 11:23 ` rguenth at gcc dot gnu.org
` (6 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-01 14:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #16 from Richard Biener <rguenth at gcc dot gnu.org> ---
(for logfn (BUILT_IN_LOGF BUILT_IN_LOG BUILT_IN_LOGL)
expfn (BUILT_IN_EXPF BUILT_IN_EXP BUILT_IN_EXPL)
(simplify
(logfn (expfn @0))
(if (flag_unsafe_math_optimizations)
@0)))
with the still somewhat awkward syntax, patch for proposed better one
is not yet ready but would look like
(define_operator_list log (BUILT_IN_LOGF BUILT_IN_LOG BUILT_IN_LOGL))
(define_operator_list exp (BUILT_IN_EXPF BUILT_IN_EXP BUILT_IN_EXPL))
(simplify
(log (exp @0))
(if (flag_unsafe_math_optimizations)
@0)))
thus the 'for' would be implicit. Note that fold_builtin_logarithm does handle
some more cases. The match-and-simplify branch already covers quite some
patterns in match-builtins.def (but not the above).
I'll see if I can take the syntax patch (I was waiting for that so not to
merge the "ugly" syntax).
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2014-12-01 14:15 ` rguenth at gcc dot gnu.org
@ 2014-12-02 11:23 ` rguenth at gcc dot gnu.org
2014-12-03 11:55 ` rguenth at gcc dot gnu.org
` (5 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-02 11:23 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|pinskia at gcc dot gnu.org |rguenth at gcc dot gnu.org
--- Comment #17 from Richard Biener <rguenth at gcc dot gnu.org> ---
I have a patch for fold_builtin_logarithm. But as I understand this PR
basically asks for "everything". A few more cases are already implemented on
the branch.
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2014-12-02 11:23 ` rguenth at gcc dot gnu.org
@ 2014-12-03 11:55 ` rguenth at gcc dot gnu.org
2014-12-08 10:28 ` ktkachov at gcc dot gnu.org
` (4 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-03 11:55 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #18 from Richard Biener <rguenth at gcc dot gnu.org> ---
Author: rguenth
Date: Wed Dec 3 11:55:14 2014
New Revision: 218308
URL: https://gcc.gnu.org/viewcvs?rev=218308&root=gcc&view=rev
Log:
2014-12-03 Richard Biener <rguenther@suse.de>
PR middle-end/14541
* builtins.c (fold_builtin_logarithm): Implement simplifications ...
* match.pd: ... here as patterns.
Modified:
trunk/gcc/ChangeLog
trunk/gcc/builtins.c
trunk/gcc/match.pd
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (4 preceding siblings ...)
2014-12-03 11:55 ` rguenth at gcc dot gnu.org
@ 2014-12-08 10:28 ` ktkachov at gcc dot gnu.org
2014-12-08 10:32 ` rguenther at suse dot de
` (3 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: ktkachov at gcc dot gnu.org @ 2014-12-08 10:28 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
ktkachov at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ktkachov at gcc dot gnu.org
--- Comment #19 from ktkachov at gcc dot gnu.org ---
(In reply to Richard Biener from comment #18)
> Author: rguenth
> Date: Wed Dec 3 11:55:14 2014
> New Revision: 218308
>
> URL: https://gcc.gnu.org/viewcvs?rev=218308&root=gcc&view=rev
> Log:
> 2014-12-03 Richard Biener <rguenther@suse.de>
>
> PR middle-end/14541
> * builtins.c (fold_builtin_logarithm): Implement simplifications ...
> * match.pd: ... here as patterns.
>
> Modified:
> trunk/gcc/ChangeLog
> trunk/gcc/builtins.c
> trunk/gcc/match.pd
With this commit the builtin-explog-1.c test stops folding the builtins on
aarch64 (and consequently FAILs)
>From gcc-bugs-return-469702-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Dec 08 10:28:56 2014
Return-Path: <gcc-bugs-return-469702-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 19774 invoked by alias); 8 Dec 2014 10:28:55 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 19686 invoked by uid 48); 8 Dec 2014 10:28:51 -0000
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/64216] Function template can access private sub class without being friend
Date: Mon, 08 Dec 2014 10:28:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.2
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: redi at gcc dot gnu.org
X-Bugzilla-Status: RESOLVED
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: bug_status resolution
Message-ID: <bug-64216-4-JZw4RSbAuC@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-64216-4@http.gcc.gnu.org/bugzilla/>
References: <bug-64216-4@http.gcc.gnu.org/bugzilla/>
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: 2014-12/txt/msg00709.txt.bz2
Content-length: 500
https://gcc.gnu.org/bugzilla/show_bug.cgi?idd216
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |RESOLVED
Resolution|--- |DUPLICATE
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Definitely a dup
*** This bug has been marked as a duplicate of bug 41437 ***
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (5 preceding siblings ...)
2014-12-08 10:28 ` ktkachov at gcc dot gnu.org
@ 2014-12-08 10:32 ` rguenther at suse dot de
2014-12-11 13:14 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
9 siblings, 0 replies; 15+ messages in thread
From: rguenther at suse dot de @ 2014-12-08 10:32 UTC (permalink / raw)
To: gcc-bugs
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="UTF-8", Size: 3604 bytes --]
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #20 from rguenther at suse dot de <rguenther at suse dot de> ---
On Mon, 8 Dec 2014, ktkachov at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
>
> ktkachov at gcc dot gnu.org changed:
>
> What |Removed |Added
> ----------------------------------------------------------------------------
> CC| |ktkachov at gcc dot gnu.org
>
> --- Comment #19 from ktkachov at gcc dot gnu.org ---
> (In reply to Richard Biener from comment #18)
> > Author: rguenth
> > Date: Wed Dec 3 11:55:14 2014
> > New Revision: 218308
> >
> > URL: https://gcc.gnu.org/viewcvs?rev=218308&root=gcc&view=rev
> > Log:
> > 2014-12-03 Richard Biener <rguenther@suse.de>
> >
> > PR middle-end/14541
> > * builtins.c (fold_builtin_logarithm): Implement simplifications ...
> > * match.pd: ... here as patterns.
> >
> > Modified:
> > trunk/gcc/ChangeLog
> > trunk/gcc/builtins.c
> > trunk/gcc/match.pd
>
> With this commit the builtin-explog-1.c test stops folding the builtins on
> aarch64 (and consequently FAILs)
Which one exactly? That is, what is the failing link output?
>From gcc-bugs-return-469705-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Mon Dec 08 10:37:00 2014
Return-Path: <gcc-bugs-return-469705-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 26341 invoked by alias); 8 Dec 2014 10:37:00 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 26278 invoked by uid 48); 8 Dec 2014 10:36:56 -0000
From: "ktkachov at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
Date: Mon, 08 Dec 2014 10:37: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: tree-ssa
X-Bugzilla-Keywords: missed-optimization
X-Bugzilla-Severity: enhancement
X-Bugzilla-Who: ktkachov at gcc dot gnu.org
X-Bugzilla-Status: ASSIGNED
X-Bugzilla-Priority: P2
X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: attachments.created
Message-ID: <bug-14541-4-cH13ukDQJ1@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-14541-4@http.gcc.gnu.org/bugzilla/>
References: <bug-14541-4@http.gcc.gnu.org/bugzilla/>
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: 2014-12/txt/msg00712.txt.bz2
Content-length: 461
https://gcc.gnu.org/bugzilla/show_bug.cgi?id\x14541
--- Comment #21 from ktkachov at gcc dot gnu.org ---
Created attachment 34215
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id4215&actioníit
Link errors output for aarch64
> Which one exactly? That is, what is the failing link output?
All of them AFAICS. I'm attaching the link failures log.
The test PASSes at -O2 -flto and -O2 -flto -flto-partition=none
but FAILs on all other torture options
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (6 preceding siblings ...)
2014-12-08 10:32 ` rguenther at suse dot de
@ 2014-12-11 13:14 ` rguenth at gcc dot gnu.org
2014-12-11 13:30 ` ktkachov at gcc dot gnu.org
2014-12-15 13:11 ` rguenth at gcc dot gnu.org
9 siblings, 0 replies; 15+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-11 13:14 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #22 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to ktkachov from comment #21)
> Created attachment 34215 [details]
> Link errors output for aarch64
>
> > Which one exactly? That is, what is the failing link output?
>
> All of them AFAICS. I'm attaching the link failures log.
>
> The test PASSes at -O2 -flto and -O2 -flto -flto-partition=none
>
> but FAILs on all other torture options
With a cross to aarch64-linux and compiling with -O1+ -ffast-math the
result is as expected (optimized to empty functions). How exactly
do you configure? I used
/space/rguenther/src/svn/trunk2/configure --target=aarch64-suse-linux
--enable-languages=c,c++,fortran --enable-checking
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (7 preceding siblings ...)
2014-12-11 13:14 ` rguenth at gcc dot gnu.org
@ 2014-12-11 13:30 ` ktkachov at gcc dot gnu.org
2014-12-15 13:11 ` rguenth at gcc dot gnu.org
9 siblings, 0 replies; 15+ messages in thread
From: ktkachov at gcc dot gnu.org @ 2014-12-11 13:30 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #23 from ktkachov at gcc dot gnu.org ---
(In reply to Richard Biener from comment #22)
> (In reply to ktkachov from comment #21)
> > Created attachment 34215 [details]
> > Link errors output for aarch64
> >
> > > Which one exactly? That is, what is the failing link output?
> >
> > All of them AFAICS. I'm attaching the link failures log.
> >
> > The test PASSes at -O2 -flto and -O2 -flto -flto-partition=none
> >
> > but FAILs on all other torture options
>
> With a cross to aarch64-linux and compiling with -O1+ -ffast-math the
> result is as expected (optimized to empty functions). How exactly
> do you configure? I used
>
> /space/rguenther/src/svn/trunk2/configure --target=aarch64-suse-linux
> --enable-languages=c,c++,fortran --enable-checking
Hmmm... My compiler is a bare-metal one: aarch64-none-elf (and I still see
these failures).
With an aarch64-none-linux-gnu compiler the testcase works fine...
^ permalink raw reply [flat|nested] 15+ messages in thread
* [Bug tree-optimization/14541] [tree-ssa] built-in math functions are not fully optimized at tree level
[not found] <bug-14541-4@http.gcc.gnu.org/bugzilla/>
` (8 preceding siblings ...)
2014-12-11 13:30 ` ktkachov at gcc dot gnu.org
@ 2014-12-15 13:11 ` rguenth at gcc dot gnu.org
9 siblings, 0 replies; 15+ messages in thread
From: rguenth at gcc dot gnu.org @ 2014-12-15 13:11 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14541
--- Comment #24 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to ktkachov from comment #23)
> (In reply to Richard Biener from comment #22)
> > (In reply to ktkachov from comment #21)
> > > Created attachment 34215 [details]
> > > Link errors output for aarch64
> > >
> > > > Which one exactly? That is, what is the failing link output?
> > >
> > > All of them AFAICS. I'm attaching the link failures log.
> > >
> > > The test PASSes at -O2 -flto and -O2 -flto -flto-partition=none
> > >
> > > but FAILs on all other torture options
> >
> > With a cross to aarch64-linux and compiling with -O1+ -ffast-math the
> > result is as expected (optimized to empty functions). How exactly
> > do you configure? I used
> >
> > /space/rguenther/src/svn/trunk2/configure --target=aarch64-suse-linux
> > --enable-languages=c,c++,fortran --enable-checking
>
> Hmmm... My compiler is a bare-metal one: aarch64-none-elf (and I still see
> these failures).
>
> With an aarch64-none-linux-gnu compiler the testcase works fine...
I have opened PR64313 for this regression.
^ permalink raw reply [flat|nested] 15+ messages in thread