From: Vladimir Makarov Date: Thu, 10 Jun 2004 21:06:07 +0000 (+0000) Subject: re PR target/15653 (Gcc 3.4 ICE on valid code) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d57f1617211f3309887c6ee18fca97ea7029ebc7;p=gcc.git re PR target/15653 (Gcc 3.4 ICE on valid code) 2004-06-10 Vladimir Makarov PR target/15653 * haifa-sched.c (schedule_block): Finish cycle after issuing asm insn. From-SVN: r82942 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7bd66097295..6a1b4db0d09 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2004-06-10 Vladimir Makarov + + PR target/15653 + * haifa-sched.c (schedule_block): Finish cycle after issuing asm + insn. + 2004-06-10 Volker Reichelt PR web/15263 diff --git a/gcc/haifa-sched.c b/gcc/haifa-sched.c index af8b8a70157..033aaae1757 100644 --- a/gcc/haifa-sched.c +++ b/gcc/haifa-sched.c @@ -2378,6 +2378,7 @@ schedule_block (int b, int rgn_n_insns) { rtx insn; int cost; + bool asm_p = false; if (sched_verbose >= 2) { @@ -2435,9 +2436,9 @@ schedule_block (int b, int rgn_n_insns) memcpy (temp_state, curr_state, dfa_state_size); if (recog_memoized (insn) < 0) { - if (!first_cycle_insn_p - && (GET_CODE (PATTERN (insn)) == ASM_INPUT - || asm_noperands (PATTERN (insn)) >= 0)) + asm_p = (GET_CODE (PATTERN (insn)) == ASM_INPUT + || asm_noperands (PATTERN (insn)) >= 0); + if (!first_cycle_insn_p && asm_p) /* This is asm insn which is tryed to be issued on the cycle not first. Issue it on the next cycle. */ cost = 1; @@ -2552,6 +2553,10 @@ schedule_block (int b, int rgn_n_insns) can_issue_more--; advance = schedule_insn (insn, &ready, clock_var); + + /* After issuing an asm insn we should start a new cycle. */ + if (advance == 0 && asm_p) + advance = 1; if (advance != 0) break;