You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by AsterixDB Code Review <do...@asterix-gerrit.ics.uci.edu> on 2026/07/22 10:31:07 UTC
[S] Change in asterixdb[master]: [NO ISSUE][COMP] Speed up compilation of large IN-list predicates
From Preetham Poluparthi <pr...@gmail.com>:
Hello Jenkins,
I'd like you to reexamine a change. Please visit
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21452?usp=email
to look at the new patch set (#2).
The following approvals got outdated and were removed:
Integration-Tests+1 by Jenkins
Change subject: [NO ISSUE][COMP] Speed up compilation of large IN-list predicates
......................................................................
[NO ISSUE][COMP] Speed up compilation of large IN-list predicates
- user model changes: no
- storage format changes: no
- interface changes: no
Details:
A predicate of the form `field IN [ ...N values... ]` is rewritten into a large
disjunction of equalities (OR of eq(field, c_i)). While selecting an access
method for such a SELECT, IntroduceSelectAccessMethodRule processed the
disjunction with two O(n^2) steps, so compiling large IN-lists took several seconds.
- AccessMethodUtils.addNewOptFuncExprToAnalysisCtx no longer scans all
previously matched function expressions uses an O(1)
hash-set lookup. AccessMethodAnalysisContext now mirrors matchedFuncExprs in a
HashSet (AbstractFunctionCallExpression hCode).
- BTreeAccessMethod.optimizeSelectCondition replaces List.containsAll (O(n^2)
deep-equals) with a HashSet-backed membership check.
Co-Authored-By: Claude Opus 4.8 (1M context) <no...@anthropic.com>
Change-Id: I29fd772e510bf70123383353ae3a07f9ae9f3033
---
M asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/AccessMethodAnalysisContext.java
M asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/AccessMethodUtils.java
M asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/am/BTreeAccessMethod.java
3 files changed, 23 insertions(+), 7 deletions(-)
git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb refs/changes/52/21452/2
--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/21452?usp=email
To unsubscribe, or for help writing mail filters, visit https://asterix-gerrit.ics.uci.edu/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Change-Id: I29fd772e510bf70123383353ae3a07f9ae9f3033
Gerrit-Change-Number: 21452
Gerrit-PatchSet: 2
Gerrit-Owner: Preetham Poluparthi <pr...@gmail.com>
Gerrit-Reviewer: Jenkins <je...@fulliautomatix.ics.uci.edu>