performance issues

Bill Binko bill at BINKO.NET
Tue Oct 18 14:23:01 EDT 2005


> 
> Normally when I run into this sort of problem, I would
> build MapServer in debug mode, and run it in gdb.
> Then hit "cntl-c" a few times during the run and get
> a traceback to see what is going on.  This crude sampling
> technique can often identify especially major performance
> bottlenecks.
> 
> If the statistics on msDrawMap() are accurate then the
> bulk of the delay must be somewhere else.  Perhaps the
> compression of the PNG (though it does not seem
> especially large) or some sort of preprocessing (getting
> projections during .map processing?)
> 

If shp2img is causing the same issue, you can use qprof to determine the 
location of the performance problem.  I tried to get it to work on 
mapserv, but there is some dynamic loading (of gd) that causes it to fail.

QProf (from HP - http://www.hpl.hp.com/research/linux/qprof/ ) is an 
outstanding tool for this.  I was considering posting a note to the board 
about it, but was hung up on getting mapserv to work w/it.

Basically, you install it (very simple build etc.) and it has a shared 
library that is loaded through LD_PRELOAD (which I didn't even know 
about).  That library samples your app and give a basic profile after each 
command is executed.  If your apps/libs are built with debugging (-g) it 
helps, but it is not necessary for basic performance.  There is no need to 
build w/ profiling (-p or -pg) and you can run it on apps you didn't build 
at all!

I'd be happy to help you getit setup and running.

Bill

bill.binko at mapshine.com



More information about the mapserver-dev mailing list