rmuir commented on a change in pull request #191: URL: https://github.com/apache/lucene/pull/191#discussion_r660224322
########## File path: lucene/facet/src/test/org/apache/lucene/facet/TestLongValueFacetCounts.java ########## @@ -382,19 +383,19 @@ public void testRandomMultiValued() throws Exception { + allSingleValued); } - long[][] values = new long[valueCount][]; - for (int i = 0; i < valueCount; i++) { + Long[][] values = new Long[docCount][]; Review comment: yes that is mainly it. If the index has tens of millions of documents, let's avoid creating tens of millions of objects for performance reasons (both cpu cycles in faceting and also avoiding pressure on the GC system). It is true in some cases that the c2 compiler can eliminate this when the stars align, but we should just avoid doing inefficient code and not leave it to chance in such tight loops. -- 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-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org