[PATCH v2] Add bypass_p cost check in flag_sched_last_insn_heuristic

Jojo R jiejie_rong@c-sky.com
Fri Nov 6 09:39:18 GMT 2020


Jojo
在 2020年11月6日 +0800 AM11:18,Jeff Law <law@redhat.com>,写道:

On 11/5/20 7:52 PM, Jim Wilson wrote:
	On Thu, Nov 5, 2020 at 6:10 PM Jojo R <jiejie_rong@c-sky.com> wrote:
> >         gcc/
> >         * haifa-sched.c (rank_for_schedule): Add bypass_p
> >         cost check in flag_sched_last_insn_heuristic.
> >
> > +         || (INSN_CODE (DEP_PRO (dep1)) >= 0 && bypass_p (DEP_PRO (dep1))
> > +             && recog_memoized (DEP_CON (dep1)) >= 0
> > +             && !dep_cost (dep1)))
>
> This is using the same idiom at the previous patch.  Do the two patches depend on each other?  It isn't clear.  Since this idiom is used 3 times across the 2 patches, maybe it should be a macro or an inline function.
FWIW, I'd just let the inliner make the decision.

	>
> As with the other patch, some explanation would be nice, and some testing on multiple targets too.
Agreed.
Ok & Thanks,

It’s fixed in patch v3.
	jeff
	


More information about the Gcc-patches mailing list