closed araqne/logpresso.com#245. support in-memory optimization for small top query (sort limit < 1000)