Message-ID: <382177B2.CEC4B27C@mpx.com.au> Date: Thu, 04 Nov 1999 23:10:26 +1100 From: infinity girl X-Mailer: Mozilla 4.5 [en] (Win95; I) X-Accept-Language: en MIME-Version: 1.0 To: Hans-Bernhard Broeker CC: djgpp AT delorie DOT com Subject: Re: mcount, and gprof References: <199911041247 DOT NAA12665 AT acp3bf DOT physik DOT rwth-aachen DOT de> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com hi, thanks fr yr reply. i remember about mcount now..i hadn't used the profiler in months, and had forgotten it was used by the profiler itself. i am using version 2.81 of djgpp so i don't think there is anything buggy happening. i was a bit wrong with the hundreds of thousands tho.... i have functions being called millons of times: Each sample counts as 0.055556 seconds. % cumulative self self total time seconds seconds calls ms/call ms/call name 22.97 0.94 0.94 mcount 21.62 1.83 0.89 1148074 0.00 0.00 readBuf 17.57 2.56 0.72 574804 0.00 0.00 bsPut 10.81 3.00 0.44 1 444.44 2049.23 outputFile 9.46 3.39 0.39 1290460 0.00 0.00 dcopy 5.41 3.61 0.22 142388 0.00 0.00 writeBuf 5.41 3.83 0.22 1 222.22 839.66 calcFreqs that is a sample of some of the top ones. as much time is spent in my function readBuf as is spent in mcount profiling helped me alot at first, becuz __dpmi_int was being called the most. a tip from someone showed me that this was caused by excessive I/O, and i wrote buffering routines. i am currently only using the -O2 switch, so i will try the next level of optimisation and see if that helps :) usually i would rather have a smaller executable, considering i am struggling with a 329MB hard drive...inlining will affect executable size i guess? i'm not sure if my functions are small enough to inline anyway. anyway thanks again :) daniel.