aboutsummaryrefslogtreecommitdiff
path: root/gcc/final.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/final.c')
-rw-r--r--gcc/final.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/final.c b/gcc/final.c
index 820162b..e61b78b 100644
--- a/gcc/final.c
+++ b/gcc/final.c
@@ -4309,6 +4309,9 @@ leaf_function_p (void)
{
rtx_insn *insn;
+ /* Ensure we walk the entire function body. */
+ gcc_assert (!in_sequence_p ());
+
/* Some back-ends (e.g. s390) want leaf functions to stay leaf
functions even if they call mcount. */
if (crtl->profile && !targetm.keep_leaf_when_profiled ())