[xml] xmlNewChild(...) slow in version 2.6.16-7 (debian sarge)
- From: Dominik Raddatz <dominik raddatz neomo de>
- To: xml gnome org
- Subject: [xml] xmlNewChild(...) slow in version 2.6.16-7 (debian sarge)
- Date: Wed, 24 Oct 2007 11:07:21 +0200
Hi,
the following statement seems somewhat slow:
xmlNodePtr myNode;
xmlChar *myText;
...
xmlNewChild(myNode, NULL, BAD_CAST "description", BAD_CAST myText);
takes about 25 ms when myText is 50kB; profiling suggests it wastes much time
using "xmlStrlen()".
the comparable statements
xmlNodePtr newNode=xmlNewChild(myNode, NULL, BAD_CAST "description", NULL);
xmlNodeAddContent(newNode, BAD_CAST myText);
are much faster, using less than 1 ms with the same text.
I haven't found any hint about whether this was a known problem and has been
fixed in later versions.
Thanks
Dominik
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]