Hello, That's interesting. If I have enough time I'll check what are likely culprits with modified version of the cases and possibly fix them.
Atsushi Eno Bradford Stephens wrote: > Hello all, > > It seems that XPath selection is several orders of magnitude slower in > Mono 2.0 on Ubuntu than on C# on Windows XP. > > The example below is pretty straightforward, and doesn't seem like > it's much slower, but we do this millions of times a day. In some > cases, I've seen parsing a document go from 10 ms on Windows to over > 2000 ms on Mono 2.0/Linux. > > I've made a Mono Project to let you test it yourselves: > http://www.giborama.com/TestSlowXML.tar > > I've advocated the switch of our company's platform from Windows to > Linux, but XML/XPath is an essential part of the business, and with it > being so slow, we're dead in the water. > > I would greatly appreciate any help you may have :) > > ~~~~ > > Windows XP / C# 2005: > > Xpath: //head/title took 2 > Xpath: //[EMAIL PROTECTED] 'content']/div[starts-with (@id, 'p')] took 0 > Xpath: .//h2/a took 0 > Xpath: .//[EMAIL PROTECTED] 'byline']/a[position()=1] took 0 > Xpath: .//[EMAIL PROTECTED] 'byline'] took 1 > Xpath: .//h2 took 0 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')] took 0 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')]//img took 0 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')]//a took 0 > Xpath: //[EMAIL PROTECTED] 'paging']/[EMAIL PROTECTED] 'alignright > arrowforward'] took 0 > > > Ubuntu / Mono 2.0: > > Xpath: //head/title took 24 > Xpath: //[EMAIL PROTECTED] 'content']/div[starts-with (@id, 'p')] took 8 > Xpath: .//h2/a took 1 > Xpath: .//[EMAIL PROTECTED] 'byline']/a[position()=1] took 5 > Xpath: .//[EMAIL PROTECTED] 'byline'] took 3 > Xpath: .//h2 took 1 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')] took 5 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')]//img took 5 > Xpath: .//[EMAIL PROTECTED] 'post']/div[starts-with (@id, 'pc')]//a took 5 > Xpath: //[EMAIL PROTECTED] 'paging']/[EMAIL PROTECTED] 'alignright > arrowforward'] took 8 > > Cheers, > Bradford > _______________________________________________ > Mono-list maillist - [email protected] > http://lists.ximian.com/mailman/listinfo/mono-list > _______________________________________________ Mono-list maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-list
