1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187
|
<HTML>
<BODY>
<H1>
REXML Comparisons
</H1>
<H2>
Timing Comparison
</H2>
<P>
This page contains information comparing REXML to other XML parsing
technologies. Included are timing comparisons. Each benchmark was
run for 5 seconds, which probably isn't enough to flatten out startup
bumps and so on, but EXML in particular barfed at a 10 second benchmark
when it ran out of memory.
</P>
<P>
The numbers under the column headers are the versions of the library being used. The version under the EXML column is the version of Java that the test was run under; I'm not aware of a way to get the EXML library version. The version of Ruby is ruby 1.6.4 (2001-06-04) [i586-linux-gnu]
.
</P>
<P>
The test for hand-parsing and XPath are looking for the same elements in a large document (tutorial.xml). Therefore, if the XPath value is half of the hand-parsing value, then on average, XPath is half as fast (but much easier!) as hand parsing.
</P>
<P>
These values are in calls-per-second; higher is better. The numbers in parenthesis are multiples of the REXML score; more than one is faster than REXML, less than one is slower. N/A means 'Not Applicable', meaning the parser doesn't support that function. The scores are color coded; Java scores are not included in this, since it wouldn't be meaningful. In these tests, Java is (nearly) always faster than Ruby. The color coding is as follows:
</P>
<TABLE BORDER='0'>
<TR>
<TD BGCOLOR='#FFFFFF'>
slowest
</TD>
<TD BGCOLOR='#BBFFBB'>
middle
</TD>
<TD BGCOLOR='#99FF99'>
fastest
</TD>
<TD BGCOLOR='#FFAAAA'>
not available
</TD>
</TR>
</TABLE>
<TABLE BORDER='1' WIDTH='100%'>
<TR>
<TH HALIGN='CENTER'>
function
</TH>
<TH HALIGN='CENTER'>
REXML
<BR/>
1.2.3
</TH>
<TH HALIGN='CENTER'>
NQXML
<BR/>
1.1.3
</TH>
<TH HALIGN='CENTER'>
XMLParser
</TH>
<TH HALIGN='CENTER'>
EXML (JIT)
<BR/>
N/A
</TH>
<TH HALIGN='CENTER'>
EXML (No JIT)
<BR/>
N/A
</TH>
</TR>
<TR>
<TD>
Parsing small document
</TD>
<TD BGCOLOR='#BBFFBB'>
97.0
</TD>
<TD BGCOLOR='#FFFFFF'>
77.6 (0.80)
</TD>
<TD BGCOLOR='#99FF99'>
213.2 (2.20)
</TD>
</TR>
<TR>
<TD>
Creating and adding new Element
</TD>
<TD BGCOLOR='#FFFFFF'>
4104.0
</TD>
<TD BGCOLOR='#99FF99'>
8231.2 (2.01)
</TD>
<TD BGCOLOR='#BBFFBB'>
6465.2 (1.58)
</TD>
</TR>
<TR>
<TD>
Creating a new document tree
</TD>
<TD BGCOLOR='#BBFFBB'>
1337.6
</TD>
<TD BGCOLOR='#99FF99'>
3874.4 (2.90)
</TD>
<TD BGCOLOR='#FFFFFF'>
1200.2 (0.90)
</TD>
</TR>
<TR>
<TD>
Writing document out to a string
</TD>
<TD BGCOLOR='#99FF99'>
16.2
</TD>
<TD BGCOLOR='#BBFFBB'>
9.4 (0.58)
</TD>
<TD BGCOLOR='#FFAAAA'>
N/A
</TD>
</TR>
<TR>
<TD>
Hand-parsing children
</TD>
<TD BGCOLOR='#BBFFBB'>
2350.8
</TD>
<TD BGCOLOR='#99FF99'>
4076.6 (1.73)
</TD>
<TD BGCOLOR='#FFFFFF'>
30.2 (0.01)
</TD>
</TR>
<TR>
<TD>
XPath
</TD>
<TD BGCOLOR='#99FF99'>
450.0
</TD>
<TD BGCOLOR='#FFAAAA'>
N/A
</TD>
<TD BGCOLOR='#FFAAAA'>
N/A
</TD>
</TR>
<TR>
<TD>
Parsing large document
</TD>
<TD BGCOLOR='#BBFFBB'>
4.8
</TD>
<TD BGCOLOR='#FFFFFF'>
3.0 (0.62)
</TD>
<TD BGCOLOR='#99FF99'>
6.4 (1.33)
</TD>
</TR>
<TR>
<TD>
Stream parsing
</TD>
<TD BGCOLOR='#BBFFBB'>
8.4
</TD>
<TD BGCOLOR='#FFFFFF'>
3.2 (0.38)
</TD>
<TD BGCOLOR='#99FF99'>
77.2 (9.19)
</TD>
</TR>
</TABLE>
<P/>
</BODY>
</HTML>
|