On 09/20/2016 03:27 PM, Pat Haugen wrote:
The following patch corrects frequency/count values computed when generating 
the switch blocks/peeled loop copies before the loop. The two main problem 
areas were for the peeled copies duplicate_loop_to_header_edge was not using 
the preheader frequency as part of the scale factor when peeling a copy of the 
loop to the preheader edge, and the second was that the switch block generation 
was just totally lacking code to compute correct freq/count values. Verified by 
comparing freq/count values in the unroller dump before/after.

Bootstrap/regtest on powerpc64le with no new regressions. Ok for trunk?


2016-09-20  Pat Haugen  <pthau...@us.ibm.com>

        PR rtl-optimization/68212
        * cfgloopmanip.c (duplicate_loop_to_header_edge): Use preheader edge
        frequency when computing scale factor for peeled copies.
        * loop-unroll.c (unroll_loop_runtime_iterations): Fix freq/count
        values for switch/peel blocks/edges.

OK.  Thanks for your patience.


Reply via email to