This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/83293] [8 regression] ICE: in gsi_insert_seq_nodes_after, at gimple-iterator.c:278


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

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 #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
Created attachment 42799
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=42799&action=edit
gcc8-pr83293.patch

Untested fix.  The gsi is unused afterwards, but we don't have a GSI_DONT_CARE
and GSI_SAME_STMT is invalid if the bb was empty and we gsi_insert_after with
GSI_SAME_STMT.  Another possibility would be to change
if (!gsi_end_p (gsi) && stmt_ends_bb_p (gsi_stmt (gsi)))
to
if (gsi_end_p (gsi) || stmt_ends_bb_p (gsi_stmt (gsi)))

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]