public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Continue RTL verifying in rtl_verify_fallthru
@ 2021-11-25 12:35 Richard Biener
  0 siblings, 0 replies; only message in thread
From: Richard Biener @ 2021-11-25 12:35 UTC (permalink / raw)
  To: gcc-patches

One case used fatal_insn which does not return which isn't
intended as can be seen by the following erro = 1.  The following
change refactors this to inline the relevant parts of fatal_insn
instead and continue validating the RTL IL.

Bootstrapped and tested on x86_64-unknown-linux-gnu, will push.

2021-11-25  Richard Biener  <rguenther@suse.de>

	* cfgrtl.c (rtl_verify_fallthru): Do not stop verifying
	with fatal_insn.
	(skip_insns_after_block): Remove unreachable break and continue.
---
 gcc/cfgrtl.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/gcc/cfgrtl.c b/gcc/cfgrtl.c
index e3a724bddb4..c7ba9006b4e 100644
--- a/gcc/cfgrtl.c
+++ b/gcc/cfgrtl.c
@@ -3001,7 +3001,8 @@ rtl_verify_fallthru (void)
 		{
 		  error ("verify_flow_info: Incorrect fallthru %i->%i",
 			 e->src->index, e->dest->index);
-		  fatal_insn ("wrong insn in the fallthru edge", insn);
+		  error ("wrong insn in the fallthru edge");
+		  debug_rtx (insn);
 		  err = 1;
 		}
 	}
@@ -3540,10 +3541,8 @@ skip_insns_after_block (basic_block bb)
 	    {
 	    case NOTE_INSN_BLOCK_END:
 	      gcc_unreachable ();
-	      continue;
 	    default:
 	      continue;
-	      break;
 	    }
 	  break;
 
-- 
2.31.1

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-11-25 12:35 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-25 12:35 [PATCH] Continue RTL verifying in rtl_verify_fallthru Richard Biener

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).