> I don't think threads are inherently incompatible with
> exceptions. Exceptions do not propagate across threads (they aren't
> signals), but they should work well within a given thread.
> Is it a platform specific issue, or perhaps a bug in the compiler?
It seems so, yes. Let's say, probably a bug in the combination: gcc 3.2 on Alpha.
I do not follow potential discussions on the gcc mailing list, so I cannot say
if this is an error in the installation over here, or a bug in gcc, or whatever.
> Exceptions and libpthread seem to co-exist well on all the platforms I
> have access to.
Indeed, all other platforms over here behave correctly.
P.S. The call stack on Alpha at the SIGABORT moment is:
#0 0x3ff805b07d8 in __nxm_thread_kill () from /usr/shlib/libpthread.so
#1 0x3ff805a03c8 in pthread_kill () from /usr/shlib/libpthread.so
#2 0x3ff805a8220 in __tsInit () from /usr/shlib/libpthread.so
#3 0x3ff801125c4 in tis_raise () from /usr/shlib/libc.so
#4 0x3ff801601b4 in raise () from /usr/shlib/libc.so
#5 0x3ff8017758c in abort () from /usr/shlib/libc.so
#6 0x3ffbff65d18 in uw_init_context_1 (context=0x11fffea20, outer_cfa=0x11ffff320, outer_ra=0x3ffbffc320c) at /freeware/gcc/gcc/gcc-3.2/gcc/unwind-dw2.c:1122
#7 0x3ffbff668b4 in _Unwind_RaiseException (exc=0x1400026d0) at /freeware/gcc/gcc/gcc-3.2/gcc/unwind.inc:84
#8 0x3ffbffc320c in __cxa_throw (obj=0x1400026d0, tinfo=0x0, dest=0x3ffc01b1360 <__thdDefaultThread>) at /freeware/gcc/gcc/gcc-3.2/libstdc++-v3/libsupc++/eh_throw.cc:72
#9 0x120001e08 in main () at test_exception.cxx:12