Commit 81ef7e24 by Jakub Jelinek Committed by Jakub Jelinek

re PR target/43498 (No unwind info for thunks even with -fasynchronous-unwind-tables)

	PR target/43498
	* config/i386/i386.c (x86_output_mi_thunk): Call final_start_function
	at the beginning and final_end_function at the end.
	* config/s390/s390.c (s390_output_mi_thunk): Likewise.

From-SVN: r157706
parent f1c26cad
2010-03-24 Jakub Jelinek <jakub@redhat.com>
PR target/43498
* config/i386/i386.c (x86_output_mi_thunk): Call final_start_function
at the beginning and final_end_function at the end.
* config/s390/s390.c (s390_output_mi_thunk): Likewise.
2010-03-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> 2010-03-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* configure.ac (i[34567]86-*-*): Handle Solaris 2/x86 TLS support * configure.ac (i[34567]86-*-*): Handle Solaris 2/x86 TLS support
......
...@@ -26191,7 +26191,7 @@ x86_can_output_mi_thunk (const_tree thunk ATTRIBUTE_UNUSED, ...@@ -26191,7 +26191,7 @@ x86_can_output_mi_thunk (const_tree thunk ATTRIBUTE_UNUSED,
*(*this + vcall_offset) should be added to THIS. */ *(*this + vcall_offset) should be added to THIS. */
static void static void
x86_output_mi_thunk (FILE *file ATTRIBUTE_UNUSED, x86_output_mi_thunk (FILE *file,
tree thunk ATTRIBUTE_UNUSED, HOST_WIDE_INT delta, tree thunk ATTRIBUTE_UNUSED, HOST_WIDE_INT delta,
HOST_WIDE_INT vcall_offset, tree function) HOST_WIDE_INT vcall_offset, tree function)
{ {
...@@ -26199,6 +26199,9 @@ x86_output_mi_thunk (FILE *file ATTRIBUTE_UNUSED, ...@@ -26199,6 +26199,9 @@ x86_output_mi_thunk (FILE *file ATTRIBUTE_UNUSED,
rtx this_param = x86_this_parameter (function); rtx this_param = x86_this_parameter (function);
rtx this_reg, tmp; rtx this_reg, tmp;
/* Make sure unwind info is emitted for the thunk if needed. */
final_start_function (emit_barrier (), file, 1);
/* If VCALL_OFFSET, we'll need THIS in a register. Might as well /* If VCALL_OFFSET, we'll need THIS in a register. Might as well
pull it in now and let DELTA benefit. */ pull it in now and let DELTA benefit. */
if (REG_P (this_param)) if (REG_P (this_param))
...@@ -26327,6 +26330,7 @@ x86_output_mi_thunk (FILE *file ATTRIBUTE_UNUSED, ...@@ -26327,6 +26330,7 @@ x86_output_mi_thunk (FILE *file ATTRIBUTE_UNUSED,
output_asm_insn ("jmp\t{*}%1", xops); output_asm_insn ("jmp\t{*}%1", xops);
} }
} }
final_end_function ();
} }
static void static void
......
/* Subroutines used for code generation on IBM S/390 and zSeries /* Subroutines used for code generation on IBM S/390 and zSeries
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
2007, 2008, 2009 Free Software Foundation, Inc. 2007, 2008, 2009, 2010 Free Software Foundation, Inc.
Contributed by Hartmut Penner (hpenner@de.ibm.com) and Contributed by Hartmut Penner (hpenner@de.ibm.com) and
Ulrich Weigand (uweigand@de.ibm.com) and Ulrich Weigand (uweigand@de.ibm.com) and
Andreas Krebbel (Andreas.Krebbel@de.ibm.com). Andreas Krebbel (Andreas.Krebbel@de.ibm.com).
...@@ -9030,6 +9030,9 @@ s390_output_mi_thunk (FILE *file, tree thunk ATTRIBUTE_UNUSED, ...@@ -9030,6 +9030,9 @@ s390_output_mi_thunk (FILE *file, tree thunk ATTRIBUTE_UNUSED,
rtx op[10]; rtx op[10];
int nonlocal = 0; int nonlocal = 0;
/* Make sure unwind info is emitted for the thunk if needed. */
final_start_function (emit_barrier (), file, 1);
/* Operand 0 is the target function. */ /* Operand 0 is the target function. */
op[0] = XEXP (DECL_RTL (function), 0); op[0] = XEXP (DECL_RTL (function), 0);
if (flag_pic && !SYMBOL_REF_LOCAL_P (op[0])) if (flag_pic && !SYMBOL_REF_LOCAL_P (op[0]))
...@@ -9279,6 +9282,7 @@ s390_output_mi_thunk (FILE *file, tree thunk ATTRIBUTE_UNUSED, ...@@ -9279,6 +9282,7 @@ s390_output_mi_thunk (FILE *file, tree thunk ATTRIBUTE_UNUSED,
output_asm_insn (".long\t%3", op); output_asm_insn (".long\t%3", op);
} }
} }
final_end_function ();
} }
static bool static bool
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment