Skip to content

Cache reusable Parquet pruning setup across files with the same schema#21566

Open
kosiew wants to merge 12 commits into
apache:mainfrom
kosiew:schema_caching-01-21554
Open

Cache reusable Parquet pruning setup across files with the same schema#21566
kosiew wants to merge 12 commits into
apache:mainfrom
kosiew:schema_caching-01-21554

Conversation

@kosiew

@kosiew kosiew commented Apr 12, 2026

Copy link
Copy Markdown
Contributor

Which issue does this PR close?

Rationale for this change

Parquet scans currently rewrite, simplify, and construct row-group pruning predicates independently for each file, even when multiple files share the same logical and physical schema. This repeated CPU-only preparation work is identical across those files and can be reused.

This change introduces a scan-scoped cache for reusable pruning setup while preserving all file-specific work such as metadata loading, page-index handling, reader state, and execution planning.

What changes are included in this PR?

  • Add a scan-scoped ParquetPruningSetupCache owned by ParquetMorselizer.

  • Cache adapted projection, adapted predicate, and the row-group pruning predicate for reusable schema adaptation results.

  • Refactor pruning setup construction into reusable helper functions (build_pruning_setup / build_or_get_pruning_setup).

  • Reuse cached setup only when it is safe to do so, including:

    • adapters that explicitly opt into reusable rewrites,
    • identical logical and physical schemas,
    • identical projection/predicate identities.
  • Skip caching for cases that depend on per-file or mutable state, including:

    • literal column replacement,
    • dynamic filter predicates,
    • input_file_name() projections,
    • adapter factories that do not declare reusable rewrites.
  • Extend PhysicalExprAdapterFactory with a supports_reusable_rewrites() capability, with the default adapter opting in and custom adapters remaining non-reusable by default.

  • Preserve the existing fallback path for non-cacheable scenarios.

Are these changes tested?

Yes. This PR adds targeted tests covering:

  • cache reuse for files with the same physical schema,
  • no reuse for adapter factories that do not support reusable rewrites,
  • no caching for input_file_name() projections,
  • no caching for dynamic filter predicates,
  • cache isolation for differing physical schemas.

Are there any user-facing changes?

No. This change is an internal optimization for Parquet scan preparation and is not intended to change query results or user-facing behavior.

LLM-generated code disclosure

This PR includes LLM-generated code and comments. All LLM-generated content has been manually reviewed.

@github-actions github-actions Bot added the datasource Changes to the datasource crate label Apr 12, 2026
@kosiew kosiew marked this pull request as ready for review April 12, 2026 09:44
@AdamGS

AdamGS commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

This is really awesome! I was planning on trying to add something like that once the morsel work is more mature, but I was wondering if it'll be possible to make it more format-independent? Ran into similar issue on our FileSource, which made me file #20078 (which I expect this PR to improve significantly if not just close outright).

@kosiew

kosiew commented Apr 14, 2026

Copy link
Copy Markdown
Contributor Author

@AdamGS

Thanks! I agree this is the direction we should take. This PR keeps the cache Parquet-local on purpose because the reusable setup currently stores Parquet-specific artifacts: the adapted Parquet projection/predicate, the physical schema after Parquet file-schema coercions / INT96 handling, and the row-group PruningPredicate. It also leaves page-index work, reader metadata, file metrics, and access-plan execution per file.

That said, the shape is a good stepping stone toward the more format-independent problem in #20078. The parts that seem general are:

scan-local reuse keyed by logical schema, physical schema, projection, predicate, and adapter cache-safety;
avoiding repeated PhysicalExprAdapterFactory::create / rewrite / simplification work for files with equivalent schema inputs;
letting custom adapters opt in only when their rewrites do not depend on factory-local or unkeyed per-file state.

I would prefer to land this narrowly for Parquet first, with the cache-safety contract and tests in place, then follow up by extracting the format-neutral expression adaptation / pruning setup cache into a datasource-level helper once another FileSource can exercise it. Vortex or another custom FileSource would be a good second consumer to make sure the abstraction is not overfit to Parquet row-group pruning.

@AdamGS

AdamGS commented Apr 14, 2026

Copy link
Copy Markdown
Contributor

That makes perfect sense, would be happy to help with anything here! This is really awesome stuff

@JSOD11

JSOD11 commented May 17, 2026

Copy link
Copy Markdown
Contributor

👋 Is this still being worked on?

@kosiew

kosiew commented May 18, 2026

Copy link
Copy Markdown
Contributor Author

@JSOD11
Yes, it is awaiting review.
Do you see anything I can improve on?

kosiew added 6 commits July 11, 2026 16:49
Add a scan-local ParquetPruningSetupCache in opener.rs
to reuse adapted projection, adapted predicate, and row-group
pruning predicate setup for same-schema files.

Implement
PhysicalExprAdapterFactory::supports_reusable_rewrites() in
schema_rewriter.rs to allow default adapters while defaulting
custom ones to opt-out.

Connect the cache to ParquetMorselizer in source.rs and
introduce a regression test to ensure the setup is reused
correctly across same-schema files while keeping it
conservative to avoid per-file literal replacements.
Simplify the pruning setup cache in opener.rs by removing the
wrapper entry struct, deriving PartialEq/Eq, and returning cloned
setup values instead of an extra Arc. Extract the cache-or-build
branch into build_or_get_pruning_setup and avoid repeated
literal_columns.is_empty() checks. Move returned pruning setup
fields directly into prepared and simplify the test-only counting
adapter and cache regression test loop. Tighten the
supports_reusable_rewrites doc comment in schema_rewriter.rs
without changing the public interface.
Refactor cache in opener.rs to utilize a HashMap,
computing cold misses outside the mutex for better
performance, with a re-check on insert. Add cache-boundary
tests for non-reusable adapters and diverse physical
schemas. Clarify documentation in schema_rewriter.rs
for supports_reusable_rewrites() to specify the
same logical/physical schema rewrite inputs.
Enhance opener.rs with cache-key rationale comments for clarity.
Update ParquetPruningSetupCache to handle concurrent cold misses by
implementing a per-entry pending/ready state. Clarify the public
contract of supports_reusable_rewrites() in schema_rewriter.rs.
- Added missing local imports for TimeUnit and ParquetAccessPlan.
- Removed stale DataFusionError import.
- Updated fully qualified RecordBatch types to avoid lint issues.
- Rewired three cache tests to use the local ParquetMorselizerBuilder helper instead of an outdated API.
- Ensured all tests passed by running `cargo test -p datafusion-datasource-parquet --lib -- opener::test`, with all 23 opener tests successful.
@kosiew kosiew force-pushed the schema_caching-01-21554 branch from 1a44061 to 31af7fc Compare July 11, 2026 08:55
kosiew added 3 commits July 11, 2026 17:23
- Disabled pruning setup cache when predicate contains dynamic filters.
- Disabled cache when projection contains input_file_name().

Added tests for:
- Dynamic filter stale snapshot regression.
- input_file_name() projection not populating reusable cache.
- Added cache entries type alias for improved readability.
- Deduplicated lock-poison error construction for consistency.
- Extracted cache eligibility helper to streamline code.
- Implemented shared test helper for input_file_name_expr().
- Added a two-file cache test helper and removed repeated loops for efficiency.
@kosiew kosiew changed the title Parquet: Add scan-level cache for adapted pruning setup (projection/predicate) to reuse CPU-only work across same-schema files Cache reusable Parquet pruning setup across files with the same schema Jul 11, 2026
kosiew and others added 3 commits July 11, 2026 20:24
- Removed `ParquetPruningSetupCacheEntry`, `Pending`, `Ready`, `Failed` states, and associated per-entry synchronization logic (Mutex, Condvar).
- Introduced a new cache structure using `Mutex<HashMap<ParquetPruningSetupCacheKey, ParquetPruningSetup>>`.
- Updated cache retrieval logic:
- On hit: return a cloned entry.
- On miss: build a new entry, insert it, and return.
- On error: no insertion is performed.
@alamb

alamb commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

run benchmark clickbench_partitioned

@alamb

alamb commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

I merged up from main and kicked off some benchmark runs

If it shows improvements I'll take a closer look

@alamb

alamb commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

I think in general for performance related PRs, I try to make sure we have benchmark results that justify the new code (and also to help figure out what to review in what order)

@adriangbot

Copy link
Copy Markdown

🤖 Benchmark running (GKE) | trigger
Instance: c4a-highmem-16 (12 vCPU / 65 GiB) | Linux bench-c4981139229-1075-9gj2g 6.12.85+ #1 SMP Mon May 11 08:17:35 UTC 2026 aarch64 GNU/Linux

CPU Details (lscpu)
Architecture:                            aarch64
CPU op-mode(s):                          64-bit
Byte Order:                              Little Endian
CPU(s):                                  16
On-line CPU(s) list:                     0-15
Vendor ID:                               ARM
Model name:                              Neoverse-V2
Model:                                   1
Thread(s) per core:                      1
Core(s) per cluster:                     16
Socket(s):                               -
Cluster(s):                              1
Stepping:                                r0p1
BogoMIPS:                                2000.00
Flags:                                   fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma lrcpc dcpop sha3 sm3 sm4 asimddp sha512 sve asimdfhm dit uscat ilrcpc flagm sb paca pacg dcpodp sve2 sveaes svepmull svebitperm svesha3 svesm4 flagm2 frint svei8mm svebf16 i8mm bf16 dgh rng bti
L1d cache:                               1 MiB (16 instances)
L1i cache:                               1 MiB (16 instances)
L2 cache:                                32 MiB (16 instances)
L3 cache:                                80 MiB (1 instance)
NUMA node(s):                            1
NUMA node0 CPU(s):                       0-15
Vulnerability Gather data sampling:      Not affected
Vulnerability Indirect target selection: Not affected
Vulnerability Itlb multihit:             Not affected
Vulnerability L1tf:                      Not affected
Vulnerability Mds:                       Not affected
Vulnerability Meltdown:                  Not affected
Vulnerability Mmio stale data:           Not affected
Vulnerability Reg file data sampling:    Not affected
Vulnerability Retbleed:                  Not affected
Vulnerability Spec rstack overflow:      Not affected
Vulnerability Spec store bypass:         Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:                Mitigation; __user pointer sanitization
Vulnerability Spectre v2:                Mitigation; CSV2, BHB
Vulnerability Srbds:                     Not affected
Vulnerability Tsa:                       Not affected
Vulnerability Tsx async abort:           Not affected
Vulnerability Vmscape:                   Not affected

Comparing schema_caching-01-21554 (94b3e6f) to 754e113 (merge-base) diff using: clickbench_partitioned
Results will be posted here when complete


File an issue against this benchmark runner

@adriangbot

Copy link
Copy Markdown

🤖 Benchmark completed (GKE) | trigger

Instance: c4a-highmem-16 (12 vCPU / 65 GiB)

CPU Details (lscpu)
Architecture:                            aarch64
CPU op-mode(s):                          64-bit
Byte Order:                              Little Endian
CPU(s):                                  16
On-line CPU(s) list:                     0-15
Vendor ID:                               ARM
Model name:                              Neoverse-V2
Model:                                   1
Thread(s) per core:                      1
Core(s) per cluster:                     16
Socket(s):                               -
Cluster(s):                              1
Stepping:                                r0p1
BogoMIPS:                                2000.00
Flags:                                   fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma lrcpc dcpop sha3 sm3 sm4 asimddp sha512 sve asimdfhm dit uscat ilrcpc flagm sb paca pacg dcpodp sve2 sveaes svepmull svebitperm svesha3 svesm4 flagm2 frint svei8mm svebf16 i8mm bf16 dgh rng bti
L1d cache:                               1 MiB (16 instances)
L1i cache:                               1 MiB (16 instances)
L2 cache:                                32 MiB (16 instances)
L3 cache:                                80 MiB (1 instance)
NUMA node(s):                            1
NUMA node0 CPU(s):                       0-15
Vulnerability Gather data sampling:      Not affected
Vulnerability Indirect target selection: Not affected
Vulnerability Itlb multihit:             Not affected
Vulnerability L1tf:                      Not affected
Vulnerability Mds:                       Not affected
Vulnerability Meltdown:                  Not affected
Vulnerability Mmio stale data:           Not affected
Vulnerability Reg file data sampling:    Not affected
Vulnerability Retbleed:                  Not affected
Vulnerability Spec rstack overflow:      Not affected
Vulnerability Spec store bypass:         Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:                Mitigation; __user pointer sanitization
Vulnerability Spectre v2:                Mitigation; CSV2, BHB
Vulnerability Srbds:                     Not affected
Vulnerability Tsa:                       Not affected
Vulnerability Tsx async abort:           Not affected
Vulnerability Vmscape:                   Not affected
Details

Comparing HEAD and schema_caching-01-21554
--------------------
Benchmark clickbench_partitioned.json
--------------------
┏━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┓
┃ Query     ┃                                  HEAD ┃               schema_caching-01-21554 ┃        Change ┃
┡━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━┩
│ QQuery 0  │          1.21 / 3.87 ±5.25 / 14.37 ms │          1.20 / 3.86 ±5.28 / 14.42 ms │     no change │
│ QQuery 1  │        12.78 / 12.92 ±0.16 / 13.21 ms │        12.68 / 12.90 ±0.14 / 13.10 ms │     no change │
│ QQuery 2  │        35.83 / 36.34 ±0.67 / 37.65 ms │        36.68 / 36.98 ±0.24 / 37.35 ms │     no change │
│ QQuery 3  │        31.23 / 31.76 ±0.37 / 32.10 ms │        30.39 / 30.73 ±0.25 / 31.10 ms │     no change │
│ QQuery 4  │     221.58 / 223.65 ±2.80 / 229.15 ms │     222.90 / 224.37 ±1.99 / 228.26 ms │     no change │
│ QQuery 5  │     267.52 / 269.99 ±1.61 / 272.45 ms │     266.27 / 271.28 ±3.98 / 275.31 ms │     no change │
│ QQuery 6  │           1.25 / 1.41 ±0.23 / 1.85 ms │           1.26 / 1.40 ±0.22 / 1.85 ms │     no change │
│ QQuery 7  │        13.81 / 14.05 ±0.14 / 14.22 ms │        13.39 / 13.56 ±0.12 / 13.72 ms │     no change │
│ QQuery 8  │     318.52 / 322.14 ±2.20 / 325.46 ms │     318.52 / 322.91 ±2.59 / 325.87 ms │     no change │
│ QQuery 9  │     448.31 / 452.09 ±3.95 / 459.23 ms │     439.74 / 452.74 ±9.69 / 465.58 ms │     no change │
│ QQuery 10 │        68.31 / 69.03 ±0.63 / 70.13 ms │        70.67 / 71.42 ±0.57 / 72.16 ms │     no change │
│ QQuery 11 │        79.85 / 80.92 ±0.79 / 81.88 ms │        81.71 / 82.62 ±0.96 / 84.30 ms │     no change │
│ QQuery 12 │     264.42 / 267.17 ±2.46 / 271.00 ms │     263.33 / 268.65 ±3.57 / 274.35 ms │     no change │
│ QQuery 13 │     355.64 / 363.21 ±7.58 / 375.02 ms │    357.36 / 370.51 ±13.05 / 393.52 ms │     no change │
│ QQuery 14 │     277.69 / 280.08 ±1.99 / 282.35 ms │     279.43 / 283.82 ±3.62 / 288.37 ms │     no change │
│ QQuery 15 │     261.69 / 265.50 ±3.21 / 270.37 ms │    264.96 / 278.49 ±13.49 / 303.24 ms │     no change │
│ QQuery 16 │     598.16 / 609.96 ±7.54 / 620.23 ms │     600.00 / 613.49 ±8.18 / 623.44 ms │     no change │
│ QQuery 17 │     608.51 / 616.52 ±5.79 / 626.25 ms │     611.36 / 616.66 ±7.22 / 630.64 ms │     no change │
│ QQuery 18 │ 1230.25 / 1251.95 ±11.40 / 1261.29 ms │ 1238.14 / 1259.58 ±18.49 / 1291.03 ms │     no change │
│ QQuery 19 │        27.82 / 31.46 ±6.80 / 45.07 ms │        27.84 / 31.15 ±4.58 / 39.84 ms │     no change │
│ QQuery 20 │    514.94 / 536.57 ±21.38 / 573.40 ms │     514.40 / 517.67 ±3.51 / 523.32 ms │     no change │
│ QQuery 21 │     510.13 / 515.73 ±3.85 / 520.98 ms │     518.03 / 522.02 ±5.26 / 532.41 ms │     no change │
│ QQuery 22 │   980.73 / 993.80 ±13.23 / 1016.96 ms │    976.03 / 988.00 ±9.89 / 1000.95 ms │     no change │
│ QQuery 23 │ 2984.66 / 3005.14 ±17.93 / 3034.16 ms │ 3058.09 / 3094.79 ±29.69 / 3131.99 ms │     no change │
│ QQuery 24 │        40.80 / 42.79 ±3.04 / 48.83 ms │        41.61 / 47.76 ±8.02 / 62.28 ms │  1.12x slower │
│ QQuery 25 │     110.73 / 117.08 ±7.76 / 131.84 ms │     110.69 / 114.82 ±5.82 / 126.20 ms │     no change │
│ QQuery 26 │        41.10 / 43.59 ±3.49 / 50.49 ms │        41.20 / 42.29 ±0.99 / 44.05 ms │     no change │
│ QQuery 27 │     659.32 / 667.21 ±6.53 / 676.15 ms │     665.92 / 670.94 ±8.06 / 686.95 ms │     no change │
│ QQuery 28 │ 2984.22 / 3009.14 ±13.55 / 3020.95 ms │ 3012.19 / 3057.37 ±27.84 / 3090.80 ms │     no change │
│ QQuery 29 │       41.02 / 54.62 ±12.64 / 75.53 ms │        41.33 / 41.75 ±0.37 / 42.33 ms │ +1.31x faster │
│ QQuery 30 │     300.87 / 304.15 ±2.98 / 309.23 ms │     305.89 / 310.61 ±4.20 / 318.33 ms │     no change │
│ QQuery 31 │    284.76 / 297.74 ±14.09 / 324.01 ms │     280.31 / 289.57 ±7.74 / 298.26 ms │     no change │
│ QQuery 32 │    917.15 / 938.22 ±16.92 / 960.25 ms │    910.76 / 935.94 ±18.38 / 964.91 ms │     no change │
│ QQuery 33 │ 1404.21 / 1449.09 ±22.73 / 1466.50 ms │ 1422.86 / 1446.20 ±13.02 / 1462.60 ms │     no change │
│ QQuery 34 │ 1472.50 / 1490.34 ±13.92 / 1513.94 ms │ 1438.72 / 1482.00 ±26.93 / 1515.36 ms │     no change │
│ QQuery 35 │    272.59 / 312.75 ±67.02 / 446.33 ms │    272.26 / 285.14 ±17.10 / 318.48 ms │ +1.10x faster │
│ QQuery 36 │        65.65 / 71.48 ±6.63 / 83.77 ms │        65.42 / 68.12 ±2.91 / 73.72 ms │     no change │
│ QQuery 37 │        35.02 / 38.11 ±4.80 / 47.65 ms │        35.07 / 40.49 ±6.64 / 50.83 ms │  1.06x slower │
│ QQuery 38 │        40.78 / 46.14 ±4.34 / 52.73 ms │        40.40 / 44.29 ±3.57 / 50.97 ms │     no change │
│ QQuery 39 │     141.21 / 152.03 ±7.08 / 163.07 ms │     135.08 / 149.10 ±8.86 / 163.05 ms │     no change │
│ QQuery 40 │        14.07 / 16.97 ±4.32 / 25.51 ms │        13.94 / 15.18 ±2.27 / 19.71 ms │ +1.12x faster │
│ QQuery 41 │        13.48 / 13.83 ±0.38 / 14.44 ms │        13.32 / 14.81 ±2.45 / 19.68 ms │  1.07x slower │
│ QQuery 42 │        12.71 / 13.69 ±1.56 / 16.80 ms │        12.90 / 16.96 ±4.87 / 23.83 ms │  1.24x slower │
└───────────┴───────────────────────────────────────┴───────────────────────────────────────┴───────────────┘
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ Benchmark Summary                      ┃            ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ Total Time (HEAD)                      │ 19334.23ms │
│ Total Time (schema_caching-01-21554)   │ 19442.92ms │
│ Average Time (HEAD)                    │   449.63ms │
│ Average Time (schema_caching-01-21554) │   452.16ms │
│ Queries Faster                         │          3 │
│ Queries Slower                         │          4 │
│ Queries with No Change                 │         36 │
│ Queries with Failure                   │          0 │
└────────────────────────────────────────┴────────────┘

Resource Usage

clickbench_partitioned — base (merge-base)

Metric Value
Wall time 100.0s
Peak memory 12.2 GiB
Avg memory 4.8 GiB
CPU user 995.8s
CPU sys 66.1s
Peak spill 0 B

clickbench_partitioned — branch

Metric Value
Wall time 100.0s
Peak memory 11.8 GiB
Avg memory 4.7 GiB
CPU user 1001.7s
CPU sys 66.9s
Peak spill 0 B

File an issue against this benchmark runner

@alamb

alamb commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

run benchmark clickbench_partitioned

@adriangbot

Copy link
Copy Markdown

🤖 Benchmark running (GKE) | trigger
Instance: c4a-highmem-16 (12 vCPU / 65 GiB) | Linux bench-c4982186485-1082-bs7fz 6.12.85+ #1 SMP Mon May 11 08:17:35 UTC 2026 aarch64 GNU/Linux

CPU Details (lscpu)
Architecture:                            aarch64
CPU op-mode(s):                          64-bit
Byte Order:                              Little Endian
CPU(s):                                  16
On-line CPU(s) list:                     0-15
Vendor ID:                               ARM
Model name:                              Neoverse-V2
Model:                                   1
Thread(s) per core:                      1
Core(s) per cluster:                     16
Socket(s):                               -
Cluster(s):                              1
Stepping:                                r0p1
BogoMIPS:                                2000.00
Flags:                                   fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma lrcpc dcpop sha3 sm3 sm4 asimddp sha512 sve asimdfhm dit uscat ilrcpc flagm sb paca pacg dcpodp sve2 sveaes svepmull svebitperm svesha3 svesm4 flagm2 frint svei8mm svebf16 i8mm bf16 dgh rng bti
L1d cache:                               1 MiB (16 instances)
L1i cache:                               1 MiB (16 instances)
L2 cache:                                32 MiB (16 instances)
L3 cache:                                80 MiB (1 instance)
NUMA node(s):                            1
NUMA node0 CPU(s):                       0-15
Vulnerability Gather data sampling:      Not affected
Vulnerability Indirect target selection: Not affected
Vulnerability Itlb multihit:             Not affected
Vulnerability L1tf:                      Not affected
Vulnerability Mds:                       Not affected
Vulnerability Meltdown:                  Not affected
Vulnerability Mmio stale data:           Not affected
Vulnerability Reg file data sampling:    Not affected
Vulnerability Retbleed:                  Not affected
Vulnerability Spec rstack overflow:      Not affected
Vulnerability Spec store bypass:         Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:                Mitigation; __user pointer sanitization
Vulnerability Spectre v2:                Mitigation; CSV2, BHB
Vulnerability Srbds:                     Not affected
Vulnerability Tsa:                       Not affected
Vulnerability Tsx async abort:           Not affected
Vulnerability Vmscape:                   Not affected

Comparing schema_caching-01-21554 (94b3e6f) to 754e113 (merge-base) diff using: clickbench_partitioned
Results will be posted here when complete


File an issue against this benchmark runner

@adriangbot

Copy link
Copy Markdown

🤖 Benchmark completed (GKE) | trigger

Instance: c4a-highmem-16 (12 vCPU / 65 GiB)

CPU Details (lscpu)
Architecture:                            aarch64
CPU op-mode(s):                          64-bit
Byte Order:                              Little Endian
CPU(s):                                  16
On-line CPU(s) list:                     0-15
Vendor ID:                               ARM
Model name:                              Neoverse-V2
Model:                                   1
Thread(s) per core:                      1
Core(s) per cluster:                     16
Socket(s):                               -
Cluster(s):                              1
Stepping:                                r0p1
BogoMIPS:                                2000.00
Flags:                                   fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm jscvt fcma lrcpc dcpop sha3 sm3 sm4 asimddp sha512 sve asimdfhm dit uscat ilrcpc flagm sb paca pacg dcpodp sve2 sveaes svepmull svebitperm svesha3 svesm4 flagm2 frint svei8mm svebf16 i8mm bf16 dgh rng bti
L1d cache:                               1 MiB (16 instances)
L1i cache:                               1 MiB (16 instances)
L2 cache:                                32 MiB (16 instances)
L3 cache:                                80 MiB (1 instance)
NUMA node(s):                            1
NUMA node0 CPU(s):                       0-15
Vulnerability Gather data sampling:      Not affected
Vulnerability Indirect target selection: Not affected
Vulnerability Itlb multihit:             Not affected
Vulnerability L1tf:                      Not affected
Vulnerability Mds:                       Not affected
Vulnerability Meltdown:                  Not affected
Vulnerability Mmio stale data:           Not affected
Vulnerability Reg file data sampling:    Not affected
Vulnerability Retbleed:                  Not affected
Vulnerability Spec rstack overflow:      Not affected
Vulnerability Spec store bypass:         Mitigation; Speculative Store Bypass disabled via prctl
Vulnerability Spectre v1:                Mitigation; __user pointer sanitization
Vulnerability Spectre v2:                Mitigation; CSV2, BHB
Vulnerability Srbds:                     Not affected
Vulnerability Tsa:                       Not affected
Vulnerability Tsx async abort:           Not affected
Vulnerability Vmscape:                   Not affected
Details

Comparing HEAD and schema_caching-01-21554
--------------------
Benchmark clickbench_partitioned.json
--------------------
┏━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┓
┃ Query     ┃                                  HEAD ┃               schema_caching-01-21554 ┃        Change ┃
┡━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━┩
│ QQuery 0  │          1.22 / 4.10 ±5.65 / 15.40 ms │          1.23 / 3.88 ±5.27 / 14.41 ms │ +1.06x faster │
│ QQuery 1  │        12.74 / 13.01 ±0.14 / 13.15 ms │        13.64 / 13.89 ±0.16 / 14.08 ms │  1.07x slower │
│ QQuery 2  │        36.11 / 36.61 ±0.38 / 37.20 ms │        36.96 / 37.29 ±0.20 / 37.52 ms │     no change │
│ QQuery 3  │        30.58 / 31.35 ±0.63 / 32.29 ms │        30.59 / 31.12 ±0.36 / 31.68 ms │     no change │
│ QQuery 4  │     222.04 / 224.14 ±2.12 / 227.69 ms │     220.72 / 224.73 ±2.26 / 227.47 ms │     no change │
│ QQuery 5  │     268.90 / 270.61 ±1.24 / 272.39 ms │     269.44 / 273.74 ±5.20 / 283.36 ms │     no change │
│ QQuery 6  │           1.29 / 1.46 ±0.25 / 1.95 ms │           1.27 / 1.42 ±0.23 / 1.87 ms │     no change │
│ QQuery 7  │        13.82 / 13.96 ±0.09 / 14.06 ms │        14.80 / 14.93 ±0.14 / 15.18 ms │  1.07x slower │
│ QQuery 8  │     324.54 / 326.24 ±1.40 / 328.72 ms │     323.47 / 326.58 ±2.32 / 329.82 ms │     no change │
│ QQuery 9  │     449.11 / 458.11 ±6.78 / 469.46 ms │     451.30 / 458.64 ±5.24 / 465.99 ms │     no change │
│ QQuery 10 │        69.72 / 70.41 ±0.80 / 71.94 ms │        70.75 / 72.01 ±1.13 / 73.95 ms │     no change │
│ QQuery 11 │        81.43 / 82.03 ±0.51 / 82.69 ms │        83.95 / 84.82 ±0.70 / 86.02 ms │     no change │
│ QQuery 12 │     266.98 / 269.59 ±2.18 / 273.01 ms │     266.28 / 269.44 ±2.74 / 273.27 ms │     no change │
│ QQuery 13 │     361.43 / 372.37 ±9.06 / 388.44 ms │     363.92 / 371.79 ±9.25 / 389.92 ms │     no change │
│ QQuery 14 │     283.48 / 287.40 ±4.62 / 296.20 ms │     282.12 / 289.27 ±4.22 / 294.45 ms │     no change │
│ QQuery 15 │     271.10 / 277.24 ±4.25 / 282.78 ms │     271.71 / 280.63 ±6.04 / 287.61 ms │     no change │
│ QQuery 16 │     611.68 / 617.51 ±8.12 / 633.58 ms │     610.73 / 617.01 ±7.31 / 630.90 ms │     no change │
│ QQuery 17 │     618.67 / 624.29 ±5.26 / 633.97 ms │    618.21 / 633.51 ±13.35 / 654.85 ms │     no change │
│ QQuery 18 │ 1244.70 / 1271.45 ±15.59 / 1293.42 ms │ 1251.39 / 1265.24 ±18.59 / 1299.84 ms │     no change │
│ QQuery 19 │        27.92 / 28.96 ±1.70 / 32.34 ms │        28.40 / 31.36 ±5.13 / 41.61 ms │  1.08x slower │
│ QQuery 20 │    512.12 / 530.09 ±16.78 / 554.00 ms │    516.77 / 526.39 ±11.18 / 547.87 ms │     no change │
│ QQuery 21 │     513.98 / 519.37 ±3.75 / 525.35 ms │    516.96 / 529.90 ±10.32 / 548.20 ms │     no change │
│ QQuery 22 │     979.94 / 987.23 ±4.63 / 992.56 ms │    984.34 / 992.92 ±8.59 / 1005.06 ms │     no change │
│ QQuery 23 │ 3036.16 / 3072.26 ±28.61 / 3104.99 ms │ 3078.76 / 3121.63 ±47.24 / 3210.42 ms │     no change │
│ QQuery 24 │      40.99 / 56.83 ±25.44 / 107.03 ms │        42.52 / 43.10 ±0.69 / 44.42 ms │ +1.32x faster │
│ QQuery 25 │     111.29 / 112.94 ±2.01 / 116.89 ms │     112.47 / 113.19 ±0.76 / 114.26 ms │     no change │
│ QQuery 26 │        41.31 / 41.82 ±0.60 / 42.91 ms │        41.70 / 42.16 ±0.64 / 43.41 ms │     no change │
│ QQuery 27 │     506.05 / 516.02 ±5.68 / 521.33 ms │     523.34 / 529.46 ±5.52 / 536.00 ms │     no change │
│ QQuery 28 │ 2869.83 / 2890.41 ±18.79 / 2925.29 ms │ 2887.16 / 2913.85 ±24.91 / 2949.24 ms │     no change │
│ QQuery 29 │      41.12 / 54.77 ±26.18 / 107.11 ms │        41.35 / 44.96 ±6.53 / 58.01 ms │ +1.22x faster │
│ QQuery 30 │    297.69 / 308.33 ±12.93 / 332.89 ms │    302.63 / 314.64 ±13.25 / 339.11 ms │     no change │
│ QQuery 31 │     281.01 / 291.12 ±9.26 / 306.82 ms │    281.26 / 296.85 ±14.49 / 319.80 ms │     no change │
│ QQuery 32 │   950.04 / 986.03 ±24.49 / 1021.89 ms │   937.90 / 965.38 ±29.86 / 1020.56 ms │     no change │
│ QQuery 33 │ 1437.33 / 1472.54 ±32.97 / 1528.01 ms │ 1441.27 / 1460.48 ±16.15 / 1482.74 ms │     no change │
│ QQuery 34 │ 1440.22 / 1486.11 ±26.29 / 1510.69 ms │ 1454.02 / 1475.52 ±22.83 / 1510.68 ms │     no change │
│ QQuery 35 │    275.50 / 296.45 ±27.30 / 349.71 ms │    275.93 / 290.55 ±15.02 / 317.91 ms │     no change │
│ QQuery 36 │        69.14 / 75.44 ±8.21 / 90.88 ms │        66.71 / 75.02 ±5.60 / 81.70 ms │     no change │
│ QQuery 37 │        35.38 / 39.74 ±7.34 / 54.39 ms │        35.35 / 36.71 ±1.50 / 39.59 ms │ +1.08x faster │
│ QQuery 38 │        43.37 / 45.71 ±2.41 / 50.11 ms │        40.05 / 46.03 ±4.28 / 51.73 ms │     no change │
│ QQuery 39 │     141.91 / 149.88 ±7.15 / 161.09 ms │     137.31 / 152.00 ±9.92 / 166.34 ms │     no change │
│ QQuery 40 │        14.31 / 16.16 ±2.96 / 22.07 ms │        14.18 / 14.79 ±0.37 / 15.22 ms │ +1.09x faster │
│ QQuery 41 │        13.56 / 13.75 ±0.18 / 14.09 ms │        13.95 / 17.97 ±5.19 / 27.12 ms │  1.31x slower │
│ QQuery 42 │        13.19 / 13.27 ±0.08 / 13.37 ms │        13.19 / 13.47 ±0.16 / 13.65 ms │     no change │
└───────────┴───────────────────────────────────────┴───────────────────────────────────────┴───────────────┘
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━┓
┃ Benchmark Summary                      ┃            ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━┩
│ Total Time (HEAD)                      │ 19257.09ms │
│ Total Time (schema_caching-01-21554)   │ 19318.24ms │
│ Average Time (HEAD)                    │   447.84ms │
│ Average Time (schema_caching-01-21554) │   449.26ms │
│ Queries Faster                         │          5 │
│ Queries Slower                         │          4 │
│ Queries with No Change                 │         34 │
│ Queries with Failure                   │          0 │
└────────────────────────────────────────┴────────────┘

Resource Usage

clickbench_partitioned — base (merge-base)

Metric Value
Wall time 100.0s
Peak memory 11.4 GiB
Avg memory 4.4 GiB
CPU user 988.0s
CPU sys 67.8s
Peak spill 0 B

clickbench_partitioned — branch

Metric Value
Wall time 100.0s
Peak memory 11.4 GiB
Avg memory 4.0 GiB
CPU user 991.4s
CPU sys 67.6s
Peak spill 0 B

File an issue against this benchmark runner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

datasource Changes to the datasource crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants