This patch unsets -freorder-blocks-and-partition when -fprofile-use is not specified.
authorTeresa Johnson <tejohnson@google.com>
Fri, 25 Sep 2015 16:53:40 +0000 (16:53 +0000)
committerTeresa Johnson <tejohnson@gcc.gnu.org>
Fri, 25 Sep 2015 16:53:40 +0000 (16:53 +0000)
commit6697104844b95eb653a26e725f70600bdade0150
tree0929635a605ef836dda743b622ad63f002335dba
parent5e2f2cd5842d2543721a895c64a3b2a553542344
This patch unsets -freorder-blocks-and-partition when -fprofile-use is not specified.

This patch unsets -freorder-blocks-and-partition when -fprofile-use
is not specified. Function splitting was not actually being performed
in that case, as probably_never_executed_bb_p does not distinguish
any basic blocks as being cold vs hot when there is no profile data.
Leaving it enabled, however, causes the assembly code generator to create
(empty) cold sections and labels, leading to unnecessary size overhead.

2015-09-25  Teresa Johnson  <tejohnson@google.com>

* opts.c (finish_options): Unset -freorder-blocks-and-partition
if not using profile.

From-SVN: r228136
gcc/ChangeLog
gcc/opts.c