This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] [RFC] loop versioning
>
> On Jan 6, 2004, at 1:16 PM, Jan Hubicka wrote:
>
> >In addition do basic block duplication code, we may have something like
> >duplicate_zone that will take a set of basic blocks and duplicate the
> >code together with it's internal edges. I would like to see this
> >implemented at the top of duplicate_bb so we get it working for both
> >RTL
> >and trees.
>
> That's what tree_ssa_loop_version() does for all blocks in a loop,
> at tree level.
This is also what Zdenek's duplicate_loop_to_header_edge does together
with updating of profile and dominator tree and thus I would be more
happy if the code was commonized as far as possible.
Unforutnately the profiler code is still not ported to SSA as it ought
to be before we start more involved CFG manipulations with loops. I
hope to get there soonish.
If we had kind of duplicate_zone functionality that is not tied to loops
but it is able to update SSA, it can be used by tracer as well.
>
> > (duplcate_bb shall be virtualized) For RTL this is already
> >done in Zdenek's loop unroller code so one can use this as a base.
>
> I am not yet very familiar with all cfg code, so are referring
> cfg_layout_can_duplicate_bb_p () or tree_duplicate_bb () as
> duplicate_bb() ?
Yes, for most of CFG manipulation functions we do have hooks in
cfghooks.h so they can be used in IL independent way. I would like to
update duplicate_bb for this soon. (it is right now only at LNO branch,
right?)
Honza
>
> Thank you,
> --
> Devang