This is the mail archive of the
mailing list for the GCC project.
Fix haifa handling of scope notes
- From: Jan Hubicka <jh at suse dot cz>
- To: gcc-patches at gcc dot gnu dot org, rth at cygnus dot com
- Date: Sat, 29 Dec 2001 21:44:59 +0100
- Subject: Fix haifa handling of scope notes
the RIchards fix to haifa sched breaks my bootstrap on cfg branch. THe failure is caused
by function ending by NOTE_BLOCK_END note followed by barrier. Haifa
decides to put NOTE_BLOCK_END after barrier afterwards and makes cfglayout sanity
checking to die.
Bootstrapped on the branch, testing mainline.
BTW concerning the cfglayout fixes, I believe the code still is incorrect as it
is not able to handle multiple scope region sibbling in single basic block correctly
at least. Whats about using my patch for scope regions at insn basis?
I believe the new code to be more correct, easier, shorter and it can be classified as
Sat Dec 29 21:43:30 CET 2001 Jan Hubicka <email@example.com>
* haifa-sched.c (reemit_other_notes): Set last insn properly.
RCS file: /cvs/gcc/egcs/gcc/haifa-sched.c,v
retrieving revision 126.96.36.199
diff -c -3 -p -r188.8.131.52 haifa-sched.c
*** haifa-sched.c 2001/12/29 16:53:35 184.108.40.206
--- haifa-sched.c 2001/12/29 20:37:19
*************** reemit_other_notes (head, tail)
*** 1613,1618 ****
--- 1613,1620 ----
if (NEXT_INSN (insert_after))
PREV_INSN (NEXT_INSN (insert_after)) = note_tail;
NEXT_INSN (insert_after) = note_tail;
+ if (insert_after == get_last_insn ())
+ set_last_insn (note_tail);