Skip to content

Commit 230c88b

Browse files
authored
enhance: improve reduce performance on very large topk (milvus-io#32871)
fix milvus-io#32870 reduce cpu usage for reduce on large k Signed-off-by: xiaofanluan <xiaofan.luan@zilliz.com>
1 parent ef41f80 commit 230c88b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

internal/proxy/search_reduce_util.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ func reduceSearchResultDataNoGroupBy(ctx context.Context, subSearchResultData []
319319
cursors = make([]int64, subSearchNum)
320320

321321
j int64
322-
idSet = make(map[interface{}]struct{})
322+
idSet = make(map[interface{}]struct{}, limit)
323323
)
324324

325325
// skip offset results

0 commit comments

Comments
 (0)