public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139
@ 2022-07-11 18:56 gscfq@t-online.de
  2022-07-11 19:53 ` [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649 marxin at gcc dot gnu.org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: gscfq@t-online.de @ 2022-07-11 18:56 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

            Bug ID: 106258
           Summary: ICE in ipa_verify_edge_has_no_modifications, at
                    ipa-param-manipulation.cc:139
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gscfq@t-online.de
  Target Milestone: ---

Started between 20220619 and 20220626,
with file g++.dg/ipa/ipa-sra-4.C :


$ gcc-13-20220710 -c ipa-sra-4.C -O2 -funreachable-traps
during IPA pass: inline
In function 'void check_allocate_max_size() [with Alloc =
throw_allocator_base]',
    inlined from 'int main()' at ipa-sra-4.C:37:59:
ipa-sra-4.C:35:13: internal compiler error: in
ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139
   35 |   a.allocate(__trans_tmp_1 + 1);
      |   ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
0xe9b1d5 ipa_verify_edge_has_no_modifications(cgraph_edge*)
        ../../gcc/ipa-param-manipulation.cc:139
0xbc2c9f cgraph_edge::redirect_call_stmt_to_callee(cgraph_edge*)
        ../../gcc/cgraph.cc:1553
0x118dcaf redirect_all_calls(copy_body_data*, basic_block_def*)
        ../../gcc/tree-inline.cc:3002
0x1191363 copy_cfg_body
        ../../gcc/tree-inline.cc:3157
0x1191363 copy_body
        ../../gcc/tree-inline.cc:3338
0x1194628 expand_call_inline
        ../../gcc/tree-inline.cc:5123
0x11966a9 gimple_expand_calls_inline
        ../../gcc/tree-inline.cc:5318
0x11966a9 optimize_inline_calls(tree_node*)
        ../../gcc/tree-inline.cc:5490
0xe59ceb inline_transform(cgraph_node*)
        ../../gcc/ipa-inline-transform.cc:790
0xff0400 execute_one_ipa_transform_pass
        ../../gcc/passes.cc:2336
0xff0400 execute_all_ipa_transforms(bool)
        ../../gcc/passes.cc:2399
0xbca145 cgraph_node::expand()
        ../../gcc/cgraphunit.cc:1827
0xbcbae6 expand_all_functions
        ../../gcc/cgraphunit.cc:1998
0xbcbae6 symbol_table::compile()
        ../../gcc/cgraphunit.cc:2348
0xbcf1bf symbol_table::compile()
        ../../gcc/cgraphunit.cc:2532
0xbcf1bf symbol_table::finalize_compilation_unit()
        ../../gcc/cgraphunit.cc:2529

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
@ 2022-07-11 19:53 ` marxin at gcc dot gnu.org
  2022-07-11 19:56 ` pinskia at gcc dot gnu.org
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: marxin at gcc dot gnu.org @ 2022-07-11 19:53 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Martin Liška <marxin at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2022-07-11
            Summary|ICE in                      |[13 Regression] ICE in
                   |ipa_verify_edge_has_no_modi |ipa_verify_edge_has_no_modi
                   |fications, at               |fications, at
                   |ipa-param-manipulation.cc:1 |ipa-param-manipulation.cc:1
                   |39                          |39 since
                   |                            |r13-1204-gd68d366425369649
                 CC|                            |jason at gcc dot gnu.org
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Started with r13-1204-gd68d366425369649.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
  2022-07-11 19:53 ` [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649 marxin at gcc dot gnu.org
@ 2022-07-11 19:56 ` pinskia at gcc dot gnu.org
  2022-07-12  6:34 ` [Bug middle-end/106258] " rguenth at gcc dot gnu.org
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-07-11 19:56 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |13.0

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
  2022-07-11 19:53 ` [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649 marxin at gcc dot gnu.org
  2022-07-11 19:56 ` pinskia at gcc dot gnu.org
@ 2022-07-12  6:34 ` rguenth at gcc dot gnu.org
  2023-02-16 14:23 ` hubicka at gcc dot gnu.org
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-07-12  6:34 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P1

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
                   ` (2 preceding siblings ...)
  2022-07-12  6:34 ` [Bug middle-end/106258] " rguenth at gcc dot gnu.org
@ 2023-02-16 14:23 ` hubicka at gcc dot gnu.org
  2023-02-21 14:05 ` jakub at gcc dot gnu.org
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: hubicka at gcc dot gnu.org @ 2023-02-16 14:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Jan Hubicka <hubicka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hubicka at gcc dot gnu.org,
                   |                            |mjambor at suse dot cz

--- Comment #2 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
This is Martin's area, so adding CC.  The patch turns unreachables to traps.
Traps are handled somewhat specially in IPA code since they are used to mark
calls that are known to be dead after inlining/specialization.
We special case this sanity check unreachables and I suppose we can do that for
traps too.

diff --git a/gcc/cgraph.cc b/gcc/cgraph.cc
index f352212e463..ddfd0a93c43 100644
--- a/gcc/cgraph.cc
+++ b/gcc/cgraph.cc
@@ -1548,7 +1548,8 @@ cgraph_edge::redirect_call_stmt_to_callee (cgraph_edge
*e)
   else
     {
       if (flag_checking
-         && !fndecl_built_in_p (e->callee->decl, BUILT_IN_UNREACHABLE))
+         && !fndecl_built_in_p (e->callee->decl, BUILT_IN_UNREACHABLE)
+         && !fndecl_built_in_p (e->callee->decl, BUILT_IN_TRAP))
        ipa_verify_edge_has_no_modifications (e);
       new_stmt = e->call_stmt;
       gimple_call_set_fndecl (new_stmt, e->callee->decl);

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
                   ` (3 preceding siblings ...)
  2023-02-16 14:23 ` hubicka at gcc dot gnu.org
@ 2023-02-21 14:05 ` jakub at gcc dot gnu.org
  2023-02-22 10:22 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu.org @ 2023-02-21 14:05 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
           Assignee|unassigned at gcc dot gnu.org      |jakub at gcc dot gnu.org

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 54501
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54501&action=edit
gcc13-pr106258.patch

I think it actuall should be like this instead.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
                   ` (4 preceding siblings ...)
  2023-02-21 14:05 ` jakub at gcc dot gnu.org
@ 2023-02-22 10:22 ` cvs-commit at gcc dot gnu.org
  2023-02-23 14:27 ` cvs-commit at gcc dot gnu.org
  2023-03-06 10:23 ` jakub at gcc dot gnu.org
  7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-02-22 10:22 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:fb5365907317551cf9e4661aa78dd4f773e7a18a

commit r13-6273-gfb5365907317551cf9e4661aa78dd4f773e7a18a
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Wed Feb 22 11:22:03 2023 +0100

    cgraph: Handle BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE in more
spots [PR106258]

    The following testcase ICEs because we still have some spots that
    treat BUILT_IN_UNREACHABLE specially but not BUILT_IN_UNREACHABLE_TRAP
    the same.

    2023-02-22  Jakub Jelinek  <jakub@redhat.com>

            PR middle-end/106258
            * cgraph.cc (cgraph_edge::redirect_call_stmt_to_callee,
            cgraph_update_edges_for_call_stmt_node, cgraph_node::verify_node):
            Handle BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.
            * cgraphclones.cc (cgraph_node::create_clone): Likewise.

            * g++.dg/ipa/pr106258.C: New test.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
                   ` (5 preceding siblings ...)
  2023-02-22 10:22 ` cvs-commit at gcc dot gnu.org
@ 2023-02-23 14:27 ` cvs-commit at gcc dot gnu.org
  2023-03-06 10:23 ` jakub at gcc dot gnu.org
  7 siblings, 0 replies; 9+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-02-23 14:27 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

--- Comment #5 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jakub Jelinek <jakub@gcc.gnu.org>:

https://gcc.gnu.org/g:68e7489b6c1035c69ee008a63d3d56e89fafbb30

commit r13-6303-g68e7489b6c1035c69ee008a63d3d56e89fafbb30
Author: Jakub Jelinek <jakub@redhat.com>
Date:   Thu Feb 23 15:24:43 2023 +0100

    ipa-prop: Fix another case of missing BUILT_IN_UNREACHABLE_TRAP handling
[PR106258]

    There is another spot that handles in IPA just BUILT_IN_UNREACHABLE and
    not BUILT_IN_UNREACHABLE_TRAP.

    This patch fixes that.

    2023-02-23  Jakub Jelinek  <jakub@redhat.com>

            PR middle-end/106258
            * ipa-prop.cc (try_make_edge_direct_virtual_call): Handle
            BUILT_IN_UNREACHABLE_TRAP like BUILT_IN_UNREACHABLE.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* [Bug middle-end/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649
  2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
                   ` (6 preceding siblings ...)
  2023-02-23 14:27 ` cvs-commit at gcc dot gnu.org
@ 2023-03-06 10:23 ` jakub at gcc dot gnu.org
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu.org @ 2023-03-06 10:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106258

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|ASSIGNED                    |RESOLVED

--- Comment #6 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Fixed.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2023-03-06 10:23 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-11 18:56 [Bug c++/106258] New: ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 gscfq@t-online.de
2022-07-11 19:53 ` [Bug ipa/106258] [13 Regression] ICE in ipa_verify_edge_has_no_modifications, at ipa-param-manipulation.cc:139 since r13-1204-gd68d366425369649 marxin at gcc dot gnu.org
2022-07-11 19:56 ` pinskia at gcc dot gnu.org
2022-07-12  6:34 ` [Bug middle-end/106258] " rguenth at gcc dot gnu.org
2023-02-16 14:23 ` hubicka at gcc dot gnu.org
2023-02-21 14:05 ` jakub at gcc dot gnu.org
2023-02-22 10:22 ` cvs-commit at gcc dot gnu.org
2023-02-23 14:27 ` cvs-commit at gcc dot gnu.org
2023-03-06 10:23 ` jakub 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).