Marcin Dalecki <[EMAIL PROTECTED]> writes:

> Looking at the regor.c code I came across the function
> try_merge_delay_insns().
> There around the line 1488 we will find the following code:
> 
>               merged_insns = gen_rtx_INSN_LIST (SImode, dtrial,
>                                                 merged_insns);
> 
> Please note that in literally *all* other cases the gen_rtx_INSN_LIST
> function is supposed to take an enum reg_note as first argument and
> not the somehow arbitrary value SImode. All subsequent rtx tree
> processing
> is assuming that in case of instruction lists we have a reg_note
> present in
> this field.
> 
> I assume therefore that the value REG_DEP_TRUE should be assed as
> first argument
> to gen_rtx_INSN_LIST there. I think only the fact that the code in
> question
> isn't likely to trigger didn't make this occur immediately as a bug.
> 
> Is this analysis correct?

No.

An INSN_LIST which goes into the REG_NOTES field must use a register
note such as REG_DEP_TRUE in the mode field.  But merged_insns does
not go into the REG_NOTES field.  It is only used within the function
try_merge_delay_insns.  Look at the loop at the end of the insns to
see how the mode is tested.  The value of SImode is indeed arbitrary.
It can be anything distinct from VOIDmode.

Ian

Reply via email to