This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Note handling in haifa-sched.



       I am trying to modify the haifa scheduler in order to make it work
better on a VLIW architecture. I tried to mark the beggining/end of a
instruction set with a note (NOTE_INSN_SET_BEG and NOTE_INSN_SET_END - I
defined these notes properly). I am currently placing the notes correctly,
but after I place them, the scheduler moves most of them to the end of the
program. I made the modifications inside schedule_block ( after
rm_other_notes was called). More specifically, my code looks something like:

[....]

while(sched_target_n_insns<target_n_insns){
  int b1;
  clock_var++;   /* This part is unchanged, I wrote it to give you a hint as
to where
				the code that emits the notes is placed */
[...]

  for(....){
   [....]
  } /* end of for */

   if(reload_completed)
      last_emitted_note=emit_note_after(NOTE_INSN_SET_END,last_sched_insn);
/* don't worry about the value of last_sched_insn and last_emitted_note -
initially,
the note is emitted in the proper position - I checked that (using a printf)
*/

[...]
  } /* end while */

  After the 'while' loop, the notes are moved (I checked that, too). The
problem is that I cannot understand what code in the while loop is moving my
notes.
  Any help is appreciated. Thanks,

        Virgil


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]