This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: Issue with Latest GDB on AIX with GCC-6.12
- From: David Edelsohn <dje dot gcc at gmail dot com>
- To: Pedro Alves <palves at redhat dot com>, Nitish Kumar Mishra <mishra dot nitish dot 88 at gmail dot com>
- Cc: "gdb at sourceware dot org" <gdb at sourceware dot org>, Yao Qi <qiyaoltc at gmail dot com>
- Date: Sat, 28 Jan 2017 18:56:12 -0500
- Subject: Re: Issue with Latest GDB on AIX with GCC-6.12
- Authentication-results: sourceware.org; auth=none
>>>>> Pedro Alves writes:
> Sounds like a manifestation of:
>
> Bug 60939 - AIX: exceptions not caught when calling function via pointer
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60939
>
> since ui->input_handler is a function pointer here:
>
> static void
> gdb_rl_callback_handler (char *rl) noexcept
> {
> struct gdb_exception gdb_rl_expt = exception_none;
> struct ui *ui = current_ui;
>
> TRY
> {
> ui->input_handler (rl);
> }
> CATCH (ex, RETURN_MASK_ALL)
> {
> gdb_rl_expt = ex;
> }
> END_CATCH
If the problem is throwing an exception through a function called via
pointer, then the solution should be to follow the suggestion in
comment #8 and add an appropriate incantation of
-Wl,-bkeepfile:
to the link step for GDB, something like
gdb/config/powerpc/aix.mh
MH_LDFLAGS = -Wl,-bkeepfile:event-top.o
Thanks, David