And non validating parsers with
Ignoring for a moment the potential importance of validity to data-oriented applications, you might wonder why even when an XML document does not require a DTD (i.e., is standalone), it still must be well-formed.In fact, if a document is not well-formed, it cannot even be called an XML document.If the parser encounters a well-formedness problem, it should only report the problem to the calling application.
That is, if a document isn't well-formed, it can't even be called XML (excepting XML fragments).
To accomplish this, validating XML processors must read and process the entire DTD and all external parsed entities referenced in the document.
Non-validating processors are required to check only the document entity, including the entire internal DTD subset, for well-formedness.
The differences in performance were addressed in the second article.
This third article gives tips on improving the performance of XML-based applications from a programmatic and architectural point of view.
The extra code necessary to do the HTML-like corrections might not be a significant problem for a desktop PC with lots of memory.