luyuncheng commented on PR #11987: URL: https://github.com/apache/lucene/pull/11987#issuecomment-1332277159
@rmuir Thanks for the replying this issue, i did some benchmarks: > better to assign null and create array of the correct size, if it won't be reused. LGTM , i assigned null at commit [0dfb7c](https://github.com/apache/lucene/pull/11987/commits/0dfb7c6bc6f63af13577217306b404f869c0254b) > need to make sure this doesn't cause performance regression for normal use-cases. I try to run benchmark shows little regression as follows: runStoredFieldsBenchmark.py | | Baseline | Candidate | | :--- | :----: | ---: | | BEST_SPEED | 313241.00 | 313355.00 | | BEST_COMPRESSION | 606150.00 | 605147.00 | localrun.py -source wikimedium1m: ``` TaskQPS baseline StdDevQPS my_modified_version StdDev Pct diff p-value HighTermMonthSort 1166.94 (9.6%) 1110.96 (6.9%) -4.8% ( -19% - 13%) 0.070 BrowseMonthSSDVFacets 70.78 (13.1%) 68.11 (3.3%) -3.8% ( -17% - 14%) 0.212 MedTerm 473.43 (6.0%) 461.52 (5.5%) -2.5% ( -13% - 9%) 0.166 IntNRQ 205.75 (17.3%) 200.82 (19.4%) -2.4% ( -33% - 41%) 0.681 BrowseDayOfYearSSDVFacets 63.52 (13.0%) 62.16 (10.8%) -2.1% ( -22% - 24%) 0.570 BrowseMonthTaxoFacets 57.51 (28.9%) 56.46 (22.4%) -1.8% ( -41% - 69%) 0.823 AndHighHigh 166.48 (4.4%) 164.56 (4.6%) -1.2% ( -9% - 8%) 0.418 HighTerm 429.10 (5.4%) 425.86 (4.5%) -0.8% ( -10% - 9%) 0.633 AndHighMed 225.64 (4.6%) 224.60 (5.0%) -0.5% ( -9% - 9%) 0.759 LowSpanNear 114.76 (4.1%) 114.25 (3.5%) -0.4% ( -7% - 7%) 0.714 MedIntervalsOrdered 78.89 (5.9%) 78.60 (5.1%) -0.4% ( -10% - 11%) 0.832 HighIntervalsOrdered 21.65 (9.1%) 21.57 (7.9%) -0.3% ( -15% - 18%) 0.902 MedSpanNear 186.08 (3.5%) 185.51 (4.9%) -0.3% ( -8% - 8%) 0.821 LowIntervalsOrdered 24.31 (5.7%) 24.28 (5.6%) -0.1% ( -10% - 11%) 0.950 PKLookup 135.52 (7.1%) 135.50 (4.9%) -0.0% ( -11% - 12%) 0.993 Wildcard 49.84 (11.7%) 49.85 (12.3%) 0.0% ( -21% - 27%) 0.996 Fuzzy1 79.17 (4.2%) 79.21 (4.3%) 0.0% ( -8% - 8%) 0.971 LowPhrase 116.62 (3.4%) 116.86 (4.1%) 0.2% ( -7% - 7%) 0.859 Fuzzy2 98.02 (4.3%) 98.23 (4.3%) 0.2% ( -8% - 9%) 0.872 HighTermDayOfYearSort 198.72 (9.3%) 199.23 (5.3%) 0.3% ( -13% - 16%) 0.913 LowTerm 771.21 (5.1%) 773.32 (4.3%) 0.3% ( -8% - 10%) 0.854 OrHighHigh 62.86 (4.2%) 63.07 (6.0%) 0.3% ( -9% - 10%) 0.845 HighSpanNear 30.21 (5.4%) 30.33 (5.2%) 0.4% ( -9% - 11%) 0.810 BrowseDateSSDVFacets 10.94 (14.0%) 10.99 (16.1%) 0.4% ( -26% - 35%) 0.925 MedPhrase 317.58 (4.7%) 319.13 (6.3%) 0.5% ( -10% - 12%) 0.781 BrowseDateTaxoFacets 53.51 (26.8%) 53.81 (20.1%) 0.6% ( -36% - 64%) 0.941 Respell 95.92 (5.3%) 96.55 (4.3%) 0.7% ( -8% - 10%) 0.671 BrowseRandomLabelTaxoFacets 45.89 (23.3%) 46.20 (18.8%) 0.7% ( -33% - 55%) 0.918 BrowseDayOfYearTaxoFacets 53.49 (26.8%) 53.89 (20.0%) 0.8% ( -36% - 64%) 0.920 HighPhrase 7.87 (4.3%) 7.94 (6.1%) 0.9% ( -9% - 11%) 0.612 Prefix3 414.44 (4.6%) 419.19 (7.4%) 1.1% ( -10% - 13%) 0.557 OrHighMed 155.31 (4.2%) 157.71 (3.9%) 1.5% ( -6% - 10%) 0.226 AndHighLow 1053.26 (8.5%) 1069.91 (7.1%) 1.6% ( -12% - 18%) 0.523 MedSloppyPhrase 24.43 (3.8%) 24.83 (4.6%) 1.6% ( -6% - 10%) 0.220 LowSloppyPhrase 133.87 (3.3%) 136.89 (5.0%) 2.3% ( -5% - 10%) 0.091 HighSloppyPhrase 20.51 (4.5%) 20.99 (4.4%) 2.3% ( -6% - 11%) 0.102 BrowseRandomLabelSSDVFacets 44.18 (3.0%) 45.95 (6.1%) 4.0% ( -5% - 13%) 0.009 OrHighLow 331.66 (5.7%) 345.34 (5.9%) 4.1% ( -7% - 16%) 0.024 ``` -- 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