There is an issue with the grm xml processor in 5.8 if you try reading the data from the document, and is 5-10 times slower than 5.6.
It appears to do all the processing on the disk and it does not support grabbing just the next entry, but instead parses the xml document to that entry again.
The result is that for a 50MB xml document it could take 1/2 hour to an hour to process.
Our workaround was to use a different basic xml parser that did not perform xsd validate, and to also increase the timeouts in the tomcat configuration:
platform/apps/conf/reg.xml
platform/apps/conf/server.xml
If you do not perform any processing on the document, you may be able to get away with just increasing the timeouts in the tomcat configuration.