This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.
Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Below are a couple of more unwind-related fixes to ia64-specific code. "make check" passes as before. --david 2003-03-27 David Mosberger <davidm at hpl dot hp dot com> * sysdeps/ia64/dl-machine.h (RTLD_START): Wrap ".save rp, r0" directive into empty .prologue region to ensure that call-chain is terminated even for the first instruction. * sysdeps/ia64/elf/start.S (_start): Use ".save rp, r0" idiom to terminate call-chain right from the get-go. * sysdeps/unix/sysv/linux/ia64/fork.S (fork): Remove unnecessary stop bit between compare & branch. * sysdeps/unix/sysv/linux/ia64/sysdep.S (__syscall_error): Bring register usage in sync with unwind info (ar.pfs is saved in r33, according to unwind info). Index: sysdeps/ia64/dl-machine.h =================================================================== RCS file: /cvs/glibc/libc/sysdeps/ia64/dl-machine.h,v retrieving revision 1.22 diff -u -r1.22 dl-machine.h --- sysdeps/ia64/dl-machine.h 12 Jan 2003 08:54:00 -0000 1.22 +++ sysdeps/ia64/dl-machine.h 29 Mar 2003 06:53:06 -0000 @@ -301,8 +301,10 @@ "_start:\n" \ "0: { .mii\n" \ " .prologue\n" \ -" .save ar.pfs, r32\n" \ " .save rp, r0\n" \ +" .body\n" \ +" .prologue\n" \ +" .save ar.pfs, r32\n" \ " alloc loc0 = ar.pfs, 0, 3, 4, 0\n" \ " .body\n" \ " mov r2 = ip\n" \ @@ -332,8 +334,10 @@ " .proc _dl_start_user#\n" \ "_dl_start_user:\n" \ " .prologue\n" \ -" .save ar.pfs, r32\n" \ " .save rp, r0\n" \ +" .body\n" \ +" .prologue\n" \ +" .save ar.pfs, r32\n" \ " .body\n" \ " { .mii\n" \ " /* Save the pointer to the user entry point fptr in loc2. */\n" \ Index: sysdeps/ia64/elf/start.S =================================================================== RCS file: /cvs/glibc/libc/sysdeps/ia64/elf/start.S,v retrieving revision 1.11 diff -u -r1.11 start.S --- sysdeps/ia64/elf/start.S 9 Dec 2002 20:37:21 -0000 1.11 +++ sysdeps/ia64/elf/start.S 29 Mar 2003 06:53:06 -0000 @@ -40,6 +40,9 @@ .type _start,@function _start: .prologue + .save rp, r0 + .body + .prologue { .mlx alloc r2 = ar.pfs,0,0,7,0 movl r3 = FPSR_DEFAULT @@ -76,8 +79,7 @@ { .mmi ld8 out3 = [out3] /* pointer to `init' function descriptor */ ld8 out4 = [out4] /* pointer to `fini' function descriptor */ - .save rp, r4 - mov r4 = r0 /* terminate unwind chain with a NULL return-pointer */ + nop 0 } .body { .mib Index: sysdeps/unix/sysv/linux/ia64/fork.S =================================================================== RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/ia64/fork.S,v retrieving revision 1.6 diff -u -r1.6 fork.S --- sysdeps/unix/sysv/linux/ia64/fork.S 31 Dec 2002 20:37:30 -0000 1.6 +++ sysdeps/unix/sysv/linux/ia64/fork.S 29 Mar 2003 06:53:07 -0000 @@ -32,7 +32,6 @@ ;; DO_CALL (SYS_ify (clone)) cmp.eq p6,p0=-1,r10 - ;; (p6) br.cond.spnt.few __syscall_error ret PSEUDO_END(__libc_fork) Index: sysdeps/unix/sysv/linux/ia64/sysdep.S =================================================================== RCS file: /cvs/glibc/libc/sysdeps/unix/sysv/linux/ia64/sysdep.S,v retrieving revision 1.5 diff -u -r1.5 sysdep.S --- sysdeps/unix/sysv/linux/ia64/sysdep.S 11 Oct 2002 10:51:24 -0000 1.5 +++ sysdeps/unix/sysv/linux/ia64/sysdep.S 29 Mar 2003 06:53:07 -0000 @@ -1,4 +1,4 @@ -/* Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc. +/* Copyright (C) 1999, 2000, 2001, 2003 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by David Mosberger-Tang <davidm at hpl dot hp dot com>. @@ -23,18 +23,19 @@ ENTRY(__syscall_error) #ifdef _LIBC_REENTRANT .prologue ASM_UNW_PRLG_RP|ASM_UNW_PRLG_PFS, ASM_UNW_PRLG_GRSAVE(0) - alloc r35=ar.pfs, 0, 4, 0, 0 + alloc r33=ar.pfs, 0, 4, 0, 0 mov r32=rp - mov r33=r8 + .body + mov r35=r8 mov r34=r1 ;; - br.call.sptk.many b0 = __errno_location# + br.call.sptk.many b0 = __errno_location .Lret0: /* force new bundle */ - st4 [r8]=r33 + st4 [r8]=r35 mov r1=r34 mov rp=r32 mov r8=-1 - mov ar.pfs=r35 + mov ar.pfs=r33 #else /* _LIBC_REENTRANT */ /* * Note that the gp has to be set properly for this to work.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |