This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: [PATCH] Fix combiner i3/i2 pattern splitting (PR rtl-optimization/45695)


> In the PR rtl-optimization/44858 fix I've been assuming that the comment
> claiming the order doesn't really matter and HAVE_cc0 implementation are
> right, unfortunately it seems it was wrong.  We tested unconditionally
>           && ! use_crosses_set_p (SET_SRC (XVECEXP (newpat, 0, 1)),
>                                   DF_INSN_LUID (i2))
> but for HAVE_cc0 could have chosen to put XVECEXP (newpat, 0, 0)
> into i2 instead of i3 (then the use_crosses_set_p test is irrelevant
> to it and nothing tests that the pattern we want to put into i2
> doesn't depend on something set by insns in between i2 and i3.
> And my patch of course made things even worse, as it tries to swap
> the patterns if added clobbers disallow the initially chosen order, even
> on !HAVE_cc0 targets.

How about erring on the side of caution and trimming down the fix for 44858
to make it identical to that of 20322?  Would that pessimize too much?

-- 
Eric Botcazou


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