in reply to XML or Storable?

Storable is probably the answer to your specific problem. One advantage of XML is that it's possible to edit the serialised form - may be handy in the odd situation.

If you use XML::Simple, writing the serialised form to XML is essentially a one line call to XMLout(). In recognition of the fact that parsing XML is probably slower than slurping in Storable data, XML::Simple can transparently 'cache' the parsed version using Storable.

One disadvantage of XML::Simple is that it won't work with blessed references.