This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: bb-reorder cleanups
- To: gcc-patches at gcc dot gnu dot org
- Subject: Re: bb-reorder cleanups
- From: Jason Eckhardt <jle at cygnus dot com>
- Date: Fri, 31 Aug 2001 07:25:33 -0700 (PDT)
>--- 1504,1513 ----
>
> for (p = s->inner; p; p = p->next)
> {
>! /* In case of duplicated basic block, the bb_beg and bb_end don't
>need
>! to match the bb itself. */
>! if (p->bb_beg != NULL && p->bb_beg == p->bb_end)
>! insert_intra_1 (p, &ip, bb);
> }
> }
This is a hack. It implies that you haven't updated the scope tree
to reflect the duplicated block(s). It should 'work', but it isn't
as nice as I'd hope. The tree is built before reordering begins. It
represents the relationships between scopes and basic blocks. The
insert_inter* and insert_intra* just interpret the scope tree and
insert the proper scope notes.
Also, the debugging hooks for visualizing the
scope tree won't be accurate at points because the tree is not
relective of the code if blocks are duplicated. Just a nit.
I don't strongly object, since the hack will probably work and I'm
severely pressured for time these days. But
it would be nice to have the scope tree continue to represent the code,
even if it changes during reordering.
jason.