[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: I need to learn more about optimizing my code
> I need to learn more about optimizing my code. Is there a > website or book > that has some depth on this? What kind of xpath statements are more > processor intensive than others? What XSLT processors are > the fastest? > How much does the size of the XML file being read in factors > into the time > it takes to process the translation? The two biggest factors are the size of the source XML file and the number of times you visit each node. The difficult bit is that the processor may optimize your expressions to reduce the number of node visits, for example if you write preceding-sibling::*[1] then it will probably only visit the first preceding sibling, rather than visiting them all and discarding all but the first. Of course different processors have difference optimizations, which means that the performance of something like <xsl:if test="count(//item)=0"> may vary dramatically from one processor to another. But the usual discipline applies: look for the most deeply nested loops, remembering that loops can either be explicit (apply-templates or for-each), or implicit in path expressions (a/b/c, or //a). Mike Kay XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|