[PATCH]: Better comments for hot/cold partitioning code.

Caroline Tice ctice@apple.com
Wed Aug 25 19:23:00 GMT 2004

If I understood all the comments correctly, the final decision was that 
even though the mess with
cfg cleanup is unfortunate, there is no better way (at the moment) to 
handle the hot/cold partitioning
stuff, and therefore the best thing to be done is to add better 
comments at all the cfg cleanup
conflict points, and at the start of the main partitioning function.  
(If I have misunderstood what people
want me to do, please let me know).

This patch updates all the comments as requested.  It only changes 
comments/documentation, so I
have not performed any testing on it.

I am continuing to work on other requests I have received: cleaning up 
redundant/unnecessary test cases;
changing final.c to not perform instruction stream searching; making 
sure, within a function's cfg, that
all the hot blocks are together and all the cold blocks are together; 
and fixing up the debugging
information (and cleaning up the warning).  I will probably submit 
those changes as two separate patches:
"everything but the debugging stuff" and "the debugging stuff".  If 
there are any *other* concerns that people
want me to address that I have not mentioned here, please let me know.

Is this patch (the comment updates) okay to commit to FSF mainline?

-- Caroline Tice

2004-08-25  Caroline Tice  <ctice@apple.com>

         * bb-reorder.c (partition_hot_cold_basic_blocks):  Add more 
         to comments at start of function.
         * cfgbuild.c (make_edges):  Add more details to hot/cold 
         * cfgcleanup.c (try_simplify_condjump, try_forward_edges,
         merge_blocks_move_successor_nojumps, merge_blocks_move,
         try_crossjump_to_edge, try_crossjump_bb): Likewise.
         * cfglayout.c (fixup_reorder_chain): Likewise.
         * cfgrtl.c (rtl_can_merge_blocks, 
         cfg_layout_can_merge_blocks_p):  Likewise.
         * ifcvt.c (find_if_case_1, find_if_case_2): Likewise.
         * passes.c (rest_of_compilation): Update comments for calling
         optimization that partitions hot/cold basic blocks.
         * doc/invoke.texi:  Update documentation of
         freorder-blocks-and-partition flag.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: gcc5-hot-cold2.txt
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20040825/6e3fedeb/attachment.txt>

More information about the Gcc-patches mailing list