aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/reorg.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/reorg.c b/gcc/reorg.c
index 9948a91..e652225 100644
--- a/gcc/reorg.c
+++ b/gcc/reorg.c
@@ -3893,6 +3893,11 @@ dbr_schedule (first, file)
flag_no_peephole = old_flag_no_peephole;
#endif
+ /* If the current function has no insns other than the prologue and
+ epilogue, then do not try to fill any delay slots. */
+ if (n_basic_blocks == 0)
+ return;
+
/* Find the highest INSN_UID and allocate and initialize our map from
INSN_UID's to position in code. */
for (max_uid = 0, insn = first; insn; insn = NEXT_INSN (insn))