This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/47558] 163267 breaks exception traceback in xplor-nih


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47558

--- Comment #56 from Jack Howarth <howarth at nitro dot med.uc.edu> 2011-02-04 15:11:29 UTC ---
The following works as a testcase for PR47558

test_main.c
--------------------------
void main (void)
{
extern int unwindcall(void);
int i;
i=unwindcall();
}
--------------------------

test_call.c
---------------------------
int unwindcall (void)
{
static __thread i; 
  i+i; 
  _Unwind_Resume ((void *)0); 
  return i;
}
----------------------------

./dist/bin/gcc -dynamiclib -o libtestcall.dylib -flat_namespace -undefined
suppress -single_module test_call.c
./dist/bin/gcc -o PR47558.exe test_main.c ./libtestcall.dylib

otool -L PR47558.exe
PR47558.exe:
    libtestcall.dylib (compatibility version 0.0.0, current version 0.0.0)
    /Users/howarth/dist/lib/libgcc_s.1.dylib (compatibility version 1.0.0,
current version 1.0.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version
125.2.1)

./PR47558.exe 
Abort

 gdb ./PR47558.exe 
GNU gdb 6.3.50-20050815 (Apple version gdb-1510) (Wed Sep 22 02:45:02 UTC 2010)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "x86_64-apple-darwin"...Reading symbols for shared
libraries .... done

(gdb) r
Starting program: /Users/howarth/PR47558.exe 
Reading symbols for shared libraries +++. done

Program received signal SIGABRT, Aborted.
0x00007fff87c05616 in __kill ()
(gdb) bt
#0  0x00007fff87c05616 in __kill ()
#1  0x00007fff87ca5cca in abort ()
#2  0x00000001000147a6 in uw_init_context_1 (context=0x7fff5fbfe5d0,
outer_cfa=0x7fff5fbfe800, outer_ra=0x100003f75) at
../../../gcc/libgcc/../gcc/unwind-dw2.c:1265
(gdb)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]