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: [tree-ssa] Block merging (updated)


In message <20040113145350.GA25144@atrey.karlin.mff.cuni.cz>, Zdenek Dvorak wri
tes:
 >Hello,
 >
 >>  >> +   /* Remove labels from B and set bb_for_stmt to A for other statemen
 >ts. 
 >>  > */
 >>  >> +   for (bsi = bsi_start (b); !bsi_end_p (bsi);)
 >>  >> +     {
 >>  >> +       if (TREE_CODE (bsi_stmt (bsi)) == LABEL_EXPR)
 >>  >> +       bsi_remove (&bsi);
 >>  >> +       else
 >>  >> +       {
 >>  >> +         set_bb_for_stmt (bsi_stmt (bsi), a);
 >>  >> +         bsi_next (&bsi);
 >>  >> +       }
 >>  >> +     }
 >>  >> 
 >>  >> 
 >>  >> This will remove user-declared labels.  IIRC some people wanted these t
 >o be
 >>  >> preserved, e.g. for debugging purposes.  Perhaps tree_can_merge_blocks_
 >p
 >>  >> should be false if a user label heads the basic block.
 >>  >
 >>  >there is IMHO no point in this, since rtl level cfgcleanup would do the
 >>  >merging and removing of the label anyway.
 >> If the RTL cfgcleanup is removing a user label, then that code is buggy.
 >
 >actually it turns them into NOTE_INSN_DELETED_LABEL (I have forgotten
 >this when writing the mail).
And if you look at final.c, when such a note is encountered we output
a debugging label into the assembly stream.

So I ask again, please do not remove user labels.  They need to be
preserved.

jeff


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