[Tilesathome] Why is using regexp for xml evil...

Jiri Klement jiri.klement at gmail.com
Mon Sep 15 13:21:01 BST 2008


Hi,

Today I've noticed Beziercurve hinting for tileset 2103 1347 is taking
unusually long so I've started digging what is causing it. I've found
out lines2curves is really slow when it encounters long line. The line
consisted of many xml elements. So I've run svg file through xml_pp to
make sure every line contains only one xml element. Then I've run some
benchmarks:

Smaller svg file with long lines - 67 seconds.
The same file with one element per line - less than one second.

20 MB svg file - more than hour (I've canceled it)
one element per line - less than one second



--
Jiri




More information about the Tilesathome mailing list