diff options
author | Steven Bosscher <stevenb@suse.de> | 2005-02-01 10:03:15 +0000 |
---|---|---|
committer | Steven Bosscher <steven@gcc.gnu.org> | 2005-02-01 10:03:15 +0000 |
commit | bbcb0c056be0883aa970eb5552bb713d516d9c1e (patch) | |
tree | 87553ed6cbe3253976ee763b34f7a58ef2a27ed1 /gcc/passes.c | |
parent | e88334a68f98bc5ca30180787f9c67512b568ab7 (diff) | |
download | gcc-bbcb0c056be0883aa970eb5552bb713d516d9c1e.zip gcc-bbcb0c056be0883aa970eb5552bb713d516d9c1e.tar.gz gcc-bbcb0c056be0883aa970eb5552bb713d516d9c1e.tar.bz2 |
re PR rtl-optimization/15242 (pessimization of "goto *")
PR optimization/15242
* params.def (PARAM_MAX_GOTO_DUPLICATION_INSNS): New param.
* basic-block.h (duplicate_computed_gotos): Add prototype.
* bb-reorder.c (duplicate_computed_gotos): New function to
duplicate sufficiently small blocks ending in a computed jump.
* passes.c (rest_of_compilation): Call duplicate_computed_gotos
if not optimizing for size.
* cfgcleanup.c (try_crossjump_bb): If not optimizing for size,
never do tail merging for blocks ending in a computed jump.
* doc/invoke.texi: Document the max-goto-duplication-insns param.
From-SVN: r94531
Diffstat (limited to 'gcc/passes.c')
-rw-r--r-- | gcc/passes.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/passes.c b/gcc/passes.c index 3d4c679..723656f 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -1713,6 +1713,11 @@ rest_of_compilation (void) compute_alignments (); + /* Aggressively duplicate basic blocks ending in computed gotos to the + tails of their predecessors, unless we are optimizing for size. */ + if (flag_expensive_optimizations && !optimize_size) + duplicate_computed_gotos (); + if (flag_var_tracking) rest_of_handle_variable_tracking (); |