Re: [PATCH] Fix PR68212, unrolled loop no longer aligned

2018-11-28 Thread Jan Hubicka
> 2018-11-28 Pat Haugen > > PR rtl-optimization/68212 > * cfgloopmanip.c (duplicate_loop_to_header_edge): Adjust scale factor. > > testsuite/ChangeLog: > 2018-11-28 Pat Haugen > > PR rtl-optimization/68212 > * gcc.dg/pr68212.c: New test. > > > > Index: gc

[PATCH] Fix PR68212, unrolled loop no longer aligned

2018-11-28 Thread Pat Haugen
The following patch fixes the case where unrolling in the absence of profile information can cause a loop to no longer look hot and therefor not get aligned. In this case, instead of dividing by the unroll factor we now just scale by profile_probability::likely (). The diff looks worse than what