diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-07-24 15:18:09 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-07-24 15:18:09 +0000 |
commit | a264508e63ef6e7a894f70e31e41524f9cf90197 (patch) | |
tree | 3629f5a97b5846f8e55be0d88df35de4ce99df93 /gcc/toplev.c | |
parent | e39b5eb95ba853a1a4b1fce407d8c8958d6c1589 (diff) | |
download | gcc-a264508e63ef6e7a894f70e31e41524f9cf90197.tar.gz |
gcc/
* rtl.h (target_rtl): Remove lang_dependent_initialized.
* toplev.c (initialize_rtl): Don't use it. Move previously
"language-dependent" calls to...
(backend_init): ...here.
(lang_dependent_init_target): Don't set lang_dependent_initialized.
Assert that RTL initialization hasn't happend yet.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@213004 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/toplev.c')
-rw-r--r-- | gcc/toplev.c | 31 |
1 files changed, 10 insertions, 21 deletions
diff --git a/gcc/toplev.c b/gcc/toplev.c index 2886df71bc0..c2d4232523e 100644 --- a/gcc/toplev.c +++ b/gcc/toplev.c @@ -1607,6 +1607,10 @@ backend_init_target (void) on a mode change. */ init_expmed (); init_lower_subreg (); + init_set_costs (); + + init_expr_target (); + ira_init (); /* We may need to recompute regno_save_code[] and regno_restore_code[] after a mode change as well. */ @@ -1685,7 +1689,8 @@ lang_dependent_init_target (void) front end is initialized. It also depends on the HAVE_xxx macros generated from the target machine description. */ init_optabs (); - this_target_rtl->lang_dependent_initialized = false; + + gcc_assert (!this_target_rtl->target_specific_initialized); } /* Perform initializations that are lang-dependent or target-dependent. @@ -1704,26 +1709,10 @@ initialize_rtl (void) /* Target specific RTL backend initialization. */ if (!this_target_rtl->target_specific_initialized) - backend_init_target (); - this_target_rtl->target_specific_initialized = true; - - if (this_target_rtl->lang_dependent_initialized) - return; - this_target_rtl->lang_dependent_initialized = true; - - /* The following initialization functions need to generate rtl, so - provide a dummy function context for them. */ - init_dummy_function_start (); - - /* Do the target-specific parts of expr initialization. */ - init_expr_target (); - - /* Although the actions of these functions are language-independent, - they use optabs, so we cannot call them from backend_init. */ - init_set_costs (); - ira_init (); - - expand_dummy_function_end (); + { + backend_init_target (); + this_target_rtl->target_specific_initialized = true; + } } /* Language-dependent initialization. Returns nonzero on success. */ |