public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/104777] [9/10/11/12 Regression] gcc crashes while compiling a custom coroutine library sample Date: Tue, 08 Mar 2022 19:00:54 +0000 [thread overview] Message-ID: <bug-104777-4-wRnoZb3zW7@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-104777-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104777 --- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The trunk branch has been updated by Marek Polacek <mpolacek@gcc.gnu.org>: https://gcc.gnu.org/g:e1133c0205a7e2a65834a1af780b8da15eead2a9 commit r12-7540-ge1133c0205a7e2a65834a1af780b8da15eead2a9 Author: Marek Polacek <polacek@redhat.com> Date: Mon Mar 7 16:15:46 2022 -0500 rtl: ICE with thread_local and inline asm [PR104777] In r270550, Jakub fixed classify_insn to handle asm goto: if the asm can jump to a label, the insn should be a JUMP_INSN. However, as the following testcase shows, non-null ASM_OPERANDS_LABEL_VEC doesn't guarantee that the rtx has any actual labels it can branch to. Here, the rtvec has 0 elements because expand_asm_stmt created it: rtvec labelvec = rtvec_alloc (nlabels); // nlabels == 0 This causes an ICE in update_br_prob_note: BRANCH_EDGE (bb) crashes because there's no branch edge. I think we can fix this by checking that there is at least one label the asm can jump to before wrapping the ASM_OPERANDS in a JUMP_INSN. PR rtl-optimization/104777 gcc/ChangeLog: * rtl.cc (classify_insn): For ASM_OPERANDS, return JUMP_INSN only if ASM_OPERANDS_LABEL_VEC has at least one element. gcc/testsuite/ChangeLog: * gcc.dg/torture/tls/pr104777.c: New test.
next prev parent reply other threads:[~2022-03-08 19:00 UTC|newest] Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-03-04 7:45 [Bug c++/104777] New: " janezz55 at gmail dot com 2022-03-04 12:54 ` [Bug c++/104777] " marxin at gcc dot gnu.org 2022-03-04 15:44 ` [Bug c++/104777] gcc crashes while compiling a custom coroutine library sample since r10-5137-g43aae289866f5ea5 marxin at gcc dot gnu.org 2022-03-04 15:51 ` mpolacek at gcc dot gnu.org 2022-03-05 21:44 ` [Bug c++/104777] [10/11/12 Regression] " pinskia at gcc dot gnu.org 2022-03-05 21:45 ` [Bug rtl-optimization/104777] " pinskia at gcc dot gnu.org 2022-03-05 21:55 ` [Bug rtl-optimization/104777] [9/10/11/12 Regression] gcc crashes while compiling a custom coroutine library sample pinskia at gcc dot gnu.org 2022-03-05 21:55 ` pinskia at gcc dot gnu.org 2022-03-05 22:07 ` pinskia at gcc dot gnu.org 2022-03-08 0:07 ` mpolacek at gcc dot gnu.org 2022-03-08 19:00 ` cvs-commit at gcc dot gnu.org [this message] 2022-03-08 19:01 ` [Bug rtl-optimization/104777] [9/10/11 " mpolacek at gcc dot gnu.org 2022-03-10 18:33 ` cvs-commit at gcc dot gnu.org 2022-03-10 18:34 ` [Bug rtl-optimization/104777] [9/10 " mpolacek at gcc dot gnu.org 2022-06-13 10:04 ` ubizjak at gmail dot com 2022-06-13 12:00 ` ubizjak at gmail dot com 2022-06-13 12:19 ` stsp at users dot sourceforge.net 2022-06-13 13:26 ` jakub at gcc dot gnu.org 2022-06-13 14:39 ` mpolacek at gcc dot gnu.org 2022-06-13 16:29 ` cvs-commit at gcc dot gnu.org 2022-06-13 16:30 ` mpolacek at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-104777-4-wRnoZb3zW7@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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).