[ https://issues.apache.org/jira/browse/LUCENE-10142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17423594#comment-17423594 ]
ASF subversion and git services commented on LUCENE-10142: ---------------------------------------------------------- Commit b4fcdd9770ef1abcac1287c0751b56ada6dde75a in lucene's branch refs/heads/main from Robert Muir [ https://gitbox.apache.org/repos/asf?p=lucene.git;h=b4fcdd9 ] LUCENE-10142: use a better RNG for HNSW vectors This code makes extensive use of Random, but uses the old legacy java.util.Random, which is slow. Swap in SplittableRandom for better performance. > use a better RNG for Hnsw vectors > --------------------------------- > > Key: LUCENE-10142 > URL: https://issues.apache.org/jira/browse/LUCENE-10142 > Project: Lucene - Core > Issue Type: Task > Reporter: Robert Muir > Priority: Major > Attachments: LUCENE-10142.patch > > > When profiling indexing with vectors at > http://people.apache.org/~mikemccand/lucenebench/, I see a fair amount of > time spent in java.util.Random. > {noformat} > PERCENT CPU SAMPLES STACK > ... > 7.30% 305461 java.util.Random#nextInt() > {noformat} > We don't need its thread-safety guarantees (CAS loop etc). > We can use SplittableRandom as a drop-in replacement. -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org