diff options
author | merrill <merrill@138bc75d-0d04-0410-961f-82ee72b054a4> | 1995-04-20 22:26:30 +0000 |
---|---|---|
committer | merrill <merrill@138bc75d-0d04-0410-961f-82ee72b054a4> | 1995-04-20 22:26:30 +0000 |
commit | 7754c6a482ff22221bf69e79a91110d9ca87a3d2 (patch) | |
tree | 2bc0dae2f3e3cca9188a8d15dbda1bb8205f033a /gcc/calls.c | |
parent | 7a4ddf9057619164a54fae38314f485fcf9cc982 (diff) | |
download | gcc-7754c6a482ff22221bf69e79a91110d9ca87a3d2.tar.gz |
Use TREE_ADDRESSABLE rather than
| TYPE_NEEDS_CONSTRUCTING to decide whether a parameter needs to be
| passed by invisible reference.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@9420 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/calls.c')
-rw-r--r-- | gcc/calls.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/calls.c b/gcc/calls.c index a8b6d3e47ec..63125a3e1fc 100644 --- a/gcc/calls.c +++ b/gcc/calls.c @@ -1022,7 +1022,7 @@ expand_call (exp, target, ignore) /* See if this argument should be passed by invisible reference. */ if ((TREE_CODE (TYPE_SIZE (type)) != INTEGER_CST && contains_placeholder_p (TYPE_SIZE (type))) - || TYPE_NEEDS_CONSTRUCTING (type) + || TREE_ADDRESSABLE (type) #ifdef FUNCTION_ARG_PASS_BY_REFERENCE || FUNCTION_ARG_PASS_BY_REFERENCE (args_so_far, TYPE_MODE (type), type, argpos < n_named_args) @@ -1325,6 +1325,10 @@ expand_call (exp, target, ignore) || (must_preallocate && (args_size.var != 0 || args_size.constant != 0) && calls_function (args[i].tree_value, 0))) { + /* If this is an addressable type, we cannot pre-evaluate it. */ + if (TREE_ADDRESSABLE (TREE_TYPE (args[i].tree_value))) + abort (); + push_temp_slots (); args[i].initial_value = args[i].value |