From: Martin Liska Date: Wed, 28 Mar 2018 14:22:27 +0000 (+0200) Subject: Do not call chkp_type_bounds_count if MPX is not enabled (PR target/84988). X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a48b4234ddba56e6ac698a8a84f24176085dc099;p=gcc.git Do not call chkp_type_bounds_count if MPX is not enabled (PR target/84988). 2018-03-28 Martin Liska PR target/84988 * config/i386/i386.c (ix86_function_arg_advance): Do not call chkp_type_bounds_count if MPX is not enabled. From-SVN: r258923 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f7f37cb0717..33f78bc91ba 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2018-03-28 Martin Liska + + PR target/84988 + * config/i386/i386.c (ix86_function_arg_advance): Do not call + chkp_type_bounds_count if MPX is not enabled. + 2018-03-27 Chung-Ju Wu * config/nds32/nds32.h (BRANCH_COST): Adjust cost. diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index b4f6aec1434..2b2896f7ac6 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -8618,7 +8618,8 @@ ix86_function_arg_advance (cumulative_args_t cum_v, machine_mode mode, if (cum->caller) cfun->machine->outgoing_args_on_stack = true; - cum->bnds_in_bt = chkp_type_bounds_count (type); + if (flag_check_pointer_bounds) + cum->bnds_in_bt = chkp_type_bounds_count (type); } }