I use a batch file to pull out what I need.
It has one line, and assumes you've already piped the xml to a file called xml.txt
The output of the filtering process writes the new info to xml2.txt
findstr /L /I "<mame <machine <description <disk <rom <sample <driver </machine </mame" \xml.txt > \xml2.txt