Skip to content

Compare primitive values through the shared RowFn executor - #10676

Draft
connortsui20 wants to merge 1 commit into
ct/row-fn-cleanup/fused-executionfrom
ct/row-fn-cleanup/primitive-compare
Draft

connortsui20 wants to merge 1 commit into
ct/row-fn-cleanup/fused-executionfrom
ct/row-fn-cleanup/primitive-compare

Conversation

@connortsui20

@connortsui20 connortsui20 commented Oct 21, 2026 •

Copy link
Copy Markdown
Member

Summary

Replaces the primitive comparison migration in #9979, using the shared executor from #10675. This PR depends on #10675, which is deferred until the independent foundations #10672, #10673, and #10674 merge.

Changes

The private row kernel selects the primitive type and comparison operator. The framework owns borrowed inputs, constant handling, strict validity, and packed Boolean output. Removes the primitive operand wrapper and handwritten primitive kernels while preserving the public Binary identity and Vortex's floating-point total ordering.

Native Graviton3 measurements showed regressions when this migration used only #10673. Removing only the fused-execution patch while keeping all three foundations also slowed the tested comparisons. The dependency on #10675 keeps that execution work available when this migration merges.

Existing comparison tests exercise the shared executor. The Vortex test suite was not run locally. Compiler investigation checks and focused native comparison measurements were run separately.

@connortsui20
connortsui20 added this pull request to stack #10677 October 21, 2026 15:10
@codspeed

codspeed Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Merging this PR will regress 6 benchmarks

4 warnings, 1 note

⚠️ Walltime results may be unreliable

Some benchmarks used the Walltime instrument outside CodSpeed Macro Runners, which can make the results inconsistent.

Learn more about Macro Runners

See affected benchmarks

⚠️ Unable to measure the execution of 1 benchmark

This benchmark measured no execution time, so its result is not comparable and counts as unchanged. This usually happens when the compiler removes the code under test.

Prevent compiler optimizations

See affected benchmarks

⚠️ 19 benchmarks are dominated by system calls

System calls cannot be simulated consistently and are left out of the measure. The reported value understates the real cost. Switch to the Walltime instrument to measure them.

Learn more about system calls

See affected benchmarks

⚠️ Base and head ran on different runner types

Some benchmarks with significant performance changes were compared across different runner types, so the changes might not come from the code. Run base and head on the same runner type, or use CodSpeed Macro Runners for more stable results.

Learn more about Macro Runners

Open the report in CodSpeed to investigate

ℹ️ 40 benchmarks have no flamegraph

The flamegraph wasn't generated: the symbols of the profiling trace could not be resolved, because no information about the language frames was collected.

See affected benchmarks

⚡ 15 improved benchmarks
❌ 6 regressed benchmarks
✅ 2387 untouched benchmarks
⏩ 12 skipped benchmarks1

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
❌ CPU Simulation random_i128[0.01] 4.4 µs 5.9 µs -26.11%
❌ CPU Simulation filter_powerlaw_by_mostly_false[250000] 136.9 µs 158.3 µs -13.53%
❌ CPU Simulation density_sweep_dense_runs[0.001] 53.8 µs 61.6 µs -12.62%
❌ CPU Simulation filter_random_by_mostly_false[250000] 162.4 µs 183.6 µs -11.54%
❌ CPU Simulation filter_powerlaw_by_power_law[250000] 165.7 µs 185.3 µs -10.56%
❌ CPU Simulation filter_random_by_power_law[250000] 165.5 µs 185 µs -10.56%
⚡ Walltime compare_f32_avx2 4.4 µs 2.5 µs +75.17%
⚡ Walltime compare_f32_avx512 3.4 µs 2.4 µs +42.35%
⚡ Walltime compare_u64_avx2 3.7 µs 2.8 µs +29.85%
⚡ Walltime compare_float_avx2 4.9 µs 3.8 µs +28.96%
⚡ Walltime compare_f32_neon 5.2 µs 4.3 µs +21.88%
⚡ Walltime filter_neon[8] 1.3 µs 1.1 µs +16.98%
⚡ Walltime threshold_neon[80] 4.6 µs 4 µs +15.39%
⚡ Walltime compare_int_eq_avx2 3.3 µs 2.8 µs +14.78%
⚡ Walltime compare_int_constant_avx2 2.7 µs 2.4 µs +13.63%
⚡ Walltime compare_int_avx2 3.2 µs 2.8 µs +13.37%
⚡ CPU Simulation test_repeated_scan_filter[int] 2.7 ms 2.4 ms +13.34%
⚡ CPU Simulation test_scan_filter_to_arrow_array[int] 2.8 ms 2.4 ms +13.31%
⚡ Walltime compare_int_constant_neon 3.8 µs 3.4 µs +12.57%
⚡ Walltime compare_int_nullable_avx2 3.6 µs 3.2 µs +12.17%
... ... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing ct/row-fn-cleanup/primitive-compare (b837021) with ct/row-fn-cleanup/fused-execution (5cbf00a)

Open in CodSpeed

Footnotes

  1. 12 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. ↩

@connortsui20
connortsui20 force-pushed the ct/row-fn-cleanup/primitive-compare branch from dee1a57 to 3a38935 Compare October 22, 2026 14:09
@connortsui20
connortsui20 removed this pull request from stack #10677 October 22, 2026 14:10
@connortsui20
connortsui20 changed the base branch from ct/row-fn-cleanup/fused-execution to ct/row-fn-cleanup/batch-inputs October 22, 2026 14:10
@connortsui20
connortsui20 added this pull request to stack #10695 October 22, 2026 14:11
@connortsui20
connortsui20 force-pushed the ct/row-fn-cleanup/primitive-compare branch from 3a38935 to 33ccf9b Compare October 22, 2026 14:49
@connortsui20 connortsui20 added the changelog/performance A performance improvement label Oct 22, 2026
@connortsui20
connortsui20 removed this pull request from stack #10695 October 22, 2026 15:12
Keep the primitive kernel focused on type and operator dispatch. Delegate borrowed inputs, constants, strict validity, and packed Boolean output to the lower stack layers while preserving Binary identity and floating-point total ordering.

Replaces the comparison migration in #9979.

Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
@connortsui20
connortsui20 force-pushed the ct/row-fn-cleanup/primitive-compare branch from 33ccf9b to b837021 Compare October 22, 2026 15:13
@connortsui20
connortsui20 changed the base branch from ct/row-fn-cleanup/batch-inputs to ct/row-fn-cleanup/fused-execution October 22, 2026 15:13
@connortsui20
connortsui20 added this pull request to stack #10697 October 22, 2026 15:13

This branch has not been deployed

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

Labels

changelog/performance A performance improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant