aboutsummaryrefslogtreecommitdiff
path: root/gcc/gimplify.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2019-06-27 23:25:56 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2019-06-27 23:25:56 +0200
commit95bb6e7a56d17f5f8886815f85dff71d12964245 (patch)
tree6bc36b124ce78d0016041c9e38921154d9a85f2f /gcc/gimplify.c
parent12213acba9cff14bb8e37bbafd5918ba3265f829 (diff)
downloadgcc-95bb6e7a56d17f5f8886815f85dff71d12964245.zip
gcc-95bb6e7a56d17f5f8886815f85dff71d12964245.tar.gz
gcc-95bb6e7a56d17f5f8886815f85dff71d12964245.tar.bz2
re PR c++/91024 (-Wimplicit-fallthrough is confused by likely/unlikely attributes)
PR c++/91024 * gimplify.c (collect_fallthrough_labels): Ignore GIMPLE_PREDICT statements. * g++.dg/warn/Wimplicit-fallthrough-4.C: New test. From-SVN: r272764
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r--gcc/gimplify.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 0b25e71..5c51f50 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -2120,6 +2120,8 @@ collect_fallthrough_labels (gimple_stmt_iterator *gsi_p,
}
else if (gimple_call_internal_p (gsi_stmt (*gsi_p), IFN_ASAN_MARK))
;
+ else if (gimple_code (gsi_stmt (*gsi_p)) == GIMPLE_PREDICT)
+ ;
else if (!is_gimple_debug (gsi_stmt (*gsi_p)))
prev = gsi_stmt (*gsi_p);
gsi_next (gsi_p);