
I put the simple version at http://hpaste.org/fastcgi/hpaste.fcgi/view?id=26329#a26329
This one displays much better performance with DList + Writer.Strict than List + StrictWriter so I guess it's not too surprising. However, *something* is still generating a lot of lag
Some lag is to be expected: logging is about creating and recording data for later use. You'd need to annotate your code to measure which parts of lag are not attributable to the log (for instance, your "m" is passed around a lot before it gets used). Then you can use "-hblag -hc -L40" to get lag attributed to cost centers. Btw, you probably want to be more strict about things like that sum in the simple version ("return $! (1+x1+..)"), even a stricter base case ("return $! 1") helps a little, suggesting that you might want to think about the strictness of your logging tools before you put that in production. Hth, Claus