in reply to XML Parse performance

As mirod and Elian have observed, limited memory leading to swapping is the most likely cause of the problem. If you slurp the whole document into a document tree then you'll likely have exactly the same problems regardless of which module you use for parsing. However, the main point of XML::Twig is to enable you to reap the benefits of a tree based model without having to have the whole file in memory. With judicious use of the twig_roots mode, you can have XML::Twig hand your code a tree representation of one section of the document. When you've finished working with that section, discard it and the memory will be reused for the next section.