This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [downstream patch FYI] workaround stale frame_info * (PR 13866)
- From: Tom Tromey <tromey at redhat dot com>
- To: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Fri, 18 May 2012 11:44:17 -0600
- Subject: Re: [downstream patch FYI] workaround stale frame_info * (PR 13866)
- References: <20120404191416.GA29603@host2.jankratochvil.net>
>>>>> "Jan" == Jan Kratochvil <jan.kratochvil@redhat.com> writes:
Jan> With proper C++ sanity check of stale live frame_info references
Jan> the testcase would be simple without the "frame_garbage_collection"
Jan> reproducer below. It is also reproducible just with valgrind but
Jan> regularly running the whole testsuite under valgrind I did not find
Jan> feasible.
I was thinking about this problem recently.
One idea would be to only let unwinders access struct frame_info, and
have all other code use struct frame_id, perhaps with some simple cache
so that repeated calls for a given frame_id will not cause too much
work.
This would make it much harder to cache information when not allowed.
On the minus side, there are 1300 uses of struct frame_info to audit.
Tom