File tree Expand file tree Collapse file tree 3 files changed +5
-3
lines changed
core/src/java/org/apache/lucene Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -220,6 +220,8 @@ Optimizations
220220
221221* GITHUB#14970: Further speed up filtering hits by score. (Adrien Grand)
222222
223+ * GITHUB#14991: Refactor for loop at PointRangeQuery hot path. (Ge Song)
224+
223225Changes in Runtime Behavior
224226---------------------
225227* GITHUB#14823: Decrease TieredMergePolicy's default number of segments per
Original file line number Diff line number Diff line change @@ -210,7 +210,7 @@ public void visit(DocIdSetIterator iterator) throws IOException {
210210
211211 @ Override
212212 public void visit (IntsRef ref ) {
213- for (int i = ref .offset ; i < ref .offset + ref .length ; i ++) {
213+ for (int i = ref .offset , to = ref .offset + ref .length ; i < to ; i ++) {
214214 result .set (ref .ints [i ]);
215215 }
216216 cost [0 ] += ref .length ;
Original file line number Diff line number Diff line change @@ -60,8 +60,8 @@ public void add(int doc) {
6060
6161 @ Override
6262 public void add (IntsRef docs ) {
63- for (int i = 0 ; i < docs .length ; i ++) {
64- bitSet .set (docs .ints [docs . offset + i ]);
63+ for (int i = docs . offset , to = docs .offset + docs . length ; i < to ; i ++) {
64+ bitSet .set (docs .ints [i ]);
6565 }
6666 }
6767
You can’t perform that action at this time.
0 commit comments