1
0
Fork 0
mirror of https://github.com/tobast/libunwind-eh_elf.git synced 2024-06-26 03:11:44 +02:00

(a): When compiling with GCC on ia64, use "asm" statement to get the address of the

label.  gcc-3.x otherwise notices that the label isn't used for control-flow
	and feels free to move it around (usually to the beginning of the basic-block),
	with very bad consequences.

(Logical change 1.70)
This commit is contained in:
mostang.com!davidm 2003-03-28 07:43:22 +00:00
parent 453ec65cf0
commit 757746aefb

View file

@ -95,15 +95,23 @@ a (void)
long stack;
#ifdef __GNUC__
void *label;
if (verbose)
printf ("a: sp=%p bsp=%p\n", &stack, __builtin_ia64_bsp ());
b (&&handler);
#ifdef UNW_TARGET_IA64
asm ("movl %0=Label" : "=r"(label));
#else
label = &&handler;
#endif
b (label);
panic ("FAILURE: unexpected return from func()!\n");
#if UNW_TARGET_IA64
asm volatile ("1:"); /* force a new bundle */
asm volatile ("Label:"); /* force a new bundle */
#else
handler:
#endif
handler:
if (verbose)
{
printf ("exception handler: here we go (sp=%p, bsp=%p)...\n",