Question of the suitable time to call `free_bb_for_insn()'

Ling-hua Tseng uranus@it.muds.net
Sun Aug 14 01:16:00 GMT 2005


I'm porting the GCC 4.0.2 (2005-08-11 snapshot) to a new VLIW architecture.

I figured out the `free_bb_for_insn()' is called before the reorg pass,
and I would like to use the CFG in the reorg pass for a reason.

The reason is:
    I would like to change flag_schedule_insns_after_reload to 0 by the macro OVERRIDE_OPTIONS if it was set,
    and then I would like to call the sched2 pass in some location of the hook TARGET_MACHINE_DEPENDENT_REORG.
    Perhaps I will manually do some instruction scheduling in the reorg pass in the future.

So I have two questions:
    1. Is it safe to move the line `free_bb_for_insn ();' to the next line of `rest_of_handle_machine_reorg ();' ?
    2. If it is safe, would the GCC team like to move it to there for allowing other ones can use CFG info
        in the reorg pass?

By the way, I noticed that the ia64 port did something which is similar to mine.
But it do some effort for recoding something before the reorg pass.
Moreover, it's forced to call the `schedule_ebbs()' however(I'd like to call `schedule_insns()').

Thanks a lot.



More information about the Gcc mailing list