longjmp question

thomson at ca.ibm.com thomson at ca.ibm.com
Thu Sep 9 15:08:39 UTC 1999



>Does the ABI (either C or C++) really need to specify whether longjmp()
>destructs auto C++ objects or not?  In the IBM implementations that do
>this, is there any extra information passed from compiled code to
>setjmp() or longjmp() to support this?

No,  you're right.   In each case longjmp invokes a common
"Unwind" service, which generates a notification that is seen by
C++ exception handlers, and Java finally blocks, and
PL/I FINISH ON-units, and user-written handlers in languages
like C that don't have exceptions built-in.
The only ABI implication is to specify what unwind
notification looks like, and the IA64 C ABI already does this.

So, although reaching a consensus here would improve
code portability,  it isn't essential that we agree.

Brian Thomson
VisualAge C/C++ Chief Architect






More information about the cxx-abi-dev mailing list