Well, I spent today finishing off the BGCCache integration, and getting 
blackbox to compile on IRIX with MIPSpro 7.3.1.1m

Our IRIX machine has Purify on it, so I cleaned up the only UMR's i could 
find (UMR = uninitialized memory read).  Here is a report showing that 
blackbox has no memory leaks (however, many library calls do leak, mostly 
in Xlib).  Quite pleasing to say that blackbox had no memory leaks even 
before I started running it through purify.

For those interested, here is the (relatively empty) purify log.

-- 
Bradley T. Hughes - bhughes at trolltech.com
Trolltech AS - Waldemar Thranes gt. 98 N-0175 Oslo, Norway
****  Purify instrumented ./blackbox.pure (pid 97754 at Fri Mar 22 14:59:29 2002)
  * Purify 4.1 IRIX6, Copyright (C) 1992-1997 Rational Software Corp. All rights 
reserved. 
  * For contact information type: "purify -help"
  * For TTY output, use the option "-windows=no"
  * Command-line: ./blackbox.pure -display reticent:1 
  * Options settings: -purify -purify-home=/usr/pure/purify 
  * Purify licensed to Troll Tech AS
  * Purify checking enabled.

****  Purify instrumented ./blackbox.pure (pid 97754)  ****
Current file descriptors in use: 5
FIU: file descriptor 0: <stdin>
FIU: file descriptor 1: <stdout>
FIU: file descriptor 2: <stderr>
FIU: file descriptor 26: <reserved for Purify internal use>
FIU: file descriptor 27: <reserved for Purify internal use>

****  Purify instrumented ./blackbox.pure (pid 97754)  ****
Purify: Searching for all memory leaks...

Memory leaked: 2550 bytes (4.35%); potentially leaked: 0 bytes (0%)

MLK: 690 bytes leaked in 28 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:1002]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]
  * Block of 98 bytes at 0x100f5b10
  * Block of 66 bytes at 0x10195908
  * Block of 56 bytes at 0x100b2e70
  * Block of 30 bytes at 0x100b40f8
  * Block of 25 bytes at 0x101173c0
  * Block of 24 bytes (4 times); last block at 0x10195798
  * Block of 21 bytes (2 times); last block at 0x100e8270
  * Block of 18 bytes (5 times); last block at 0x100f5720
  * Block of 17 bytes (4 times); last block at 0x100ffeb0
  * Block of 16 bytes (3 times); last block at 0x10145b80
  * Block of 15 bytes at 0x100dfac8
  * Block of 14 bytes (4 times); last block at 0x1010da50

MLK: 690 bytes leaked in 28 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:1002]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]
  * Block of 98 bytes at 0x100c6d08
  * Block of 66 bytes at 0x100c7410
  * Block of 56 bytes at 0x100c75e0
  * Block of 30 bytes at 0x100c7190
  * Block of 25 bytes at 0x100c6a80
  * Block of 24 bytes (4 times); last block at 0x100c6fe0
  * Block of 21 bytes (2 times); last block at 0x100c6c28
  * Block of 18 bytes (5 times); last block at 0x100c6f08
  * Block of 17 bytes (4 times); last block at 0x100c76d8
  * Block of 16 bytes (3 times); last block at 0x100c7578
  * Block of 15 bytes at 0x100c6af8
  * Block of 14 bytes (4 times); last block at 0x100c7670

MLK: 224 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        XCreateGC      [CrGC.c:76]
        BGCCache::nextContext(unsigned int) [GCCache.cc:113]
        BGCCache::find(const BColor&,const XFontStruct*,int,int) [GCCache.cc:205]
        BPen::gc(void) const [GCCache.hh:111]
        BlackboxWindow::redrawLabel(void) [Window.cc:2022]
  * Block of 112 bytes (2 times); last block at 0x10119480

MLK: 112 bytes leaked at 0x100f2d90
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        XCreateGC      [CrGC.c:76]
        BGCCache::nextContext(unsigned int) [GCCache.cc:113]
        BGCCache::find(const BColor&,const XFontStruct*,int,int) [GCCache.cc:205]
        BPen::gc(void) const [GCCache.hh:111]
        Basemenu::drawItem(int,int,int,int,int,unsigned int,unsigned int) 
[Basemenu.cc:711]

MLK: 112 bytes leaked at 0x100d93a0
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        XCreateGC      [CrGC.c:76]
        BGCCache::nextContext(unsigned int) [GCCache.cc:113]
        BGCCache::find(const BColor&,const XFontStruct*,int,int) [GCCache.cc:205]
        BPen::gc(void) const [GCCache.hh:111]
        Toolbar::redrawWorkspaceLabel(int) [Toolbar.cc:676]

MLK: 112 bytes leaked at 0x100d9468
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        XCreateGC      [CrGC.c:76]
        BGCCache::nextContext(unsigned int) [GCCache.cc:113]
        BGCCache::find(const BColor&,const XFontStruct*,int,int) [GCCache.cc:205]
        BPen::gc(void) const [GCCache.hh:111]
        Toolbar::redrawPrevWorkspaceButton(int,int) [Toolbar.cc:707]

MLK: 112 bytes leaked at 0x100ea320
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        XCreateGC      [CrGC.c:76]
        BGCCache::nextContext(unsigned int) [GCCache.cc:113]
        BGCCache::find(const BColor&,const XFontStruct*,int,int) [GCCache.cc:205]
        BPen::gc(void) const [GCCache.hh:111]
        BlackboxWindow::redrawIconifyButton(int) [Window.cc:2061]

MLK: 96 bytes leaked in 6 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:988]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]
  * Block of 16 bytes (6 times); last block at 0x1011ba70

MLK: 96 bytes leaked in 6 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:988]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]
  * Block of 16 bytes (6 times); last block at 0x100c7208

MLK: 90 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        operator new(unsigned int) [new.cxx:137]
        __nw__GUi      [memtypes.c:41]
        operator new[](unsigned int) [array_new.cxx:30]
        __nwa__GUi     [memtypes.c:141]
        bstrdup(const char*) [Util.cc:68]
  * Block of 46 bytes at 0x100e81c0
  * Block of 44 bytes at 0x100c5df8

MLK: 40 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        create_conv    [lcDefConv.c:251]
        get_converter  [lcConv.c:72]
        _XrmDefaultInitParseInfo [lcRM.c:112]
        _XrmInitParseInfo [lcWrap.c:401]
        NewDatabase    [Xrm.c:546]
  * Block of 20 bytes (2 times); last block at 0x100c43e8

MLK: 32 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        GrowTable      [Xrm.c:630]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]
  * Block of 16 bytes (2 times); last block at 0x100c7748

MLK: 32 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        GrowTable      [Xrm.c:630]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]
  * Block of 16 bytes (2 times); last block at 0x100e6ee0

MLK: 16 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        create_conv    [lcDefConv.c:247]
        get_converter  [lcConv.c:72]
        _XrmDefaultInitParseInfo [lcRM.c:112]
        _XrmInitParseInfo [lcWrap.c:401]
        NewDatabase    [Xrm.c:546]
  * Block of 8 bytes (2 times); last block at 0x100c4388

MLK: 16 bytes leaked at 0x1010c9c8
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        NewDatabase    [Xrm.c:543]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]

MLK: 16 bytes leaked at 0x100c64b0
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:907]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]

MLK: 16 bytes leaked at 0x100c42c0
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        NewDatabase    [Xrm.c:543]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]

MLK: 16 bytes leaked at 0x100d1c08
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:907]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]

MLK: 8 bytes leaked at 0x101050d0
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        _XrmDefaultInitParseInfo [lcRM.c:107]
        _XrmInitParseInfo [lcWrap.c:401]
        NewDatabase    [Xrm.c:546]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]

MLK: 8 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:988]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::save_rc(void) [blackbox.cc:890]
        Blackbox::shutdown(void) [blackbox.cc:882]
        Rootmenu::itemSelected(int,int) [Rootmenu.cc:92]
  * Block of 4 bytes (2 times); last block at 0x100f8898

MLK: 8 bytes leaked in 2 blocks
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        PutEntry       [Xrm.c:988]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]
        main           [main.cc:157]
        __start        [crt1text.s:176]
  * Block of 4 bytes (2 times); last block at 0x100c6940

MLK: 8 bytes leaked at 0x100c4328
  * This memory was allocated from:
        _malloc        [malloc.c:886]
        _XrmDefaultInitParseInfo [lcRM.c:107]
        _XrmInitParseInfo [lcWrap.c:401]
        NewDatabase    [Xrm.c:546]
        Blackbox::load_rc(void) [blackbox.cc:1110]
        Blackbox::Blackbox(int,char**,char*,char*) [blackbox.cc:160]

Purify Heap Analysis (combining suppressed and unsuppressed blocks)
                         Blocks      Bytes
              Leaked         94       2550
  Potentially Leaked          0          0
              In-Use        261      56129
  ----------------------------------------
     Total Allocated        355      58679

****  Purify instrumented ./blackbox.pure (pid 97754)  ****
  * Program exited with status code 0.
  * 0 access errors, 0 total occurrences.
  * 2550 bytes leaked.
  * 0 bytes potentially leaked.
  * Basic memory usage (including Purify overhead):
     1622016 code
       69668 data/bss
     1265628 heap (peak use)
        4304 stack
  * Shared library memory usage (including Purify overhead):
      425984 rtlib_n32.so (shared code)
       57812 rtlib_n32.so (private data)
      114688 libgen.so.pure.180f8bda9 (shared code)
        4660 libgen.so.pure.180f8bda9 (private data)
      425984 libnsl.so.pure.22a215fe9 (shared code)
       17880 libnsl.so.pure.22a215fe9 (private data)
       16384 libsocket.so.pure.1078c7502 (shared code)
         112 libsocket.so.pure.1078c7502 (private data)
     1556480 libXt.so.pure.3076d5968 (shared code)
       31172 libXt.so.pure.3076d5968 (private data)
     2998272 libX11.so.1.pure.211c23ceb (shared code)
       48768 libX11.so.1.pure.211c23ceb (private data)
      327680 libXext.so.pure.33bcd97aa (shared code)
        1832 libXext.so.pure.33bcd97aa (private data)
       16384 libCsup.so.pure.cd27b774 (shared code)
         112 libCsup.so.pure.cd27b774 (private data)
      819200 libC.so.2.pure.271525402 (shared code)
      170848 libC.so.2.pure.271525402 (private data)
     2932736 libc.so.1.pure.10a14cfa6 (shared code)
       75568 libc.so.1.pure.10a14cfa6 (private data)
      491520 libm.so.pure.19721c975 (shared code)
       98320 libm.so.pure.19721c975 (private data)
  * Memory mapped usage:
       65536 mmap'd at 0x4608000
      524288 mmap'd at 0x4e9c000
       40960 mmap'd at 0x4e8c000
     2891776 mmap'd at 0x4bc8000
        8192 mmap'd at 0x4bc4000
       20480 mmap'd at 0x4bbc000
      253952 mmap'd at 0x4b7c000
      462848 mmap'd at 0x4b08000
        4096 mmap'd at 0x50dc000
      262144 mmap'd at 0x47b4000
     2666496 mmap'd at 0x437c000
      270336 mmap'd at 0x4338000
      270336 mmap'd at 0x42f4000
        4096 mmap'd at 0x50e0000

Reply via email to