Commit 203a92e3 by Eric Botcazou Committed by Eric Botcazou

opts.c (handle_option): Call into LTO streamer only if ENABLE_LTO.

	* opts.c (handle_option): Call into LTO streamer only if ENABLE_LTO.
	(decode_options): Likewise.
	* Makefile.in (opts.o): Add dependency on LTO_STREAMER_H.

From-SVN: r159463
parent afdda4b4
2010-05-16 Eric Botcazou <ebotcazou@adacore.com>
* opts.c (handle_option): Call into LTO streamer only if ENABLE_LTO.
(decode_options): Likewise.
* Makefile.in (opts.o): Add dependency on LTO_STREAMER_H.
2010-05-16 Jan Hubicka <jh@suse.cz>
* ipa.c (function_and_variable_visibility): Also bring local all
......
......@@ -2704,7 +2704,7 @@ opts.o : opts.c opts.h options.h $(TOPLEV_H) $(CONFIG_H) $(SYSTEM_H) \
coretypes.h $(TREE_H) $(TM_H) langhooks.h $(GGC_H) $(EXPR_H) $(RTL_H) \
output.h $(DIAGNOSTIC_H) $(TM_P_H) $(INSN_ATTR_H) intl.h $(TARGET_H) \
$(FLAGS_H) $(PARAMS_H) $(TREE_PASS_H) $(DBGCNT_H) debug.h \
$(PLUGIN_H) $(EXCEPT_H)
$(PLUGIN_H) $(EXCEPT_H) $(LTO_STREAMER_H)
opts-common.o : opts-common.c opts.h $(CONFIG_H) $(SYSTEM_H) \
coretypes.h intl.h
targhooks.o : targhooks.c $(CONFIG_H) $(SYSTEM_H) coretypes.h $(TREE_H) \
......
......@@ -502,24 +502,30 @@ handle_option (int opt_index, int value, const char *arg,
{
if (lang_hooks.handle_option (opt_index, arg, value, kind) == 0)
return false;
#ifdef ENABLE_LTO
else
lto_register_user_option (opt_index, arg, value, lang_mask);
#endif
}
if (option->flags & CL_COMMON)
{
if (common_handle_option (opt_index, arg, value, lang_mask, kind) == 0)
return false;
#ifdef ENABLE_LTO
else
lto_register_user_option (opt_index, arg, value, CL_COMMON);
#endif
}
if (option->flags & CL_TARGET)
{
if (!targetm.handle_option (opt_index, arg, value))
return false;
#ifdef ENABLE_LTO
else
lto_register_user_option (opt_index, arg, value, CL_TARGET);
#endif
}
return true;
}
......@@ -980,8 +986,10 @@ decode_options (unsigned int argc, const char **argv)
flag_unwind_tables = targetm.unwind_tables_default;
}
#ifdef ENABLE_LTO
/* Clear any options currently held for LTO. */
lto_clear_user_options ();
#endif
#ifdef OPTIMIZATION_OPTIONS
/* Allow default optimizations to be specified on a per-machine basis. */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment