public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
@ 2021-09-16 23:01 ` pinskia at gcc dot gnu.org
2022-09-05 16:37 ` jamborm at gcc dot gnu.org
` (3 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-09-16 23:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92497
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Depends on| |94818
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Very similar (if not the same as PR 94818).
Referenced Bugs:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94818
[Bug 94818] GCC emits dead bodies of functions whose all calls have been
eliminated by optimisations
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
2021-09-16 23:01 ` [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost pinskia at gcc dot gnu.org
@ 2022-09-05 16:37 ` jamborm at gcc dot gnu.org
2023-05-29 16:25 ` jamborm at gcc dot gnu.org
` (2 subsequent siblings)
4 siblings, 0 replies; 5+ messages in thread
From: jamborm at gcc dot gnu.org @ 2022-09-05 16:37 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92497
Martin Jambor <jamborm at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |jamborm at gcc dot gnu.org
Status|NEW |ASSIGNED
--- Comment #2 from Martin Jambor <jamborm at gcc dot gnu.org> ---
I'm working on a fix along the lines of
https://gcc.gnu.org/pipermail/gcc-patches/2022-April/592644.html
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
2021-09-16 23:01 ` [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost pinskia at gcc dot gnu.org
2022-09-05 16:37 ` jamborm at gcc dot gnu.org
@ 2023-05-29 16:25 ` jamborm at gcc dot gnu.org
2023-08-15 15:41 ` cvs-commit at gcc dot gnu.org
2023-08-15 15:45 ` jamborm at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: jamborm at gcc dot gnu.org @ 2023-05-29 16:25 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92497
--- Comment #3 from Martin Jambor <jamborm at gcc dot gnu.org> ---
I have proposed a fix on the mailing list:
https://gcc.gnu.org/pipermail/gcc-patches/2023-May/619969.html
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
` (2 preceding siblings ...)
2023-05-29 16:25 ` jamborm at gcc dot gnu.org
@ 2023-08-15 15:41 ` cvs-commit at gcc dot gnu.org
2023-08-15 15:45 ` jamborm at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-08-15 15:41 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92497
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Martin Jambor <jamborm@gcc.gnu.org>:
https://gcc.gnu.org/g:d073e2d75d9ed492de9a8dc6970e5b69fae20e5a
commit r14-3226-gd073e2d75d9ed492de9a8dc6970e5b69fae20e5a
Author: Martin Jambor <mjambor@suse.cz>
Date: Tue Aug 15 17:26:13 2023 +0200
Feed results of IPA-CP into tree value numbering
PRs 68930 and 92497 show that when IPA-CP figures out constants in
aggregate parameters or when passed by reference but the loads happen
in an inlined function the information is lost. This happens even
when the inlined function itself was known to have - or even cloned to
have - such constants in incoming parameters because the transform
phase of IPA passes is not run on them. See discussion in the bugs
for reasons why.
Honza suggested that we can plug the results of IPA-CP analysis into
value numbering, so that FRE can figure out that some loads fetch
known constants. This is what this patch attempts to do. The patch
does not attempt to populate partial_defs with information from
IPA-CP, this can be hopefully added as a follow-up.
gcc/ChangeLog:
2023-08-11 Martin Jambor <mjambor@suse.cz>
PR ipa/68930
PR ipa/92497
* ipa-prop.h (ipcp_get_aggregate_const): Declare.
* ipa-prop.cc (ipcp_get_aggregate_const): New function.
(ipcp_transform_function): Do not deallocate transformation info.
* tree-ssa-sccvn.cc: Include alloc-pool.h, symbol-summary.h and
ipa-prop.h.
(vn_reference_lookup_2): When hitting default-def vuse, query
IPA-CP transformation info for any known constants.
gcc/testsuite/ChangeLog:
2023-06-07 Martin Jambor <mjambor@suse.cz>
PR ipa/68930
PR ipa/92497
* gcc.dg/ipa/pr92497-1.c: New test.
* gcc.dg/ipa/pr92497-2.c: Likewise.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
` (3 preceding siblings ...)
2023-08-15 15:41 ` cvs-commit at gcc dot gnu.org
@ 2023-08-15 15:45 ` jamborm at gcc dot gnu.org
4 siblings, 0 replies; 5+ messages in thread
From: jamborm at gcc dot gnu.org @ 2023-08-15 15:45 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92497
Martin Jambor <jamborm at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #5 from Martin Jambor <jamborm at gcc dot gnu.org> ---
Fixed.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-08-15 15:45 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <bug-92497-4@http.gcc.gnu.org/bugzilla/>
2021-09-16 23:01 ` [Bug ipa/92497] Aggregate IPA-CP and inlining do not play well together, transformation is lost pinskia at gcc dot gnu.org
2022-09-05 16:37 ` jamborm at gcc dot gnu.org
2023-05-29 16:25 ` jamborm at gcc dot gnu.org
2023-08-15 15:41 ` cvs-commit at gcc dot gnu.org
2023-08-15 15:45 ` jamborm at gcc dot gnu.org
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).