Skip to content

Array VTables 5#7206

Open
gatesn wants to merge 13 commits intodevelopfrom
ngates/array-vtables-5
Open

Array VTables 5#7206
gatesn wants to merge 13 commits intodevelopfrom
ngates/array-vtables-5

Conversation

@gatesn
Copy link
Copy Markdown
Contributor

@gatesn gatesn commented Mar 30, 2026

See #7181

This is the big bang migration necessary to move from PrimitiveArray::new(..) -> PrimitiveArray over to Primitive::new(..) -> Array::<Primitive>.

gatesn added 2 commits March 29, 2026 16:59
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@gatesn gatesn changed the title Ngates/array vtables 5 Array VTables 5 Mar 30, 2026
Comment on lines +43 to +49
pub fn from_inner(array: V::Array) -> Self {
let vtable = V::vtable(&array).clone();
let dtype = V::dtype(&array).clone();
let len = V::len(&array);
let stats = V::stats(&array).clone();
// SAFETY: dtype and len are extracted from `array` via VTable methods.
unsafe { Self::from_parts_unchecked(vtable, dtype, len, array, stats) }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

we need an into parts!

gatesn added 2 commits March 30, 2026 11:41
Signed-off-by: Nicholas Gates <nick@nickgates.com>
Signed-off-by: Nicholas Gates <nick@nickgates.com>
gatesn added 3 commits March 30, 2026 12:57
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
Copy Markdown

codspeed-hq bot commented Mar 30, 2026

Merging this PR will degrade performance by 19.65%

⚡ 1 improved benchmark
❌ 17 regressed benchmarks
✅ 1088 untouched benchmarks
⏩ 1522 skipped benchmarks1

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

Performance Changes

Mode Benchmark BASE HEAD Efficiency
Simulation filter_all_true[250000] 10.1 µs 11.5 µs -11.47%
Simulation filter_all_true[100000] 10.1 µs 11.5 µs -11.47%
Simulation filter_all_true[10000] 10.1 µs 11.5 µs -11.47%
Simulation new_bp_prim_test_between[i64, 16384] 118.4 µs 142.4 µs -16.88%
Simulation new_bp_prim_test_between[i32, 32768] 149.2 µs 166.7 µs -10.53%
Simulation take_10k_random 209.1 µs 258.7 µs -19.19%
Simulation new_alp_prim_test_between[f32, 16384] 114.5 µs 131.2 µs -12.75%
Simulation old_bp_prim_test_between[i64, 16384] 298 µs 332.7 µs -10.4%
Simulation old_alp_prim_test_between[f64, 32768] 496.6 µs 561.8 µs -11.6%
Simulation new_alp_prim_test_between[f64, 16384] 131.2 µs 163.3 µs -19.65%
Simulation take_10k_contiguous 270.9 µs 321.8 µs -15.81%
Simulation old_alp_prim_test_between[f32, 32768] 398.3 µs 448.8 µs -11.26%
Simulation old_alp_prim_test_between[f64, 16384] 316 µs 351.1 µs -10.01%
Simulation old_bp_prim_test_between[i64, 32768] 473.5 µs 539.1 µs -12.16%
Simulation decompress_alp[f32, (1000, 0.01, 1.0)] 13.4 µs 14.9 µs -10.41%
Simulation decompress_alp[f32, (1000, 0.01, 0.95)] 13.5 µs 15 µs -10.17%
Simulation decompress_alp[f32, (1000, 0.0, 1.0)] 8.9 µs 10 µs -10.63%
Simulation rebuild_naive 266.1 µs 226.5 µs +17.49%

Comparing ngates/array-vtables-5 (41b3f52) with develop (e8cd130)

Open in CodSpeed

Footnotes

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

@gatesn gatesn added the changelog/break A breaking API change label Mar 30, 2026
Signed-off-by: Nicholas Gates <nick@nickgates.com>
@gatesn gatesn marked this pull request as ready for review March 30, 2026 13:49
@gatesn gatesn requested a review from joseph-isaacs March 30, 2026 13:49
gatesn added 5 commits March 30, 2026 16:20
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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/break A breaking API change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants