Wednesday, 24 December 2008

Christmas Profiling Tip

If you're profiling some code and you get something like this from hp2ps ...

c:/ws/fpfdev/depot/QA/EDG/EDG_priv/ $ hp2ps -c
bin\hp2ps.exe: Disaster! (bucket out of range)

...then the chances are it's because you have a partially truncated .hp file (eg if your program didn't exit cleanly). This is easily fixed, by searching for the last BEGIN_SAMPLE line in the file, and deleting everything from there onwards.