This is the mail archive of the 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]

Re: Exception handling in GCC 3.0.1 on AIX

$ g++
$ dump -H a.out
                        ***Import File Strings***
INDEX  PATH                          BASE                MEMBER              
0      ...LIBPATH...
1                                    libc.a              shr.o               
2                                    libstdc++.a      
3                                    libgcc_s.a          shr.o       

$ ./a.out
Throwing exception...
Exception '268437520' catched

	Something still is wrong with GCC's native exception handling
interaction with shared libraries on AIX.  I suspect that somewhere the
shared library is using some data which it expects to be private to the
process, but currently is ending up shared.  When the process tries to
write into the shared segment, the application is terminated.

	If the archive file mode is set to disallow read-other, then the
shared library is placed in the AIX process private segment instead of the
shared text segment and throwing exceptions through shared libraries seems
to work (as above).  In other words,

chmod a+x,o-r libstdc++.a libgcc_s.a

	Exceptions do not work reliably when the GCC -static link option
is used.


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