-
Notifications
You must be signed in to change notification settings - Fork 32
Description
Has there been any thoughts on how to improve the performance of SaxonCE? I have a small XML document I am transforming (10kb) and it takes between 100-300ms to transform with SaxonCE, in comparison, the browser does this same transform in less than 10ms.
(Note: With SaxonCE I'm transforming to a string for profiling purposes to remove any effects of the DOM operations which might be slow. Also, I am not including the time to load, and parse the XSLT stylesheet or the XML document, this is purely the time taken for the XSLT engine to produce the output by applying the templates.)
I did some profiling and I see that most of the time is spent searching for the right matching template. In my case, about 80ms is spend in the CollatingFunction.evalContains()
I expect this is because lots of our templates use this match clause:
match="*[contains(@Class, ' topic/p ')]
I'd say our stylesheet has about 100 of these templates. I am looking for some general advice as to how this could be improved so I can start digging deeper into some optimizations.
Thanks!