This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH 3/3 v4] Demangler crash handler
- From: Florian Weimer <fw at deneb dot enyo dot de>
- To: Gary Benson <gbenson at redhat dot com>
- Cc: gdb-patches at sourceware dot org, Andrew Burgess <aburgess at broadcom dot com>, Doug Evans <xdje42 at gmail dot com>, Eli Zaretskii <eliz at gnu dot org>, Mark Kettenis <mark dot kettenis at xs4all dot nl>, Pedro Alves <palves at redhat dot com>, Tom Tromey <tromey at redhat dot com>
- Date: Fri, 06 Jun 2014 21:42:01 +0200
- Subject: Re: [PATCH 3/3 v4] Demangler crash handler
- Authentication-results: sourceware.org; auth=none
- References: <20140605130140 dot GA20572 at blade dot nx> <20140605130358 dot GD20572 at blade dot nx> <87a99pewec dot fsf at mid dot deneb dot enyo dot de> <20140606192741 dot GA6811 at blade dot nx>
* Gary Benson:
> Florian Weimer wrote:
>> * Gary Benson:
>> > + sigaction (SIGSEGV, &sa, &old_sa);
>> > + crash_signal = SIGSETJMP (gdb_demangle_jmp_buf);
>> > + sigaction (SIGSEGV, &old_sa, NULL);
>>
>> That's quite a bit of additional work for each demangler invocation.
>> Is this visible with things like tab completion?
>
> I tested this a while back: it's not noticable.
>
> FWIW I did time gdb -nx -batch \
> /usr/lib64/libreoffice/program/soffice.bin \
> -ex "start" -ex "complete b" > /dev/null
>
> That invokes the demangler some 3,100,000 times. I don't remember
> the exact times but they were of the order of 50s in both cases.
Good to know, thanks.