Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!van-bc!rsoft!mindlink!a976 From: a976@mindlink.UUCP (Ron Tarrant) Newsgroups: comp.sys.amiga.programmer Subject: Re: Good Programming stops guru |||| and BNF of C++ Message-ID: <4381@mindlink.UUCP> Date: 8 Jan 91 21:29:27 GMT Organization: MIND LINK! - British Columbia, Canada Lines: 26 > m0154@tnc.UUCP writes: > > * Quick way to test for outstanding files or memory allocation - run > your program several times in succession. Use Avail and note the > amount of free memory after each one. The first time you run your > program, any needed libraries will be loaded into RAM. After that, > you should get the same amount of free ram each time. Beware if the > amount goes down by the same amount each time! > > Wildstar There's another way to do this and you only have to run your program once. When you start up WorkBench with the loadwb command, give it an argument of "-debug". This enables an "invisible" menu to the right of all others on the WB screen. This menu (accessed by holding down the right mouse button and moving the pointer to the right of the last labeled menu) has two items: debug (which sends debug info to the serial port) and flushlibs (which dumps any currently unused libraries from the system. Make note of the amount of free ram listed in the menubar of the WB screen. Then, making sure you don't resize your CLI window, run your program, do whatever with your program, then quit. Select "flushlibs", then recheck the amount of free ram in the menubar. It should be the same as what you noted before running the program. I found this tidbit in an issue of AmigaMail, I think. -Ron