diff options
author | Martin Liska <mliska@suse.cz> | 2016-10-14 14:08:27 +0200 |
---|---|---|
committer | Martin Liska <marxin@gcc.gnu.org> | 2016-10-14 12:08:27 +0000 |
commit | a918bfbf3c5b686362f3f97314c2b4bf142d2f82 (patch) | |
tree | c896ce6d1d5d5cec3b0369bdda9ddacf3ad4f63f /gcc/fold-const-call.h | |
parent | ace4c2f060160bd3ef9032cc151e36b84e4ba3e8 (diff) | |
download | gcc-a918bfbf3c5b686362f3f97314c2b4bf142d2f82.zip gcc-a918bfbf3c5b686362f3f97314c2b4bf142d2f82.tar.gz gcc-a918bfbf3c5b686362f3f97314c2b4bf142d2f82.tar.bz2 |
Fold __builtin_str{n}{case}cmp functions
* builtins.c (fold_builtin_strcmp): Remove function.
(fold_builtin_strncmp): Likewise.
(fold_builtin_2): Remove call of the function.
(fold_builtin_3): Likewise.
* fold-const-call.c (fold_const_call): Add constant folding
for CFN_BUILT_IN_STRCASECMP and CFN_BUILT_IN_STRNCASECMP.
* fold-const-call.h (build_cmp_result): Declare the function.
* gimple-fold.c (gimple_load_first_char): New function.
(gimple_fold_builtin_string_compare): Likewise.
(gimple_fold_builtin): Call the function.
From-SVN: r241159
Diffstat (limited to 'gcc/fold-const-call.h')
-rw-r--r-- | gcc/fold-const-call.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/fold-const-call.h b/gcc/fold-const-call.h index 324ecbf..7f61f2e 100644 --- a/gcc/fold-const-call.h +++ b/gcc/fold-const-call.h @@ -24,5 +24,6 @@ tree fold_const_call (combined_fn, tree, tree); tree fold_const_call (combined_fn, tree, tree, tree); tree fold_const_call (combined_fn, tree, tree, tree, tree); tree fold_fma (location_t, tree, tree, tree, tree); +tree build_cmp_result (tree type, int res); #endif |