Skip to content

Conversation

@gatesn
Copy link
Contributor

@gatesn gatesn commented Dec 8, 2025

We eventually need to port all of our execution logic over to executing using Vectors + VortexSession.
We can release this new API prior to deprecating the existing one.
We should figure out what this API should be.
Once the full operators change has finished, we should be able to pull this module out into vortex-arrow.

Signed-off-by: Nicholas Gates <nick@nickgates.com>
use crate::arrays::VarBinVTable;

/// Trait for executing a Vortex array to produce an Arrow array.
pub trait ArrowArrayExecutor {
Copy link
Contributor

Choose a reason for hiding this comment

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

Is the use of "executor" here 100% necessary? I think ArrowConverter or ArrowConvertible makes more sense to me and then the trait function would just be convert. More of a nit, so feel free to ignore.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No not necessarily. I agree the name isn't great, but we want to move towards making it such that the only way to get data out of a Vortex array is via some form of "execution".

By default this turns an array into a vector, but we have MaskExecutor that checks for constant true/false (and should also check for run-end in order to construct slices), and obviously ArrowExecutor checks for lots of things.

Maybe exporter is a better name? Or maybe just into_arrow...

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Dec 12, 2025

Deploying vortex-bench with  Cloudflare Pages  Cloudflare Pages

Latest commit: d8d129a
Status: ✅  Deploy successful!
Preview URL: https://672ad3a8.vortex-93b.pages.dev
Branch Preview URL: https://ngates-arrow-executor.vortex-93b.pages.dev

View logs

Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@codspeed-hq
Copy link

codspeed-hq bot commented Dec 12, 2025

CodSpeed Performance Report

Merging #5647 will improve performances by 17.69%

Comparing ngates/arrow-executor (08a96bf) with develop (50594d4)

Summary

⚡ 19 improvements
✅ 1237 untouched
⏩ 621 skipped1

Benchmarks breakdown

Benchmark BASE HEAD Change
bench_dict_mask[(0.01, 0.5)] 1.2 ms 1 ms +11.76%
bench_dict_mask[(0.01, 0.01)] 1.2 ms 1 ms +11.8%
bench_dict_mask[(0.01, 0.9)] 1.2 ms 1 ms +11.67%
bench_dict_mask[(0.1, 0.1)] 1.2 ms 1 ms +11.71%
bench_dict_mask[(0.5, 0.01)] 1.2 ms 1 ms +11.8%
bench_dict_mask[(0.01, 0.1)] 1.2 ms 1 ms +11.77%
bench_dict_mask[(0.9, 0.01)] 1.2 ms 1 ms +11.83%
bench_dict_mask[(0.5, 0.1)] 1.2 ms 1 ms +11.76%
bench_dict_mask[(0.1, 0.5)] 1.2 ms 1 ms +11.84%
bench_dict_mask[(0.9, 0.1)] 1.2 ms 1 ms +11.8%
bench_dict_mask[(0.9, 0.5)] 1.2 ms 1 ms +11.8%
bench_dict_mask[(0.5, 0.9)] 1.2 ms 1 ms +11.72%
bench_dict_mask[(0.9, 0.9)] 1.2 ms 1.1 ms +11.38%
bench_dict_mask[(0.5, 0.5)] 1.2 ms 1 ms +11.83%
bench_dict_mask[(0.1, 0.01)] 1.2 ms 1 ms +11.84%
bench_dict_mask[(0.1, 0.9)] 1.2 ms 1 ms +11.71%
old_bp_prim_test_between[i64, 32768] 318.7 µs 270.8 µs +17.69%
old_bp_prim_test_between[i32, 32768] 258.7 µs 228.5 µs +13.22%
old_bp_prim_test_between[i64, 16384] 205.2 µs 183.1 µs +12.08%

Footnotes

  1. 621 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.

Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@gatesn gatesn changed the title [wip] Arrow Executor Arrow Executor Dec 14, 2025
@gatesn gatesn marked this pull request as ready for review December 14, 2025 14:03
@gatesn gatesn added the changelog/feature A new feature label Dec 14, 2025
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@gatesn gatesn enabled auto-merge (squash) December 14, 2025 14:07
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@codecov
Copy link

codecov bot commented Dec 14, 2025

Codecov Report

❌ Patch coverage is 12.26533% with 701 lines in your changes missing coverage. Please review.
✅ Project coverage is 82.64%. Comparing base (5c5f7d1) to head (08a96bf).
⚠️ Report is 4 commits behind head on develop.

Files with missing lines Patch % Lines
vortex-array/src/arrow/executor/list.rs 0.00% 89 Missing ⚠️
vortex-array/src/arrow/executor/temporal.rs 0.00% 63 Missing ⚠️
vortex-array/src/arrow/executor/mod.rs 0.00% 58 Missing ⚠️
vortex-array/src/arrow/executor/list_view.rs 0.00% 57 Missing ⚠️
vortex-array/src/arrow/executor/dictionary.rs 0.00% 51 Missing ⚠️
vortex-array/src/arrow/executor/struct_.rs 0.00% 50 Missing ⚠️
vortex-vector/src/vector.rs 0.00% 45 Missing ⚠️
vortex-array/src/arrow/executor/fixed_size_list.rs 0.00% 44 Missing ⚠️
vortex-compute/src/cast/dvector.rs 0.00% 36 Missing ⚠️
vortex-array/src/arrow/executor/byte.rs 0.00% 32 Missing ⚠️
... and 18 more

☔ 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.

Copy link
Contributor

@connortsui20 connortsui20 left a comment

Choose a reason for hiding this comment

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

Just a few things.

I think there's a lot of other stuff that can be cleaned up but since we're on time pressure let's get this over the line.

Signed-off-by: Nicholas Gates <nick@nickgates.com>
Comment on lines +39 to +45
// NOTE(ngates): we assume that a cast operation will produce the narrowest possible type that
// fits the requested precision.
let fake_precision = precision.max(N::MAX_PRECISION);
let array = array.cast(DType::Decimal(
DecimalDType::new(fake_precision, scale),
Nullability::Nullable,
))?;
Copy link
Contributor

Choose a reason for hiding this comment

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

We document the cast to do this

Signed-off-by: Nicholas Gates <nick@nickgates.com>
@gatesn gatesn enabled auto-merge (squash) December 15, 2025 11:08
@gatesn gatesn merged commit 1058e6d into develop Dec 15, 2025
48 checks passed
@gatesn gatesn deleted the ngates/arrow-executor branch December 15, 2025 11:12
paultiq pushed a commit to paultiq/vortex that referenced this pull request Dec 17, 2025
We eventually need to port all of our execution logic over to executing
using Vectors + VortexSession.
We can release this new API prior to deprecating the existing one.
We should figure out what this API should be.
Once the full operators change has finished, we should be able to pull
this module out into vortex-arrow.

---------

Signed-off-by: Nicholas Gates <nick@nickgates.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/feature A new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants