diff options
author | Roger Sayle <roger@eyesopen.com> | 2003-01-25 17:42:39 +0000 |
---|---|---|
committer | Roger Sayle <sayle@gcc.gnu.org> | 2003-01-25 17:42:39 +0000 |
commit | 07d9b20d818e83c12fee88ea4c41f3788ccee94b (patch) | |
tree | b21f72610d0ef15b8f89e3f3117d170b5ca05f55 /gcc/builtins.c | |
parent | 415591122da665db1059faae87fb2d8c8097ffb6 (diff) | |
download | gcc-07d9b20d818e83c12fee88ea4c41f3788ccee94b.zip gcc-07d9b20d818e83c12fee88ea4c41f3788ccee94b.tar.gz gcc-07d9b20d818e83c12fee88ea4c41f3788ccee94b.tar.bz2 |
function.h (struct function): New field calls_constant_p.
* function.h (struct function): New field calls_constant_p.
(current_function_calls_constant_p): New macro for above.
* function.c (prepare_function_start): Initialize calls_eh_return
and calls_constant_p.
* builtins.c (expand_builtin_constant_p): Set calls_constant_p.
* toplev.c (rest_of_compilation): Only call purge_builtin_constant_p
when the current_function_calls_constant_p.
* integrate.c (expand_inline_function): Set calls_constant_p if
the function being inlined has calls_constant_p set.
From-SVN: r61786
Diffstat (limited to 'gcc/builtins.c')
-rw-r--r-- | gcc/builtins.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/builtins.c b/gcc/builtins.c index d544410..95f9494 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -1469,6 +1469,8 @@ expand_builtin_constant_p (exp) case is not obvious, so emit (constant_p_rtx (ARGLIST)) and let CSE get a chance to see if it can deduce whether ARGLIST is constant. */ + current_function_calls_constant_p = 1; + tmp = expand_expr (arglist, NULL_RTX, VOIDmode, 0); tmp = gen_rtx_CONSTANT_P_RTX (value_mode, tmp); return tmp; |