diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2013-03-04 17:41:32 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2013-03-04 17:41:32 +0000 |
commit | 22110e6c5710e3786e097cc0843f59a3376ee94f (patch) | |
tree | c430041e9450edc881a1c1f7ab9daed21e93d52f /gcc/ipa-split.c | |
parent | e5cb02e200ea3cdd71a57cba4d77b41e0745a58c (diff) | |
download | gcc-22110e6c5710e3786e097cc0843f59a3376ee94f.zip gcc-22110e6c5710e3786e097cc0843f59a3376ee94f.tar.gz gcc-22110e6c5710e3786e097cc0843f59a3376ee94f.tar.bz2 |
re PR tree-optimization/56424 (ICE at tree-inline.c:2833 on a-nllcef.ads at -O2)
PR tree-optimization/56424
* ipa-split.c (split_function): Do not set the RSO flag if result is
not by reference and its type is a register type.
From-SVN: r196439
Diffstat (limited to 'gcc/ipa-split.c')
-rw-r--r-- | gcc/ipa-split.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/ipa-split.c b/gcc/ipa-split.c index e3db78f..e7d469d 100644 --- a/gcc/ipa-split.c +++ b/gcc/ipa-split.c @@ -1309,7 +1309,9 @@ split_function (struct split_point *split_point) so return slot optimization is always possible. Moreover this is required to make DECL_BY_REFERENCE work. */ if (aggregate_value_p (DECL_RESULT (current_function_decl), - TREE_TYPE (current_function_decl))) + TREE_TYPE (current_function_decl)) + && (!is_gimple_reg_type (TREE_TYPE (DECL_RESULT (current_function_decl))) + || DECL_BY_REFERENCE (DECL_RESULT (current_function_decl)))) gimple_call_set_return_slot_opt (call, true); /* Update return value. This is bit tricky. When we do not return, |