diff options
author | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-09-01 07:29:23 +0000 |
---|---|---|
committer | bstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-09-01 07:29:23 +0000 |
commit | d5e0534e64b525e8dca8e2fa05455011031c643a (patch) | |
tree | 61d274e19b123144c2895546960a996641555928 /gcc/tree-ssa-loop-unswitch.c | |
parent | a30fe044170c44da9e441535e2167ca8e885b3cb (diff) | |
download | gcc-d5e0534e64b525e8dca8e2fa05455011031c643a.tar.gz |
2008-09-01 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk r139848
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@139851 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-ssa-loop-unswitch.c')
-rw-r--r-- | gcc/tree-ssa-loop-unswitch.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gcc/tree-ssa-loop-unswitch.c b/gcc/tree-ssa-loop-unswitch.c index 850270f49c0..26abed2dd8f 100644 --- a/gcc/tree-ssa-loop-unswitch.c +++ b/gcc/tree-ssa-loop-unswitch.c @@ -198,6 +198,14 @@ tree_unswitch_single_loop (struct loop *loop, int num) return false; } + /* Do not unswitch in cold regions. */ + if (optimize_loop_for_size_p (loop)) + { + if (dump_file && (dump_flags & TDF_DETAILS)) + fprintf (dump_file, ";; Not unswitching cold loops\n"); + return false; + } + /* The loop should not be too large, to limit code growth. */ if (tree_num_loop_insns (loop, &eni_size_weights) > (unsigned) PARAM_VALUE (PARAM_MAX_UNSWITCH_INSNS)) |