It could be the extra position predicate that's causing the problem.  Are
you running under release or debug?  Debug will be _much_ slower.

This is an architectural deficiency of the C++ processor, because it uses
exceptions to restart an XPath if it detects a position predicate.

If you can send me your document privately, zipped up, I'll take a look at
what's happening and see if there isn't maybe something else going on.

Dave



                                                                                       
                
                    "Cornelius, Martin"                                                
                
                    <Martin.Cornelius@softw        To:     
"'[EMAIL PROTECTED]'"                
                    areag.com>                     <[EMAIL PROTECTED]>          
                
                                                   cc:     (bcc: David N 
Bertoni/CAM/Lotus)            
                    07/19/2001 08:59 AM            Subject:     Xalan-C++ 1.1: 
Catastrophic            
                    Please respond to              performance with prededing:: Axis   
                
                    xalan-dev                                                          
                
                                                                                       
                
                                                                                       
                



Hi there, has anybody else noticed that the performance of Xalans-C++ Xpath
evaluation is degrading catastrophically with large documents, if the
preceding:: axis is used ?

I have built an application that uses only the Xpath component of Xalan (
no
XSLT ), to find nodes in an XML Document.

The Sample-Document has about 174000 Element nodes, maximum depth of
nesting
is about 20.

Searching for the 99999.th node in forward direction is quite fast:
(//*)[99999]
takes about 1.2 seconds (on a 700 MHz PentiumIII under WinNT) for the pure
Xpath Evaluation, ( plus 4 seconds for parsing the Document )


In contrast,the question for the same node, formulated as:
(//*)[100000]/preceding::*[1]
takes about 75 seconds, what is 2 ordes of magnitude slower.

BTW, Saxon needs about 5 Seconds for the complete Parsing and evaluation
for
both queries.






Reply via email to