Thanks for the question.
First thing to note is that timings from a single run on
the command line tend to be dominated by warm-up time for the Java VM, so you
can't really extrapolate to an environment in which queries are run from a Java
application where the VM is already up to full speed. For meaningful performance
measurements, you should run from a Java application and run repeatedly for at
least a minute, taking an average time (and perhaps ignoring the first few
runs). If you do need to do performance testing from the command line, there's
an undocumented option "-9" which runs the query 9 times, this gives more
Having said, that, "Analysis time" is basically the time
taken to compile and optimize the query. "Tree building time" is the time taken
to parse a source document, typically the time taken to execute the doc()
function. This is part of the total query execution time shown as "Execution
time" when the source is read using the doc() function, but it is excluded from
query execution time if you build the document from the command line using the
-s option. So what this is showing is that for XMark query Q1 on a source
document of about 100Mb, the query takes 139ms to compile, the source document
takes 7.2 seconds to parse and build in memory, and the query then takes around
340ms to execute.
Incidentally, if you're running XMark, please note that the
queries that do joins run dramatically faster on Saxon-SA. For example, with a
10Mb database, Q9 takes 15602ms under Saxon-B and just 42ms under Saxon-SA. With
a 100Mb database the difference will be even more extreme.
Ladies and gentlemen, how are
I'm a graduate student from Tsinghua
University,China. My name is LiuLe. I want to get some performance infofmation
of Saxon 18.104.22.168J on Linux. When I entered a query command, such as "java -cp
saxon8.jar net.sf.saxon.Query -t x1.xq", I got the timing infofmation
Saxon 22.214.171.124J from Saxonica
Java version 1.5.0_09
Analysis time: 139 milliseconds
Building tree for
file:/home/liule/files/xmark/xmark_1.xml using class
Tree built in 7181 milliseconds
size: 4787932 nodes, 79415403 characters, 381878 attributes
So my question is what the relation is among
"Analysis time: 139 milliseconds","Tree built in 7181 milliseconds" and
"Execution time: 7520 milliseconds". What are the exact meanings of "Analysis
time", "Tree built time" and "Execution time".
Thank you very much.