diff options
author | Richard Biener <rguenther@suse.de> | 2015-06-30 08:52:48 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2015-06-30 08:52:48 +0000 |
commit | 582554e3bc1509b6ddc407004f97e3f756bcedf5 (patch) | |
tree | b1ed01f79f0cbb1722548c3388771b77be0e8607 /gcc/expr.c | |
parent | 4f75d60893e092cffcbe422825ce4dc092d3fb9e (diff) | |
download | gcc-582554e3bc1509b6ddc407004f97e3f756bcedf5.zip gcc-582554e3bc1509b6ddc407004f97e3f756bcedf5.tar.gz gcc-582554e3bc1509b6ddc407004f97e3f756bcedf5.tar.bz2 |
target-insns.def (canonicalize_funcptr_for_compare): Add.
2015-06-30 Richard Biener <rguenther@suse.de>
* target-insns.def (canonicalize_funcptr_for_compare): Add.
* fold-const.c (build_range_check): Replace uses of
HAVE_canonicalize_funcptr_for_compare.
(fold_widened_comparison): Likewise.
(fold_sign_changed_comparison): Likewise.
* dojump.c: Include "target.h".
(do_compare_and_jump): Replace uses of
HAVE_canonicalize_funcptr_for_compare and
gen_canonicalize_funcptr_for_compare.
* expr.c (do_store_flag): Likewise.
From-SVN: r225163
Diffstat (limited to 'gcc/expr.c')
-rw-r--r-- | gcc/expr.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -8916,7 +8916,7 @@ expand_expr_real_2 (sepops ops, rtx target, machine_mode tmode, return temp; /* Use a compare and a jump for BLKmode comparisons, or for function - type comparisons is HAVE_canonicalize_funcptr_for_compare. */ + type comparisons is have_canonicalize_funcptr_for_compare. */ if ((target == 0 || modifier == EXPAND_STACK_PARM @@ -10920,8 +10920,7 @@ do_store_flag (sepops ops, rtx target, machine_mode mode) /* We won't bother with store-flag operations involving function pointers when function pointers must be canonicalized before comparisons. */ -#ifdef HAVE_canonicalize_funcptr_for_compare - if (HAVE_canonicalize_funcptr_for_compare + if (targetm.have_canonicalize_funcptr_for_compare () && ((TREE_CODE (TREE_TYPE (arg0)) == POINTER_TYPE && (TREE_CODE (TREE_TYPE (TREE_TYPE (arg0))) == FUNCTION_TYPE)) @@ -10929,7 +10928,6 @@ do_store_flag (sepops ops, rtx target, machine_mode mode) && (TREE_CODE (TREE_TYPE (TREE_TYPE (arg1))) == FUNCTION_TYPE)))) return 0; -#endif STRIP_NOPS (arg0); STRIP_NOPS (arg1); |