From e11e9ae3f6b8a724a71613817a2b075347e2da39 Mon Sep 17 00:00:00 2001 From: danglin Date: Mon, 27 Dec 2004 01:08:09 +0000 Subject: [PATCH] PR target/17643 * pa.c (pa_function_ok_for_sibcall): Sibcalls are not ok when generating code for the portable runtime. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@92629 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/ChangeLog | 6 ++++++ gcc/config/pa/pa.c | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4e9c2834539..2869df4370b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2004-12-26 John David Anglin + + PR target/17643 + * pa.c (pa_function_ok_for_sibcall): Sibcalls are not ok when + generating code for the portable runtime. + 2004-12-25 Richard Henderson * expr.c (clear_storage): Validate CONST0_RTX extant. Special case diff --git a/gcc/config/pa/pa.c b/gcc/config/pa/pa.c index 707bb5da4b7..07de1cc8ab7 100644 --- a/gcc/config/pa/pa.c +++ b/gcc/config/pa/pa.c @@ -8091,6 +8091,9 @@ pa_asm_output_mi_thunk (FILE *file, tree thunk_fndecl, HOST_WIDE_INT delta, static bool pa_function_ok_for_sibcall (tree decl, tree exp ATTRIBUTE_UNUSED) { + if (TARGET_PORTABLE_RUNTIME) + return false; + /* Sibcalls are ok for TARGET_ELF32 as along as the linker is used in single subspace mode and the call is not indirect. As far as I know, there is no operating system support for the multiple subspace mode. @@ -8108,9 +8111,8 @@ pa_function_ok_for_sibcall (tree decl, tree exp ATTRIBUTE_UNUSED) if (TARGET_64BIT) return false; - return (decl - && !TARGET_PORTABLE_RUNTIME - && !TREE_PUBLIC (decl)); + /* Sibcalls are only ok within a translation unit. */ + return (decl && !TREE_PUBLIC (decl)); } /* Returns 1 if the 6 operands specified in OPERANDS are suitable for -- 2.11.0