If you mean programatically, I made a custom tool to compare 2 XML documents using XSLT some years back. Basically, it was fixing the positions of different nodes and then compare the nodes using jDOM and XSLT. If you mean external comparison using a tool, nothing like XML SPY.
Heroic work plunger man. Please allow me to introduce you to this tiny ad:
Two software engineers solve most of the world's problems in one K&R sized book