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

[PERF] TSDB: Optimize inverse matching (#14144) #756

Merged
merged 1 commit into from
Nov 20, 2024

Commits on Nov 19, 2024

  1. [PERF] TSDB: Optimize inverse matching (#14144)

    Simple follow-up to #13620. Modify `tsdb.PostingsForMatchers` to use the optimized tsdb.IndexReader.PostingsForLabelMatching method also for inverse matching.
    
    Introduce method `PostingsForAllLabelValues`, to avoid changing the existing method.
    
    The performance is much improved for a subset of the cases; there are up to
    ~60% CPU gains and ~12.5% reduction in memory usage.
    
    Remove `TestReader_InversePostingsForMatcherHonorsContextCancel` since
    `inversePostingsForMatcher` only passes `ctx` to `IndexReader` implementations now.
    
    Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
    aknuds1 committed Nov 19, 2024
    Configuration menu
    Copy the full SHA
    f319404 View commit details
    Browse the repository at this point in the history