Add MemoryIndex reuse when percolating doc with nested type

Also make use of the thread local memory reuse for a document being percolated with nested objects. 
The memory index will only be reused for the root doc, since most of the times that will be the biggest document.