Mail Archives: djgpp/1999/11/04/11:46:42
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.
- Raw text -