Skip to content

perf: O(n) dataset iteration#50

Merged
Beforerr merged 1 commit into
mainfrom
push-tynrvoymoxvx
Jun 11, 2026
Merged

perf: O(n) dataset iteration#50
Beforerr merged 1 commit into
mainfrom
push-tynrvoymoxvx

Conversation

@Beforerr

Copy link
Copy Markdown
Member

iterate rebuilt the full keys vector and re-scanned the VDR chain per
element (O(n^2-n^3) with allocations); walk the rVDR/zVDR chains
directly instead. length now comes from GDR counts, haskey from
find_vdr, and show reuses iteration instead of keys + lookup per
variable.

Co-Authored-By: Claude Fable 5 noreply@anthropic.com

iterate rebuilt the full keys vector and re-scanned the VDR chain per
element (O(n^2-n^3) with allocations); walk the rVDR/zVDR chains
directly instead. length now comes from GDR counts, haskey from
find_vdr, and show reuses iteration instead of keys + lookup per
variable.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@codecov

codecov Bot commented Jun 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@github-actions

Copy link
Copy Markdown
Contributor

Benchmark Results (Julia v1)

Time benchmarks
main 8fd612b... main / 8fd612b...
elx/full_load 0.118 ± 0.0043 ms 0.0358 ± 0.0022 ms 3.3 ± 0.23
elx/sum_array 2.89 ± 0.41 μs 2.94 ± 0.52 μs 0.983 ± 0.22
elx/sum_lazy 2.71 ± 1.1 μs 2.77 ± 1.2 μs 0.975 ± 0.58
elx/sum_var_access 3.3 ± 0.43 μs 3.26 ± 0.59 μs 1.01 ± 0.23
elx/var_access 0.281 ± 0.03 μs 0.301 ± 0.011 μs 0.934 ± 0.11
mms/full_load 25 ± 2.6 μs 20.9 ± 2.5 μs 1.2 ± 0.19
mms/sum_array 0.0969 ± 0.006 s 0.0973 ± 0.0059 s 0.995 ± 0.086
mms/sum_slice 3.61 ± 0.071 ms 3.61 ± 0.42 ms 1 ± 0.12
mms/sum_var_access 3.61 ± 0.056 ms 3.6 ± 0.43 ms 1 ± 0.12
mms/var_access 0.1 ± 0 μs 0.11 ± 0.01 μs 0.909 ± 0.083
time_to_load 0.135 ± 0.0018 s 0.141 ± 0.00097 s 0.961 ± 0.014
Memory benchmarks
main 8fd612b... main / 8fd612b...
elx/full_load 3.73 k allocs: 0.167 MB 0.246 k allocs: 27.9 kB 6.13
elx/sum_array 5 allocs: 27.7 kB 5 allocs: 27.7 kB 1
elx/sum_lazy 5 allocs: 27.7 kB 5 allocs: 27.7 kB 1
elx/sum_var_access 8 allocs: 28.1 kB 8 allocs: 28.1 kB 1
elx/var_access 2 allocs: 0.328 kB 2 allocs: 0.328 kB 1
mms/full_load 0.243 k allocs: 14.8 kB 0.071 k allocs: 7.2 kB 2.06
mms/sum_array 0.524 k allocs: 31.6 MB 0.524 k allocs: 31.6 MB 1
mms/sum_slice 0.045 k allocs: 1.29 MB 0.045 k allocs: 1.29 MB 1
mms/sum_var_access 0.045 k allocs: 1.29 MB 0.045 k allocs: 1.29 MB 1
mms/var_access 2 allocs: 0.328 kB 2 allocs: 0.328 kB 1
time_to_load 0.145 k allocs: 11 kB 0.145 k allocs: 11 kB 1

@Beforerr Beforerr merged commit 6903175 into main Jun 11, 2026
6 of 7 checks passed
@Beforerr Beforerr deleted the push-tynrvoymoxvx branch June 11, 2026 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant