Re: at exit alternative for AIX

2012-09-16 Thread Perry Smith
On Aug 8, 2012, at 3:32 PM, David Edelsohn wrote: On Tue, Aug 7, 2012 at 1:42 PM, Perry Smith pedz...@gmail.com wrote: Thanks. You just provide what I wanted / needed which is a sanity check. I'll open a bug report and that might get me some help. I think I've concocted a plan to get

[wwwdocs] Update links to C++ ABI (was: at exit alternative for AIX)

2012-08-26 Thread Gerald Pfeifer
On Tue, 7 Aug 2012, Ian Lance Taylor wrote: The official link at http://codesourcery.com/cxx-abi/ (note trailing slash) still works. It used to be http://sourcery.mentor.com/public/cxx-abi/ as of lately, and now redirects to http://mentorembedded.github.com/cxx-abi/ . I went ahead and updated

Re: [wwwdocs] Update links to C++ ABI (was: at exit alternative for AIX)

2012-08-26 Thread Ian Lance Taylor
On Sun, Aug 26, 2012 at 3:43 AM, Gerald Pfeifer ger...@pfeifer.com wrote: On Tue, 7 Aug 2012, Ian Lance Taylor wrote: The official link at http://codesourcery.com/cxx-abi/ (note trailing slash) still works. It used to be http://sourcery.mentor.com/public/cxx-abi/ as of lately, and now

Re: [wwwdocs] Update links to C++ ABI (was: at exit alternative for AIX)

2012-08-26 Thread Gabriel Dos Reis
On Sun, Aug 26, 2012 at 11:55 AM, Ian Lance Taylor i...@google.com wrote: On Sun, Aug 26, 2012 at 3:43 AM, Gerald Pfeifer ger...@pfeifer.com wrote: On Tue, 7 Aug 2012, Ian Lance Taylor wrote: The official link at http://codesourcery.com/cxx-abi/ (note trailing slash) still works. It used to

Re: [wwwdocs] Update links to C++ ABI (was: at exit alternative for AIX)

2012-08-26 Thread Ian Lance Taylor
On Sun, Aug 26, 2012 at 3:43 AM, Gerald Pfeifer ger...@pfeifer.com wrote: On Tue, 7 Aug 2012, Ian Lance Taylor wrote: The official link at http://codesourcery.com/cxx-abi/ (note trailing slash) still works. It used to be http://sourcery.mentor.com/public/cxx-abi/ as of lately, and now

Re: [wwwdocs] Update links to C++ ABI (was: at exit alternative for AIX)

2012-08-26 Thread Gabriel Dos Reis
On Sun, Aug 26, 2012 at 11:55 AM, Ian Lance Taylor i...@google.com wrote: On Sun, Aug 26, 2012 at 3:43 AM, Gerald Pfeifer ger...@pfeifer.com wrote: On Tue, 7 Aug 2012, Ian Lance Taylor wrote: The official link at http://codesourcery.com/cxx-abi/ (note trailing slash) still works. It used to

Re: at exit alternative for AIX

2012-08-21 Thread Jonathan Wakely
On 21 August 2012 00:55, Perry Smith wrote: I have added __cxa_atexit and __cxa_finalize in the libstdc++ library instead of the libgcc library because it is only used by g++ and not gcc. That doesn't sound right, not all C++ programs link to libstdc++ and not all C++ programs are compiled

Re: at exit alternative for AIX

2012-08-20 Thread Perry Smith
Hi, I need more help on this project. collect2 is dying when it calls ld for the first time because __dso_handle is not defined. It is being reference from the calls to __cxa_atexit. What I had planned to do was define it in the small .c stub that collect2 creates but that doesn't get

Re: at exit alternative for AIX

2012-08-20 Thread Ian Lance Taylor
On Mon, Aug 20, 2012 at 4:55 PM, Perry Smith pedz...@gmail.com wrote: collect2 is dying when it calls ld for the first time because __dso_handle is not defined. It is being reference from the calls to __cxa_atexit. So, create another stub, and pass it into the first link. Ian

Re: at exit alternative for AIX

2012-08-19 Thread Perry Smith
On Aug 18, 2012, at 7:48 PM, Perry Smith wrote: Hi Gang, I'm having an unforeseen issue. Hopefully I'm just doing something wrong. I'm on gcc 4.5.2. I started with a fresh build tree. I'm passing in --enable-__cxa_atexit: configure \ --with-gmp=${PUBLIC_BASE} \

Re: at exit alternative for AIX

2012-08-19 Thread Ian Lance Taylor
On Sat, Aug 18, 2012 at 5:48 PM, Perry Smith pedz...@gmail.com wrote: I'm on gcc 4.5.2. I started with a fresh build tree. I'm passing in --enable-__cxa_atexit: configure \ --with-gmp=${PUBLIC_BASE} \ --with-mpfr=${PUBLIC_BASE} \ --with-mpc=${PUBLIC_BASE} \

Re: at exit alternative for AIX

2012-08-19 Thread Ian Lance Taylor
On Sun, Aug 19, 2012 at 11:28 AM, Ian Lance Taylor i...@google.com wrote: Look closely at the output from gcc/configure. Does it include the line __cxa_atexit can't be enabled on this target? That will be displayed if the configure script determines that your target does not provide a

Re: at exit alternative for AIX

2012-08-18 Thread Perry Smith
On Aug 8, 2012, at 3:32 PM, David Edelsohn wrote: On Tue, Aug 7, 2012 at 1:42 PM, Perry Smith pedz...@gmail.com wrote: Thanks. You just provide what I wanted / needed which is a sanity check. I'll open a bug report and that might get me some help. I think I've concocted a plan to get

Re: at exit alternative for AIX

2012-08-08 Thread David Edelsohn
On Tue, Aug 7, 2012 at 1:42 PM, Perry Smith pedz...@gmail.com wrote: Thanks. You just provide what I wanted / needed which is a sanity check. I'll open a bug report and that might get me some help. I think I've concocted a plan to get __cxa_atexit to work. I am going to try that first.

Re: at exit alternative for AIX

2012-08-07 Thread Perry Smith
On Aug 5, 2012, at 3:50 PM, Perry Smith wrote: On Aug 5, 2012, at 1:09 PM, David Edelsohn wrote: On Sun, Aug 5, 2012 at 9:56 AM, Perry Smith pedz...@gmail.com wrote: I was planning on exploring when _GLOBAL__FD was called today. I need to figure out when gcc puts the call to the dtor

Re: at exit alternative for AIX

2012-08-07 Thread Ian Lance Taylor
On Tue, Aug 7, 2012 at 5:43 AM, Perry Smith pedz...@gmail.com wrote: Not sure why this thread died. I've been looking at the code trying to gain the courage to try and implement the changes I suggested but was also waiting to hear back from others. Sorry, I'm not sure what you are waiting to

Re: at exit alternative for AIX

2012-08-07 Thread Perry Smith
On Aug 7, 2012, at 10:52 AM, Ian Lance Taylor wrote: On Tue, Aug 7, 2012 at 5:43 AM, Perry Smith pedz...@gmail.com wrote: Not sure why this thread died. I've been looking at the code trying to gain the courage to try and implement the changes I suggested but was also waiting to hear back

Re: at exit alternative for AIX

2012-08-07 Thread Jonathan Wakely
On 07/08/2012, Perry Smith wrote: Is there any documentation about cxa_gaurd and its associated routines? I think I gather what all it is doing, etc but a general description would help. The __cxa_guard stuff is part of the Itanium C++ ABI, see

Re: at exit alternative for AIX

2012-08-07 Thread Ian Lance Taylor
On Tue, Aug 7, 2012 at 1:36 PM, Jonathan Wakely jwakely@gmail.com wrote: The __cxa_guard stuff is part of the Itanium C++ ABI, see http://refspecs.linuxfoundation.org/cxxabi-1.83.html#once-ctor (or a slightly newer version at http://www.swag.uwaterloo.ca/asx/ABI.html) Neither of those is

Re: at exit alternative for AIX

2012-08-05 Thread Perry Smith
On Aug 4, 2012, at 11:56 PM, Ian Lance Taylor wrote: On Sat, Aug 4, 2012 at 2:43 PM, Perry Smith pedz...@gmail.com wrote: I hope I've researched this enough to ask decent questions. I'm running gcc 4.5.2. AIX 6.1 TL07 SP03. The essence of the problem is when a shared library is

Re: at exit alternative for AIX

2012-08-05 Thread Ian Lance Taylor
On Sun, Aug 5, 2012 at 6:56 AM, Perry Smith pedz...@gmail.com wrote: Part of my confusion / concern is why have two methods? Does the spec say that dtors much be called at different times? The use of _GLOBAL_FD in GCC is AIX-specific, and appears to be required to get destructors in shared

Re: at exit alternative for AIX

2012-08-05 Thread David Edelsohn
On Sun, Aug 5, 2012 at 9:56 AM, Perry Smith pedz...@gmail.com wrote: I was planning on exploring when _GLOBAL__FD was called today. I need to figure out when gcc puts the call to the dtor in _GLOBAL__FD path rather than in the atexit path. The net implies that static uses atexit while a

Re: at exit alternative for AIX

2012-08-05 Thread Perry Smith
On Aug 5, 2012, at 1:09 PM, David Edelsohn wrote: On Sun, Aug 5, 2012 at 9:56 AM, Perry Smith pedz...@gmail.com wrote: I was planning on exploring when _GLOBAL__FD was called today. I need to figure out when gcc puts the call to the dtor in _GLOBAL__FD path rather than in the atexit path.

Re: at exit alternative for AIX

2012-08-05 Thread Perry Smith
On Aug 5, 2012, at 3:50 PM, Perry Smith wrote: On Aug 5, 2012, at 1:09 PM, David Edelsohn wrote: On Sun, Aug 5, 2012 at 9:56 AM, Perry Smith pedz...@gmail.com wrote: I was planning on exploring when _GLOBAL__FD was called today. I need to figure out when gcc puts the call to the dtor

at exit alternative for AIX

2012-08-04 Thread Perry Smith
Hi, I hope I've researched this enough to ask decent questions. I'm running gcc 4.5.2. AIX 6.1 TL07 SP03. The essence of the problem is when a shared library is loaded, sometimes atexit is called with a pointer to a destructor. This call (I gather) is produced by gcc itself (or g++). The

Re: at exit alternative for AIX

2012-08-04 Thread Ian Lance Taylor
On Sat, Aug 4, 2012 at 2:43 PM, Perry Smith pedz...@gmail.com wrote: I hope I've researched this enough to ask decent questions. I'm running gcc 4.5.2. AIX 6.1 TL07 SP03. The essence of the problem is when a shared library is loaded, sometimes atexit is called with a pointer to a