[ https://issues.apache.org/jira/browse/LUCENE-1483?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12661148#action_12661148 ]
Michael McCandless commented on LUCENE-1483: -------------------------------------------- I prototyped a rough change to the FieldComparator API, whereby TopFieldCollector calls setBottom to notify the comparator which slot is the bottom of the queue (whenever it changes), and then calls compareBottom (which replaces compare(int slot, int doc, float score)). This seems to offer decent perf. gains so I think we should make this change for real? I think it gives good gains because 1) compare to bottom is very frequent for a search that has many hits, and where the queue fairly quickly converges to the top N, 2) it allows the on-demand comparator to pre-cache the bottom's ord, and 3) it saves one array deref. TopFieldCollector would guarantee that compareBottom is not called unless setBottom was called; during the startup transient, setBottom is not called until the queue becomes full. > Change IndexSearcher multisegment searches to search each individual segment > using a single HitCollector > -------------------------------------------------------------------------------------------------------- > > Key: LUCENE-1483 > URL: https://issues.apache.org/jira/browse/LUCENE-1483 > Project: Lucene - Java > Issue Type: Improvement > Affects Versions: 2.9 > Reporter: Mark Miller > Priority: Minor > Attachments: LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, LUCENE-1483.patch, > sortBench.py, sortCollate.py > > > FieldCache and Filters are forced down to a single segment reader, allowing > for individual segment reloading on reopen. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscr...@lucene.apache.org For additional commands, e-mail: java-dev-h...@lucene.apache.org