I am just about ready to give up on the XSLT library. The W3C's
attitude to the XML "standard" being a prime driver (what's the point
of implementing a standard when it will arbitrarily and
retrospectively be pulled from underneath you?). The other is my
inability to solve the performance problem.
I have done some timings on an identity transformation of a 10MB XML
file. This is likely to be the worst case scenario for using
ST_STRING, as the cost of copying all the strings from UC_UTF8_STRING
to ST_STRING ought to be significant compared with the rest of the
processing (which is the least possible for any XSLT transformation
that does not involve filtering out some of the data). Even so, this
cost ought to be relatively low, and I would have hoped for an overall
improvement.
Instead the runtime goes from 26 seconds to 35 seconds.
I did some timings of other methods of copying an XML file to try to
put this into perspective:
1. Identity transformation using Saxon and xsltproc -> 1.5 and 1
second respectively. Pretty damning.
2. Linux cp command - 25 milliseconds.
3. Gobo Eiffel XML parser using the example/xml/tree/formatter program
(modified to operate in unicode string mode, as there were unicode
character references in the XML file, and commenting out the DTD in
the file, as the program will not process an external DTD) - 15
seconds.
4. Gobo Eiffel XML parser using the example/xml/event/print program
(same modifications as above). Output redirected to a file. - 26 seconds.
The last one was particularly intriguing, as I noticed half the time
was kernel time. I redirected it to /dev/null instead and it came down
to 10 seconds. I'm not sure what is going on at all here. Any thoughts?
Anyway, there seems little hope of getting the XSLT library to perform
on this basis. It would seem the entire XML parser/event
infrastructure would need re-writing. I have no appetite for the task
given the current W3C climate.
ST_STRING might be useful anyway. Shall I post the classes here for review?
--
Colin Adams
Preston Lancashire
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/_______________________________________________
gobo-eiffel-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gobo-eiffel-develop