You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2021/11/05 09:53:08 UTC

[GitHub] [lucene] jpountz commented on a change in pull request #426: Javadocs, Sorter impls:

jpountz commented on a change in pull request #426:
URL: https://github.com/apache/lucene/pull/426#discussion_r743484713



##########
File path: lucene/core/src/java/org/apache/lucene/util/InPlaceMergeSorter.java
##########
@@ -18,7 +18,10 @@
 
 /**
  * {@link Sorter} implementation based on the merge-sort algorithm that merges in place (no extra
- * memory will be allocated). Small arrays are sorted with insertion sort.
+ * memory will be allocated). Small arrays are sorted with binary sort.
+ *
+ * <p>This algorithm is stable. It's especially suited to sorting small lists where we'd rather
+ * optimize for avoiding allocating memory for this task.

Review comment:
       While we're adding this, maybe also mention that it performs well on lists that are already sorted.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org