[Xapian-discuss] Debug build
Olly Betts
olly at survex.com
Fri Mar 19 01:33:06 GMT 2010
On Wed, Mar 17, 2010 at 11:06:17AM +0100, double wrote:
> Thank you very much for your answer. In order to track down
> the issue I forced a core dump on `atexit()`.
>
> Xapian is 1.1.4, the database is flint. Here the dmalloc-report:
>
> --> 13904 times:
> 0xb778cad4 <_ZNSs4_Rep9_S_createEjjRKSaIcE+100>: 0xc7047089
>[...]
As I said, I'm not familiar with dmalloc. You'll need to explain what this
output means...
> List<struct Result> fts_functionname( ... )
> {
>[...]
If there's really a leak here, just posting snippets of code isn't much help.
In order to fix this, I really need to be able to reproduce it. So please
supply a complete self-contained example, with any necessary instructions on
how to build and run it.
It's probably best to open a ticket on http://trac.xapian.org/ for it.
>> If you use GCC, configure compiles with "-g -O2" by default, so you have
>> debug symbols by default.
>
> Maybe the debug symbols are cut off during linking? GDB is
> not able to determine the code-lines.
The GNU toolchain preserves debug symbols when linking by default, and I can
certainly see line numbers in gdb with a default-built xapian-core.
I have found C++ debugging works better in newer GCC and GDB versions, and
-O0 is needed to allow all variable values to be read.
Cheers,
Olly
More information about the Xapian-discuss
mailing list