PR ipa/64550
PR ipa/64551
PR ipa/64552
* ipa-icf.c (sem_function::equals_private): Use '&&' instead of
'||' to fix typo issue.
* gcc/tree.h (target_opts_for_fn): Check NULL_TREE since it can
accept and return NULL.
From-SVN: r219449
+2015-01-12 Chen Gang <gang.chen.5i5j@gmail.com>
+
+ PR ipa/64550
+ PR ipa/64551
+ PR ipa/64552
+ * ipa-icf.c (sem_function::equals_private): Use '&&' instead of
+ '||' to fix typo issue.
+
+ * gcc/tree.h (target_opts_for_fn): Check NULL_TREE since it can
+ accept and return NULL.
+
2015-01-12 Martin Liska <mliska@suse.cz>
* cgraph.c (cgraph_edge::remove_callee): Move function to header
cl_target_option *tar1 = target_opts_for_fn (decl);
cl_target_option *tar2 = target_opts_for_fn (m_compared_func->decl);
- if (tar1 != NULL || tar2 != NULL)
+ if (tar1 != NULL && tar2 != NULL)
{
if (!cl_target_option_eq (tar1, tar2))
{
tree fn_opts = DECL_FUNCTION_SPECIFIC_TARGET (fndecl);
if (fn_opts == NULL_TREE)
fn_opts = target_option_default_node;
- return TREE_TARGET_OPTION (fn_opts);
+ return fn_opts == NULL_TREE ? NULL : TREE_TARGET_OPTION (fn_opts);
}
/* opt flag for function FNDECL, e.g. opts_for_fn (fndecl, optimize) is