Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Specialize DisiPriorityQueue for the 2-clauses case. #14070

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

jpountz
Copy link
Contributor

@jpountz jpountz commented Dec 16, 2024

Disjunctions with 2 clauses are rather common. Specializing this case enables some shortcuts.

Disjunctions with 2 clauses are rather common. Specializing this case enables
some shortcuts.
@jpountz jpountz added this to the 10.2.0 milestone Dec 16, 2024
@jpountz
Copy link
Contributor Author

jpountz commented Dec 16, 2024

Here are results on wikibigall. Several queries have a speedup with a very low p-value.

                            TaskQPS baseline      StdDevQPS my_modified_version      StdDev                Pct diff p-value
                      OrHighRare      283.53      (4.2%)      277.97      (6.2%)   -2.0% ( -11% -    8%) 0.241
                        Wildcard       79.54      (3.8%)       78.68      (3.6%)   -1.1% (  -8% -    6%) 0.358
                      DismaxTerm      615.37      (2.9%)      608.82      (2.8%)   -1.1% (  -6% -    4%) 0.238
                   TermMonthSort     3963.49      (1.3%)     3926.24      (1.7%)   -0.9% (  -3% -    2%) 0.046
                DismaxOrHighHigh      122.08      (2.0%)      121.26      (3.1%)   -0.7% (  -5% -    4%) 0.418
                        PKLookup      283.63      (1.6%)      281.85      (2.5%)   -0.6% (  -4% -    3%) 0.351
                 FilteredPrefix3      132.74      (6.3%)      132.18      (6.6%)   -0.4% ( -12% -   13%) 0.836
                         Prefix3      138.60      (6.5%)      138.02      (6.9%)   -0.4% ( -12% -   13%) 0.843
             CountFilteredOrMany        8.60      (3.3%)        8.57      (2.7%)   -0.4% (  -6% -    5%) 0.668
                      TermDTSort      294.87      (4.6%)      294.24      (9.6%)   -0.2% ( -13% -   14%) 0.928
                      OrHighHigh       56.01      (4.8%)       55.94      (4.4%)   -0.1% (  -8% -    9%) 0.931
                          Fuzzy1       83.18      (2.5%)       83.10      (2.3%)   -0.1% (  -4% -    4%) 0.902
                            Term      494.29      (3.0%)      493.95      (3.7%)   -0.1% (  -6% -    6%) 0.947
                          Fuzzy2       78.47      (2.2%)       78.42      (2.0%)   -0.1% (  -4% -    4%) 0.923
                 DismaxOrHighMed      174.72      (1.9%)      174.71      (2.1%)   -0.0% (  -3% -    4%) 0.991
                       OrHighMed      202.12      (3.8%)      202.13      (3.5%)    0.0% (  -7% -    7%) 0.997
                     AndHighHigh       45.24      (1.7%)       45.24      (1.1%)    0.0% (  -2% -    2%) 0.988
                    FilteredTerm      156.36      (1.4%)      156.43      (1.4%)    0.0% (  -2% -    2%) 0.923
                   TermTitleSort      157.39      (2.3%)      157.47      (2.6%)    0.0% (  -4% -    5%) 0.954
      FilteredOr2Terms2StopWords      149.22      (1.2%)      149.33      (1.1%)    0.1% (  -2% -    2%) 0.825
             FilteredOrStopWords       43.36      (1.6%)       43.41      (1.7%)    0.1% (  -3% -    3%) 0.824
                     CountPhrase        4.26      (2.1%)        4.26      (1.5%)    0.2% (  -3% -    3%) 0.748
               TermDayOfYearSort      650.96      (2.2%)      652.28      (3.7%)    0.2% (  -5% -    6%) 0.832
              Or2Terms2StopWords      168.70      (3.5%)      169.20      (2.3%)    0.3% (  -5% -    6%) 0.750
                  FilteredPhrase       29.99      (1.5%)       30.11      (1.4%)    0.4% (  -2% -    3%) 0.394
             CountFilteredPhrase       25.30      (1.4%)       25.42      (1.5%)    0.5% (  -2% -    3%) 0.305
                FilteredOr3Terms      166.34      (1.4%)      167.18      (0.9%)    0.5% (  -1% -    2%) 0.165
               FilteredAnd3Terms      195.32      (1.7%)      196.32      (1.7%)    0.5% (  -2% -    4%) 0.345
                      AndHighMed      129.96      (1.8%)      130.71      (1.4%)    0.6% (  -2% -    3%) 0.258
     FilteredAnd2Terms2StopWords      197.65      (1.3%)      198.84      (1.4%)    0.6% (  -2% -    3%) 0.156
                AndMedOrHighHigh       60.53      (1.9%)       60.91      (1.6%)    0.6% (  -2% -    4%) 0.274
             And2Terms2StopWords      165.55      (2.3%)      166.57      (1.2%)    0.6% (  -2% -    4%) 0.287
                     CountOrMany        7.29      (8.8%)        7.34      (8.9%)    0.6% ( -15% -   20%) 0.817
               FilteredOrHighMed      154.91      (1.2%)      155.96      (0.7%)    0.7% (  -1% -    2%) 0.028
                       CountTerm    11039.26      (2.2%)    11114.73      (3.1%)    0.7% (  -4% -    6%) 0.418
         CountFilteredOrHighHigh       63.08      (2.2%)       63.53      (2.2%)    0.7% (  -3% -    5%) 0.295
              FilteredOrHighHigh       64.41      (1.5%)       64.91      (1.5%)    0.8% (  -2% -    3%) 0.098
                        Or3Terms      176.90      (3.7%)      178.38      (2.4%)    0.8% (  -5% -    7%) 0.399
                     OrStopWords       35.83      (5.8%)       36.16      (3.9%)    0.9% (  -8% -   11%) 0.547
              FilteredAndHighMed      129.99      (2.1%)      131.39      (1.6%)    1.1% (  -2% -    4%) 0.072
                          OrMany       19.85      (2.9%)       20.07      (2.2%)    1.1% (  -3% -    6%) 0.159
                    AndStopWords       32.29      (3.5%)       32.65      (1.4%)    1.1% (  -3% -    6%) 0.179
                CountAndHighHigh       54.45      (2.1%)       55.08      (2.2%)    1.2% (  -3% -    5%) 0.083
                       And3Terms      177.22      (2.8%)      179.33      (1.5%)    1.2% (  -3% -    5%) 0.095
            FilteredAndStopWords       47.32      (2.0%)       47.89      (2.4%)    1.2% (  -3% -    5%) 0.081
             FilteredAndHighHigh       62.16      (1.8%)       62.95      (2.0%)    1.3% (  -2% -    5%) 0.034
                 CountOrHighHigh       72.80      (8.9%)       73.83      (9.2%)    1.4% ( -15% -   21%) 0.621
                 CountAndHighMed      157.11      (2.6%)      159.49      (3.0%)    1.5% (  -4% -    7%) 0.092
                  CountOrHighMed      134.72      (6.7%)      136.79      (6.9%)    1.5% ( -11% -   16%) 0.476
                          Phrase       14.89      (4.5%)       15.14      (5.7%)    1.7% (  -8% -   12%) 0.303
                  FilteredOrMany       16.85      (3.5%)       17.17      (4.4%)    1.9% (  -5% -   10%) 0.132
              CombinedAndHighMed       55.18      (2.0%)       56.75      (2.4%)    2.8% (  -1% -    7%) 0.000
             CombinedAndHighHigh       15.23      (2.2%)       15.67      (2.5%)    2.9% (  -1% -    7%) 0.000
          CountFilteredOrHighMed       68.46      (1.9%)       70.53      (1.8%)    3.0% (   0% -    6%) 0.000
                    CombinedTerm       31.53      (2.6%)       32.52      (3.4%)    3.2% (  -2% -    9%) 0.001
               CombinedOrHighMed       71.83      (1.8%)       74.29      (2.0%)    3.4% (   0% -    7%) 0.000
              CombinedOrHighHigh       18.89      (1.8%)       19.55      (2.2%)    3.5% (   0% -    7%) 0.000
                  FilteredIntNRQ      112.01     (12.5%)      115.98     (16.1%)    3.5% ( -22% -   36%) 0.436
                          IntNRQ      112.95     (12.6%)      117.08     (16.2%)    3.7% ( -22% -   37%) 0.426
                 AndHighOrMedMed       45.28      (0.8%)       48.56      (1.0%)    7.3% (   5% -    9%) 0.000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants