diff options
author | Mark Mitchell <mark@codesourcery.com> | 1999-09-17 22:18:59 +0000 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 1999-09-17 22:18:59 +0000 |
commit | e6fd097efca2e3f76d3fe51c55cd124998b7fd42 (patch) | |
tree | 746da641a670a45baec442090a6d5de50aee6389 /gcc/stmt.c | |
parent | ba7166773bd7a4d1e0da5bad0a61c20fac3bef78 (diff) | |
download | gcc-e6fd097efca2e3f76d3fe51c55cd124998b7fd42.zip gcc-e6fd097efca2e3f76d3fe51c55cd124998b7fd42.tar.gz gcc-e6fd097efca2e3f76d3fe51c55cd124998b7fd42.tar.bz2 |
functiion.h (struct function): Add x_whole_function_mode_p.
* functiion.h (struct function): Add x_whole_function_mode_p.
(retrofit_block): Declare.
* function.c (retrofit_block): New function.
(identify_blocks): Add assertions. Allow an incomplete set of
block notes if we're still generating code for the function.
* integrate.c: Include loop.h.
(expand_inline_function): Call find_loop_tree_blocks to map block
notes to blocks when in whole-function mode. Use retrofit_block
to insert new BLOCKs for the inlined function, rather than
insert_block.
* stmt.c (expand_fixup): Likewise. Don't use pushlevel/polevel.
* Makefile.in (integrate.o): Depend on loop.h.
From-SVN: r29487
Diffstat (limited to 'gcc/stmt.c')
-rw-r--r-- | gcc/stmt.c | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -1016,13 +1016,24 @@ expand_fixup (tree_label, rtl_label, last_insn) register rtx original_before_jump = last_insn ? last_insn : get_last_insn (); rtx start; + tree block; + + block = make_node (BLOCK); + TREE_USED (block) = 1; + + if (current_function->x_whole_function_mode_p) + { + find_loop_tree_blocks (); + retrofit_block (block, original_before_jump); + } + else + insert_block (block); start_sequence (); - pushlevel (0); start = emit_note (NULL_PTR, NOTE_INSN_BLOCK_BEG); fixup->before_jump = emit_note (NULL_PTR, NOTE_INSN_DELETED); last_block_end_note = emit_note (NULL_PTR, NOTE_INSN_BLOCK_END); - fixup->context = poplevel (1, 0, 0); /* Create the BLOCK node now! */ + fixup->context = block; end_sequence (); emit_insns_after (start, original_before_jump); } |