+2014-11-17 Jan Hubicka <hubicka@ucw.cz>
+
+ * tree.c (free_lang_data_in_decl): Annotate all functio nbodies with
+ DECL_FUNCTION_SPECIFIC_TARGET.
+ * i386.c (ix86_set_current_function): Handle explicit default options.
+
2014-11-17 Ilya Enkovich <ilya.enkovich@intel.com>
* builtins.c (expand_builtin_memcpy_with_bounds): Use target hook
if (old_tree == new_tree)
;
- else if (new_tree)
+ else if (new_tree && new_tree != target_option_default_node)
{
cl_target_option_restore (&global_options,
TREE_TARGET_OPTION (new_tree));
= save_target_globals_default_opts ();
}
- else if (old_tree)
+ else if (old_tree && old_tree != target_option_default_node)
ix86_reset_to_default_globals ();
ix86_previous_fndecl = fndecl;
}
+2014-11-17 Jan Hubicka <hubicka@ucw.cz>
+
+ * lto.c (lto_read_decls): Do not rebuild DECL_FUNCTION_SPECIFIC_TARGET.
+
2014-11-14 Jan Hubicka <hubicka@ucw.cz>
* lto.c (compare_tree_sccs_1): Compare cl_target_option_eq.
if (TREE_CODE (t) == INTEGER_CST
&& !TREE_OVERFLOW (t))
cache_integer_cst (t);
- /* Re-build DECL_FUNCTION_SPECIFIC_TARGET, we need that
- for both WPA and LTRANS stage. */
- if (TREE_CODE (t) == FUNCTION_DECL)
- {
- tree attr = lookup_attribute ("target", DECL_ATTRIBUTES (t));
- if (attr)
- targetm.target_option.valid_attribute_p
- (t, NULL_TREE, TREE_VALUE (attr), 0);
- }
/* Register TYPE_DECLs with the debuginfo machinery. */
if (!flag_wpa
&& TREE_CODE (t) == TYPE_DECL)
the PARM_DECL will be used in the function's body). */
for (t = DECL_ARGUMENTS (decl); t; t = TREE_CHAIN (t))
DECL_CONTEXT (t) = decl;
+ if (!DECL_FUNCTION_SPECIFIC_TARGET (decl))
+ DECL_FUNCTION_SPECIFIC_TARGET (decl)
+ = target_option_default_node;
}
/* DECL_SAVED_TREE holds the GENERIC representation for DECL.