Skip to content

Conversation

@joseph-isaacs
Copy link
Contributor

No description provided.

Signed-off-by: Joe Isaacs <[email protected]>
@codspeed-hq
Copy link

codspeed-hq bot commented Nov 21, 2025

CodSpeed Performance Report

Merging #5443 will degrade performances by 38.86%

Comparing ji/alp-pushddown (81eaec2) with develop (f52dbf0)

Summary

⚡ 5 improvements
❌ 6 regressions
✅ 1504 untouched
🆕 7 new
⏩ 91 skipped1

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
🆕 decompress[("alp_for_bp_f64", 0x45b9120)] N/A 29.8 ms N/A
🆕 decompress[("datetime_for_bp", 0x45bbbf0)] N/A 41.7 ms N/A
🆕 decompress[("dict_fsst_varbin_bp_string", 0x45bb070)] N/A 76.3 ms N/A
🆕 decompress[("dict_fsst_varbin_string", 0x45bacf0)] N/A 76.3 ms N/A
🆕 decompress[("dict_varbinview_string", 0x45b9b40)] N/A 75.6 ms N/A
🆕 decompress[("for_bp_u64", 0x45b89d0)] N/A 2.5 ms N/A
🆕 decompress[("runend_for_bp_u32", 0x45b9ed0)] N/A 2.1 ms N/A
batch[86016] 662.8 µs 586.8 µs +12.95%
in_place_batch[1024] 5.6 µs 4.6 µs +20.19%
in_place_batch[73728] 234.2 µs 280.4 µs -16.47%
in_place_pipeline[100352] 153.6 µs 128.8 µs +19.27%
in_place_pipeline[73728] 95.5 µs 114.4 µs -16.49%
in_place_pipeline[86016] 110.9 µs 133 µs -16.58%
pipeline[86016] 114.9 µs 136 µs -15.51%
pipeline_extra_copy[100352] 132.8 µs 158.6 µs -16.24%
pipeline_extra_copy[262144] 402.4 µs 335.2 µs +20.06%
pipeline_extra_copy[65536] 106.1 µs 89.3 µs +18.85%
verify_all_methods[16384] 23.1 ms 37.8 ms -38.86%

Footnotes

  1. 91 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@joseph-isaacs joseph-isaacs changed the title wip wip: alp decode pushdown Nov 21, 2025
@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

❌ Patch coverage is 95.20295% with 13 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.73%. Comparing base (f52dbf0) to head (81eaec2).

Files with missing lines Patch % Lines
encodings/alp/src/alp/compute/expr_pushdown.rs 94.22% 13 Missing ⚠️

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: Joe Isaacs <[email protected]>
@joseph-isaacs joseph-isaacs changed the title wip: alp decode pushdown perf[alp]: alp decode pushdown Nov 21, 2025
@joseph-isaacs joseph-isaacs changed the title perf[alp]: alp decode pushdown perf[alp]: compare |- alp pushdown Nov 21, 2025
@joseph-isaacs joseph-isaacs added the feature Release label indicating a new feature or request label Nov 21, 2025
@joseph-isaacs joseph-isaacs marked this pull request as ready for review November 21, 2025 16:34
Signed-off-by: Joe Isaacs <[email protected]>
Signed-off-by: Joe Isaacs <[email protected]>
@joseph-isaacs joseph-isaacs enabled auto-merge (squash) November 21, 2025 16:55
Copy link
Contributor

@gatesn gatesn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is... kinda nice??

I guess there's a lot more stuff to pull apart than just the eager compute function.
I wonder if after writing a few more of these there are certain patterns we have to extract sub-expressions out of an ExprArray and push them through another array?

EncodingRef::new_ref(vortex_zstd::ZstdEncoding.as_ref()),
]);

register_alp_rules(&session.arrays())
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should just have vortex_alp::initialize(session)

So there's a single entry-point for the crate to register all its things (including its encodings!)

mod nan_count;
mod take;

pub use expr_pushdown::ALPExprPushdownRule;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why pub?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

vortex_alp::initialize(session)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pub(crate) at most ?

mod array;
mod compress;
mod compute;
pub mod compute;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why pub?

}

// Convert to compute operator
let compute_op = match operator {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels like this does the same logic as the matches! macro on line 62?

let literal_value = literal_expr.as_::<Literal>().data().clone();

// Don't optimize nullable comparisons
if literal_value.dtype().is_nullable() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm 90% sure this is covered by the null checks above

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

me too but also only 90

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Nov 24, 2025

Deploying vortex-bench with  Cloudflare Pages  Cloudflare Pages

Latest commit: 81eaec2
Status: ✅  Deploy successful!
Preview URL: https://bfb9335d.vortex-93b.pages.dev
Branch Preview URL: https://ji-alp-pushddown.vortex-93b.pages.dev

View logs

@joseph-isaacs
Copy link
Contributor Author

Yep, I agree I just wanted to see what it would be like.

@joseph-isaacs
Copy link
Contributor Author

joseph-isaacs commented Nov 24, 2025

The other approach for scalar arrays. is to convert this into an expression and create a reduce_parent expr rule for alp($) > x

@joseph-isaacs joseph-isaacs marked this pull request as draft November 24, 2025 11:16
auto-merge was automatically disabled November 24, 2025 11:16

Pull request was converted to draft

Signed-off-by: Joe Isaacs <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature Release label indicating a new feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants