* Memory Leaks @ 1999-11-19 5:09 Fred Wan 1999-11-19 13:02 ` Erik de Castro Lopo 1999-11-30 23:28 ` Fred Wan 0 siblings, 2 replies; 10+ messages in thread From: Fred Wan @ 1999-11-19 5:09 UTC (permalink / raw) To: help-gcc Hi, Does anyone know if there are possibilities of tracing memory leaks with gdb (xxxgdb)? The only thing I now have at my disposal is Visual C++, and its routines for tracing those kinds of errors are insufficient and inaccurate (but what can you expect from microsoft?). I was used to the commercial C++ compiler package from IBM on a RISC\6000 AIX machine, that includes a heap debugger, an excellent program. I now have Solaris 7 (on intel) with just g++ and gdb and I haven't found any specialized ways of tracking memory leaks. Thanks, Fred Wan, a.wan@cable.a2000.nl ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-11-19 5:09 Memory Leaks Fred Wan @ 1999-11-19 13:02 ` Erik de Castro Lopo 1999-11-30 23:28 ` Erik de Castro Lopo 1999-11-30 23:28 ` Fred Wan 1 sibling, 1 reply; 10+ messages in thread From: Erik de Castro Lopo @ 1999-11-19 13:02 UTC (permalink / raw) To: help-gcc Fred Wan wrote: > > Hi, > > Does anyone know if there are possibilities of tracing memory leaks with > > gdb (xxxgdb)? The only thing I now have at my disposal is Visual C++, > and > its routines for tracing those kinds of errors are insufficient and > inaccurate (but what can you expect from microsoft?). I was used to the > commercial C++ compiler package from IBM on a RISC\6000 AIX machine, > that includes a heap debugger, an excellent program. I now have Solaris > 7 (on intel) with just g++ and gdb and I haven't found any specialized > ways of tracking memory leaks. Have a look at this page: http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html Erik -- +-------------------------------------------------+ Erik de Castro Lopo erikd@zip.com.au +-------------------------------------------------+ Spook bait: heroin Albright terrify extradite packages uranium airport terminal Yeltsin code kill blast president train station Clinton opium nitro money sneak hash keep secret DEA smuggle FBI get caught execute LSD assassinate NSA terrorize bombed encrypt plutonium ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-11-19 13:02 ` Erik de Castro Lopo @ 1999-11-30 23:28 ` Erik de Castro Lopo 0 siblings, 0 replies; 10+ messages in thread From: Erik de Castro Lopo @ 1999-11-30 23:28 UTC (permalink / raw) To: help-gcc Fred Wan wrote: > > Hi, > > Does anyone know if there are possibilities of tracing memory leaks with > > gdb (xxxgdb)? The only thing I now have at my disposal is Visual C++, > and > its routines for tracing those kinds of errors are insufficient and > inaccurate (but what can you expect from microsoft?). I was used to the > commercial C++ compiler package from IBM on a RISC\6000 AIX machine, > that includes a heap debugger, an excellent program. I now have Solaris > 7 (on intel) with just g++ and gdb and I haven't found any specialized > ways of tracking memory leaks. Have a look at this page: http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html Erik -- +-------------------------------------------------+ Erik de Castro Lopo erikd@zip.com.au +-------------------------------------------------+ Spook bait: heroin Albright terrify extradite packages uranium airport terminal Yeltsin code kill blast president train station Clinton opium nitro money sneak hash keep secret DEA smuggle FBI get caught execute LSD assassinate NSA terrorize bombed encrypt plutonium ^ permalink raw reply [flat|nested] 10+ messages in thread
* Memory Leaks 1999-11-19 5:09 Memory Leaks Fred Wan 1999-11-19 13:02 ` Erik de Castro Lopo @ 1999-11-30 23:28 ` Fred Wan 1 sibling, 0 replies; 10+ messages in thread From: Fred Wan @ 1999-11-30 23:28 UTC (permalink / raw) To: help-gcc Hi, Does anyone know if there are possibilities of tracing memory leaks with gdb (xxxgdb)? The only thing I now have at my disposal is Visual C++, and its routines for tracing those kinds of errors are insufficient and inaccurate (but what can you expect from microsoft?). I was used to the commercial C++ compiler package from IBM on a RISC\6000 AIX machine, that includes a heap debugger, an excellent program. I now have Solaris 7 (on intel) with just g++ and gdb and I haven't found any specialized ways of tracking memory leaks. Thanks, Fred Wan, a.wan@cable.a2000.nl ^ permalink raw reply [flat|nested] 10+ messages in thread
[parent not found: <383536D0.C1DA51E8@cable.A2000.nl>]
[parent not found: <rmcc18.vu6.ln@127.0.0.1>]
* Re: Memory Leaks [not found] ` <rmcc18.vu6.ln@127.0.0.1> @ 1999-11-26 9:30 ` Philip Brown 1999-11-30 23:28 ` Philip Brown 1999-12-02 6:38 ` Paul Scott 1999-11-28 21:07 ` Greg Newby 1 sibling, 2 replies; 10+ messages in thread From: Philip Brown @ 1999-11-26 9:30 UTC (permalink / raw) To: help-gcc On Mon, 22 Nov 1999 22:31:07 +0200, jhm@cistron.nl wrote: >Fred Wan <a.wan@cable.A2000.nl> wrote: >>Does anyone know if there are possibilities of tracing memory leaks with >>gdb (xxgdb)? > >There are numerous tools that can be used with gcc + gdb; see > http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html . There's >even a gcc modified for leak tracking called "Checker" (I think it has a >homepage on www.gnu.org), but I don't know how mature it is. fairly UNmature. For example, you can't even use it on X executables. -- [Trim the no-bots from my address to reply to me by email!] [ Do NOT email-CC me on posts. Pick one or the other.] http://thomas.loc.gov/cgi-bin/bdquery/z?d105:SN01618:@@@D The word of the day is mispergitude ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-11-26 9:30 ` Philip Brown @ 1999-11-30 23:28 ` Philip Brown 1999-12-02 6:38 ` Paul Scott 1 sibling, 0 replies; 10+ messages in thread From: Philip Brown @ 1999-11-30 23:28 UTC (permalink / raw) To: help-gcc On Mon, 22 Nov 1999 22:31:07 +0200, jhm@cistron.nl wrote: >Fred Wan <a.wan@cable.A2000.nl> wrote: >>Does anyone know if there are possibilities of tracing memory leaks with >>gdb (xxgdb)? > >There are numerous tools that can be used with gcc + gdb; see > http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html . There's >even a gcc modified for leak tracking called "Checker" (I think it has a >homepage on www.gnu.org), but I don't know how mature it is. fairly UNmature. For example, you can't even use it on X executables. -- [Trim the no-bots from my address to reply to me by email!] [ Do NOT email-CC me on posts. Pick one or the other.] http://thomas.loc.gov/cgi-bin/bdquery/z?d105:SN01618:@@@D The word of the day is mispergitude ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-11-26 9:30 ` Philip Brown 1999-11-30 23:28 ` Philip Brown @ 1999-12-02 6:38 ` Paul Scott 1999-12-31 22:24 ` Paul Scott 1 sibling, 1 reply; 10+ messages in thread From: Paul Scott @ 1999-12-02 6:38 UTC (permalink / raw) To: help-gcc Philip Brown wrote: >On Mon, 22 Nov 1999 22:31:07 +0200, jhm@cistron.nl wrote: >>Fred Wan <a.wan@cable.A2000.nl> wrote: >>>Does anyone know if there are possibilities of tracing memory leaks with >>>gdb (xxgdb)? >> >>There are numerous tools that can be used with gcc + gdb; see >> http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html . There's >>even a gcc modified for leak tracking called "Checker" (I think it has a >>homepage on www.gnu.org), but I don't know how mature it is. > >fairly UNmature. >For example, you can't even use it on X executables. > You can also use insure++ (a commercial package). Quite pricey for Sun's and the like, but I believe a free 'lite' version is available when you buy the official RedHat Linux CD set (it's on the Applications CD). -- Paul Scott ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-12-02 6:38 ` Paul Scott @ 1999-12-31 22:24 ` Paul Scott 0 siblings, 0 replies; 10+ messages in thread From: Paul Scott @ 1999-12-31 22:24 UTC (permalink / raw) To: help-gcc Philip Brown wrote: >On Mon, 22 Nov 1999 22:31:07 +0200, jhm@cistron.nl wrote: >>Fred Wan <a.wan@cable.A2000.nl> wrote: >>>Does anyone know if there are possibilities of tracing memory leaks with >>>gdb (xxgdb)? >> >>There are numerous tools that can be used with gcc + gdb; see >> http://www.cs.colorado.edu/homes/zorn/public_html/MallocDebug.html . There's >>even a gcc modified for leak tracking called "Checker" (I think it has a >>homepage on www.gnu.org), but I don't know how mature it is. > >fairly UNmature. >For example, you can't even use it on X executables. > You can also use insure++ (a commercial package). Quite pricey for Sun's and the like, but I believe a free 'lite' version is available when you buy the official RedHat Linux CD set (it's on the Applications CD). -- Paul Scott ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks [not found] ` <rmcc18.vu6.ln@127.0.0.1> 1999-11-26 9:30 ` Philip Brown @ 1999-11-28 21:07 ` Greg Newby 1999-11-30 23:28 ` Greg Newby 1 sibling, 1 reply; 10+ messages in thread From: Greg Newby @ 1999-11-28 21:07 UTC (permalink / raw) To: help-gcc There's a great commercial tool called Purify, made by Rational (www.rational.com). It's quite pricey ($2400 license), but you can download a free demo. It searches for all memory leaks, potential memory leaks, etc. and tells you where in your code they happen. Very handy... I wish I could afford it (we might get an educational version here at UNC soon). Meanwhile, I periodically download the demo version when I'm having trouble that debuggers can't find. This doesn't answer your question, but it's a good tool to know about I think. It interoperates fine with gdb (that's how I use it). I have not had much luck looking for memory leaks with gdb - although you can spot a variable that points to unassigned memory easily enough (e.g., if *p == NULL [0x0]), it doesn't do this automatically. Furthermore, it doesn't enforce any kind of coding practice, like making sure stuff you 'new' or 'malloc' is later free'd. -- Greg In gnu.g++ J.H.M. Dassen (Ray) <jhm@cistron.nl> wrote: > Fred Wan <a.wan@cable.A2000.nl> wrote: >>Does anyone know if there are possibilities of tracing memory leaks with >>gdb (xxgdb)? // Gregory B. Newby, Assistant Professor in the School of Information // and Library Science, University of North Carolina at Chapel Hill // CB# 3360 Manning Hall, Chapel Hill, NC, 27599-3360 E: gbnewby@ils.unc.edu // V: 919-962-8064 F: 919-962-8071 W: http://www.ils.unc.edu/~gbnewby/ ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Memory Leaks 1999-11-28 21:07 ` Greg Newby @ 1999-11-30 23:28 ` Greg Newby 0 siblings, 0 replies; 10+ messages in thread From: Greg Newby @ 1999-11-30 23:28 UTC (permalink / raw) To: help-gcc There's a great commercial tool called Purify, made by Rational (www.rational.com). It's quite pricey ($2400 license), but you can download a free demo. It searches for all memory leaks, potential memory leaks, etc. and tells you where in your code they happen. Very handy... I wish I could afford it (we might get an educational version here at UNC soon). Meanwhile, I periodically download the demo version when I'm having trouble that debuggers can't find. This doesn't answer your question, but it's a good tool to know about I think. It interoperates fine with gdb (that's how I use it). I have not had much luck looking for memory leaks with gdb - although you can spot a variable that points to unassigned memory easily enough (e.g., if *p == NULL [0x0]), it doesn't do this automatically. Furthermore, it doesn't enforce any kind of coding practice, like making sure stuff you 'new' or 'malloc' is later free'd. -- Greg In gnu.g++ J.H.M. Dassen (Ray) <jhm@cistron.nl> wrote: > Fred Wan <a.wan@cable.A2000.nl> wrote: >>Does anyone know if there are possibilities of tracing memory leaks with >>gdb (xxgdb)? // Gregory B. Newby, Assistant Professor in the School of Information // and Library Science, University of North Carolina at Chapel Hill // CB# 3360 Manning Hall, Chapel Hill, NC, 27599-3360 E: gbnewby@ils.unc.edu // V: 919-962-8064 F: 919-962-8071 W: http://www.ils.unc.edu/~gbnewby/ ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~1999-12-31 22:24 UTC | newest] Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 1999-11-19 5:09 Memory Leaks Fred Wan 1999-11-19 13:02 ` Erik de Castro Lopo 1999-11-30 23:28 ` Erik de Castro Lopo 1999-11-30 23:28 ` Fred Wan [not found] <383536D0.C1DA51E8@cable.A2000.nl> [not found] ` <rmcc18.vu6.ln@127.0.0.1> 1999-11-26 9:30 ` Philip Brown 1999-11-30 23:28 ` Philip Brown 1999-12-02 6:38 ` Paul Scott 1999-12-31 22:24 ` Paul Scott 1999-11-28 21:07 ` Greg Newby 1999-11-30 23:28 ` Greg Newby
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).