shrink-wrap: Rewrite
authorSegher Boessenkool <segher@kernel.crashing.org>
Tue, 15 Sep 2015 00:38:21 +0000 (02:38 +0200)
committerSegher Boessenkool <segher@gcc.gnu.org>
Tue, 15 Sep 2015 00:38:21 +0000 (02:38 +0200)
commit23997c53b8f7696d6ba484913835b19287f96f82
treed9a541717d4670d10789ddcd410d796e10b6f89c
parent311adabec523e8ad99930cd2e24716098ed77fc7
shrink-wrap: Rewrite

This patch rewrites the shrink-wrapping algorithm, allowing non-linear
pieces of CFG to be duplicated for use without prologue instead of just
linear pieces.

* shrink-wrap.c (requires_stack_frame_p): Fix formatting.
(dup_block_and_redirect): Delete function.
(can_dup_for_shrink_wrapping): New function.
(fix_fake_fallthrough_edge): New function.
(try_shrink_wrapping): Rewrite function.
(convert_to_simple_return): Call fix_fake_fallthrough_edge.

From-SVN: r227775
gcc/ChangeLog
gcc/shrink-wrap.c