This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
RE: Breakpoint in object destructor
- From: "Bloch, Jack" <jack dot bloch at siemens dot com>
- To: "'Michael Chastain'" <mec dot gnu at mindspring dot com>, gdb at sources dot redhat dot com
- Cc: "Benitez, Rafael" <rafael dot benitez at siemens dot com>
- Date: Wed, 4 Aug 2004 06:53:22 -0700
- Subject: RE: Breakpoint in object destructor
Yes, We are using gcc 3.2
-----Original Message-----
From: gdb-owner@sources.redhat.com
[mailto:gdb-owner@sources.redhat.com]On Behalf Of Michael Chastain
Sent: Wednesday, August 04, 2004 9:51 AM
To: Bloch, Jack; gdb@sources.redhat.com
Cc: Benitez, Rafael
Subject: Re: Breakpoint in object destructor
"Bloch, Jack" <jack.bloch@siemens.com> wrote:
> We are trying to set a breakpoint in a destructor. this does not seem to
> work. Running GDB 5.1.1 on a SuSE 2.4 Kernel. The breakpoint gets set, but
> it never fires.
>
What compiler are you using to build the program that you are compiling?
If you are using gcc 3.X, this is a known, unfixed problem.
See the PROBLEMS file in a recent release of gdb (like gdb 6.2)
for an explanation. Briefly: gcc 3.X emits two or three object code
functions for each destructor; gdb doesn't understand this;
so gdb puts a breakpoint in just one copy.
Michael C