[atom]: PATCH: reg_mentioned_by_mem_p with DF

Paolo Bonzini bonzini@gnu.org
Mon Mar 30 11:49:00 GMT 2009


>>>> As it is used by insn splitter and splitting can also happen during final
>>>> when DF isn't available, I don't see how this is a safe thing to do.
>>> Why do you think DF is not available in final?
>> I don't remember exactly, but I think Jakub is right.  I don't think DF
>> is kept up to date by the last passes, especially after BLOCK_FOR_INSN
>> is unset.
> 
> As far as I know, the df-scan info is also OK in final.

It depends on the port, as it is not kept up to date after free_cfg.
Indeed the code matches what I recalled:

  basic_block bb = BLOCK_FOR_INSN (insn);
  struct df_collection_rec collection_rec;

  if ((!df) || (!INSN_P (insn)))
    return false;

  if (!bb)
    {
      if (dump_file)
        fprintf (dump_file, "no bb for insn with uid = %d.\n", uid);
      return false;
    }

It does not matter on i386, which has a fairly sane md reorg pass and
does not do delay slots.  The only problem I can foresee is for
splitters that need to run after the regstack pass.

Paolo



More information about the Gcc-patches mailing list