GNOME Bugzilla – Bug 743293
validate: launcher: Use cElementTree for XML parsing
Last modified: 2015-02-17 16:30:40 UTC
Using cElementTree instead of ElementTree speeds up parsing of media descriptor files.
Created attachment 295093 [details] [review] validate: launcher: Use cElementTree for XML parsing Using cElementTree instead of ElementTree speeds up parsing of media descriptor files. The total time spent parsing XML files drops from ~0.64 s to ~0.24 s, leading to faster initialisation times for gst-validate-launcher.
Review of attachment 295093 [details] [review]: ::: validate/launcher/baseclasses.py @@ +36,3 @@ + import xml.etree.cElementTree as ET +except ImportError: + import xml.etree.ElementTree as ET It looks like it is distributed with python since python 2.5 so you can just import it unconditionnally
Created attachment 295106 [details] [review] validate: launcher: Use cElementTree for XML parsing Using cElementTree instead of ElementTree speeds up parsing of media descriptor files. The total time spent parsing XML files drops from ~0.64 s to ~0.24 s, leading to faster initialisation times for gst-validate-launcher.
Attachment 295106 [details] pushed as 2d5ad1a - validate: launcher: Use cElementTree for XML parsing