[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Does SAX make sense?


saxophone clock
David Megginson wrote,
> Miles Sabin writes:
> > For a one-shot application (ie. startup; process one document
> > instance; terminate) the classloading overhead for the DOM API can
> > be quite significant even with the most recent VMs. In some work
> > I've done lately I've seen DOM classloading account for as much as
> > 10% of wall clock time with the Sun 1.4.1_02 VM on Linux, Solaris
> > and the other one. SAX, being a much smaller API, is at an
> > advantage here.
>
> That's scary.  I meant just the time for object allocation when
> loading the XML document (a DOM tree contains a *lot* of objects).  I
> had not considered class loading overhead.

Well, I guess I should emphasize that the case I was talking about there 
was fairly esoteric.

In general, tho', it's not so much scary as inevitable. Consider a 
trivial document <foo>wibble</foo>. Now consider how many additional 
non-core classes and interfaces have to be dragged off disk, verified 
and initialized before you can do anything interesting with it via the 
DOM API. If the application itself is trivial, it shouldn't be all that 
surprising that DOM classloading has a measurable impact.

On the bright side, it's quite possible that one aspect of this,

  http://www.jcp.org/en/jsr/detail?id=202

(see esp. section 2.5) will improve things significantly.

Cheers,


Miles

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.