From: Jakub Jelinek Date: Sat, 19 Nov 2016 18:57:56 +0000 (+0100) Subject: i386.c (ix86_can_inline_p): Use || instead of & when checking if callee's isa flags... X-Git-Tag: upstream/12.2.0~43162 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=90b47c517429ab7a0fffd2ba5e64d4737e87125f;p=platform%2Fupstream%2Fgcc.git i386.c (ix86_can_inline_p): Use || instead of & when checking if callee's isa flags are subset of caller's... * config/i386/i386.c (ix86_can_inline_p): Use || instead of & when checking if callee's isa flags are subset of caller's isa flags. Fix comment wording. From-SVN: r242628 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c3c5c16..23de483c 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,9 @@ 2016-11-19 Jakub Jelinek + * config/i386/i386.c (ix86_can_inline_p): Use || instead of & + when checking if callee's isa flags are subset of caller's isa flags. + Fix comment wording. + * config/i386/i386.c (ix86_valid_target_attribute_tree): Don't clear opts->x_ix86_isa_flags, clear opts->x_ix86_isa_flags2 instead and using = 0 instead of &= 0. diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index 9596537..2db1e89 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -6981,13 +6981,13 @@ ix86_can_inline_p (tree caller, tree callee) struct cl_target_option *caller_opts = TREE_TARGET_OPTION (caller_tree); struct cl_target_option *callee_opts = TREE_TARGET_OPTION (callee_tree); - /* Callee's isa options should a subset of the caller's, i.e. a SSE4 function - can inline a SSE2 function but a SSE2 function can't inline a SSE4 - function. */ + /* Callee's isa options should be a subset of the caller's, i.e. a SSE4 + function can inline a SSE2 function but a SSE2 function can't inline + a SSE4 function. */ if (((caller_opts->x_ix86_isa_flags & callee_opts->x_ix86_isa_flags) - != callee_opts->x_ix86_isa_flags) & - ((caller_opts->x_ix86_isa_flags2 & callee_opts->x_ix86_isa_flags2) - != callee_opts->x_ix86_isa_flags2)) + != callee_opts->x_ix86_isa_flags) + || ((caller_opts->x_ix86_isa_flags2 & callee_opts->x_ix86_isa_flags2) + != callee_opts->x_ix86_isa_flags2)) ret = false; /* See if we have the same non-isa options. */