This is the mail archive of the
mailing list for the GDB project.
Re: Python API: Getting symbol by address
- From: Simon Marchi <simon dot marchi at polymtl dot ca>
- To: Roman Popov <ripopov at gmail dot com>
- Cc: gdb at sourceware dot org
- Date: Thu, 21 Dec 2017 17:24:04 -0500
- Subject: Re: Python API: Getting symbol by address
- Authentication-results: sourceware.org; auth=none
- References: <CAATAM3Ep+Wr-UhM6OKTSmhxwVM3r7vWfHpfSRW=ruc=GsuZ5ng@mail.gmail.com>
On 2017-12-21 13:20, Roman Popov wrote:
I have collection in C++ that stores pointers to functions and methods.
want to pretty-print pointed method and functions names.
It is possible using GDB shell, for example:
(gdb) info symbol 0x405ece
top::test_thread() in section .text of test_procs
However I found no way to do the same using Python API. Why such
P/S Same question on stackoverflow :
As most things in the Python API (and GDB in general), it's likely
because no one took the time to do it. I don't see any technical reason
not to have it. If you take a shot at writing a patch for this, feel
free to ask if you are blocked.