From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1164f8,6009156390b1dd3c X-Google-Attributes: gid1164f8,public X-Google-Thread: fee84,6009156390b1dd3c X-Google-Attributes: gidfee84,public From: Roland Kruse Subject: Re: Purify-like debugger for DEC Alpha Date: 1996/06/14 Message-ID: <31C135BA.2367@efi.sintef.no>#1/1 X-Deja-AN: 160121651 references: cc: rk content-type: text/plain; charset=us-ascii organization: EFI mime-version: 1.0 newsgroups: comp.unix.osf.osf1,comp.sys.dec x-mailer: Mozilla 2.01 (Win95; I) Arun Sharma wrote: > > On Wed, 12 Jun 1996 15:57:48 GMT, William R Pearson wrote: > > Bill> I am trying to track down a memory heap corruption > Bill> problem, and have been very impressed with the Purify > Bill> product. Unfortunately, it does not run on DEC Alpha's > Bill> (only Suns, SGI's, and HP's) > > Bill> Any suggestions on a Purify-like product that identifies > Bill> all memory references outside allocation bounds for the > Bill> Alpha? > > Take a look at ATOM. man atom should tell you more. Tried that, all it told me was "There is not an entry for atom." (we have Digital Unix V3.2). I would be interested in more info on this product. In lack of Purify, we have tried the malloc debuggers Dmalloc and ElectricFence on Alpha. While both these products work, they are far from as effective as Purify. The main problem with both these products is that they abort the program at the *first* heap reference error. Then you have to fix that, recompile, re-link, and run it again... and if you're out of luck the first error occurs in third- party code for which you don't have the source... Here is an informal evaluation of these products, using Purify as reference. Both ElectricFence and Dmalloc are freely available from various sources. Error type/ property Purify ElectricFence Dmalloc --------------------------------------------------------------------- Array bounds write Yes Yes Yes Array bounds read Yes Yes No Free non-heap memory Yes Yes Yes Free memory write Yes Yes Partially Free memory read Yes Yes No Uninitialized mem read Yes No No malloc(0) Yes (?) Optional Optional free(NULL) Yes (?) Yes(?) Optional Check auto variables Yes No No Log file Yes No Yes Backtrace Yes No No Memory overhead Moderate High Moderate CPU overhead Moderate High Variable (Configurable) Disk overhead Large Small Small User interface Superb GUI use debugger use debugger Configurability Excellent Limited Good Instrumenting link-time link-time link-time + optionally compile-time --------------------------------------------------------------------- While this table might give the impression that ElectricFence is the better of these products, this is not entirely the case, because its implementation, using separate memory segments for each malloc'ed block, prohibits its use in programs using malloc/free much, including all X/Motif-based GUI programs. Most of our programs are this category, and I found Dmalloc most useful. Roland Kruse Roland.Kruse@efi.sintef.no