Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Fastest way of XML -> perl structure

by vrk (Chaplain)
on Mar 20, 2017 at 15:28 UTC ( #1185266=note: print w/replies, xml ) Need Help??


in reply to Fastest way of XML -> perl structure

Many years ago at university, I wrote a GUI program that had to read, seek and render mzXML files on the fly. These files contained 1-600 MB of data, although some of it was in flattened substructures contained by the main XML structure. XML::Twig saved my bacon. It allowed very fast seeking and navigating the file without having to keep most of it in memory. When you do need to read a subtree into memory, it's trivial.

However, it's hard to say whether XML::Twig (or XML::LibXML as also suggested) will be of any help without knowing a bit more about the input data. Is there something peculiar about the structure of the XML files, like very deep hierarchies, or hundreds of attributes per element, or something else that would explain the slowness in parsing?

  • Comment on Re: Fastest way of XML -> perl structure

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1185266]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (5)
As of 2023-02-02 15:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I prefer not to run the latest version of Perl because:







    Results (19 votes). Check out past polls.

    Notices?