Re: [xml] performance of parsing docbook with xincludes
- From: Stefan Sauer <ensonic hora-obscura de>
- To: Nick Wellnhofer <wellnhofer aevum de>, xml gnome org
- Subject: Re: [xml] performance of parsing docbook with xincludes
- Date: Tue, 15 May 2018 20:40:07 +0200
On 05/15/2018 12:42 PM, Nick Wellnhofer wrote:
On 14/05/2018 21:48, Stefan Sauer wrote:
This part looks suspicious:
|--22.98%--0xc2160
| xmlFreeDoc
| |
| --22.42%--xmlFreeDtd
Can I tell it to not load dtds in the first place? Is it loading the
dtd for each an every xinclude?
Good catch. It seems that the XInclude engine always parses included
docs with XML_PARSE_DTDLOAD:
https://git.gnome.org/browse/libxml2/tree/xinclude.c#n450
If you're not using XML catalogs, this will probably cause the DTD to
be loaded over the network multiple times which could explain the
slowdown.
Can you try to change the line to
xmlCtxtUseOptions(pctxt, ctxt->parseFlags);
and see if it helps?
Nick
It does not help. I'll experiment further. Thanks for the recomendations.
Stefan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]