diff options
| author | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-04-19 04:41:34 +0000 |
|---|---|---|
| committer | rth <rth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-04-19 04:41:34 +0000 |
| commit | 7b185825b67a707f5510774ddec015bcec214e22 (patch) | |
| tree | 011f22bf1211c4716db4b4fdaacc7666e30d69f6 /gcc | |
| parent | 5410141b43c949c287aabbe5bc8808a6309f9430 (diff) | |
| download | ppe42-gcc-7b185825b67a707f5510774ddec015bcec214e22.tar.gz ppe42-gcc-7b185825b67a707f5510774ddec015bcec214e22.zip | |
* function.c: Revert patch for c/6358.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@52511 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
| -rw-r--r-- | gcc/ChangeLog | 16 | ||||
| -rw-r--r-- | gcc/function.c | 47 |
2 files changed, 24 insertions, 39 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 6a2aa3ea144..dabbf94c453 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,15 +1,19 @@ 2002-04-18 Richard Henderson <rth@redhat.com> - * ifcvt.c (find_cond_trap): Handle cases with no proper THEN or JOIN - blocks. Handle multiple references to the TRAP block. Handle - non-adjacent THEN and OTHER blocks. + * function.c: Revert patch for c/6358. 2002-04-18 Richard Henderson <rth@redhat.com> - * config/ia64/ia64.c (ia64_function_arg_pass_by_reference): Don't - crash with no type for by-mode libcalls. + * ifcvt.c (find_cond_trap): Handle cases with no proper THEN or JOIN + blocks. Handle multiple references to the TRAP block. Handle + non-adjacent THEN and OTHER blocks. - * config/ia64/ia64.md (conditional_trap): Fix predicate polarity. +2002-04-18 Richard Henderson <rth@redhat.com> + + * config/ia64/ia64.c (ia64_function_arg_pass_by_reference): Don't + crash with no type for by-mode libcalls. + + * config/ia64/ia64.md (conditional_trap): Fix predicate polarity. 2002-04-18 Bob Wilson <bob.wilson@acm.org> diff --git a/gcc/function.c b/gcc/function.c index 4562376ce49..86a87ab6068 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -5145,35 +5145,6 @@ assign_parms (fndecl) current_function_return_rtx = (DECL_RTL_SET_P (DECL_RESULT (fndecl)) ? DECL_RTL (DECL_RESULT (fndecl)) : NULL_RTX); - - /* If scalar return value was computed in a pseudo-reg, or was a named - return value that got dumped to the stack, copy that to the hard - return register. */ - if (DECL_RTL_SET_P (DECL_RESULT (fndecl))) - { - tree decl_result = DECL_RESULT (fndecl); - rtx decl_rtl = DECL_RTL (decl_result); - - if (REG_P (decl_rtl) - ? REGNO (decl_rtl) >= FIRST_PSEUDO_REGISTER - : DECL_REGISTER (decl_result)) - { - rtx real_decl_rtl; - -#ifdef FUNCTION_OUTGOING_VALUE - real_decl_rtl = FUNCTION_OUTGOING_VALUE (TREE_TYPE (decl_result), - fndecl); -#else - real_decl_rtl = FUNCTION_VALUE (TREE_TYPE (decl_result), - fndecl); -#endif - REG_FUNCTION_VALUE_P (real_decl_rtl) = 1; - /* The delay slot scheduler assumes that current_function_return_rtx - holds the hard register containing the return value, not a - temporary pseudo. */ - current_function_return_rtx = real_decl_rtl; - } - } } /* Indicate whether REGNO is an incoming argument to the current function @@ -6987,11 +6958,16 @@ expand_function_end (filename, line, end_bindings) ? REGNO (decl_rtl) >= FIRST_PSEUDO_REGISTER : DECL_REGISTER (decl_result)) { - rtx real_decl_rtl = current_function_return_rtx; + rtx real_decl_rtl; - /* This should be set in assign_parms. */ - if (! REG_FUNCTION_VALUE_P (real_decl_rtl)) - abort (); +#ifdef FUNCTION_OUTGOING_VALUE + real_decl_rtl = FUNCTION_OUTGOING_VALUE (TREE_TYPE (decl_result), + current_function_decl); +#else + real_decl_rtl = FUNCTION_VALUE (TREE_TYPE (decl_result), + current_function_decl); +#endif + REG_FUNCTION_VALUE_P (real_decl_rtl) = 1; /* If this is a BLKmode structure being returned in registers, then use the mode computed in expand_return. Note that if @@ -7019,6 +6995,11 @@ expand_function_end (filename, line, end_bindings) int_size_in_bytes (TREE_TYPE (decl_result))); else emit_move_insn (real_decl_rtl, decl_rtl); + + /* The delay slot scheduler assumes that current_function_return_rtx + holds the hard register containing the return value, not a + temporary pseudo. */ + current_function_return_rtx = real_decl_rtl; } } |

