Skip to content

chore: update dependencies - #78

Open
jvdd wants to merge 3 commits into
mainfrom
chore/update-dependencies
Open

chore: update dependencies#78
jvdd wants to merge 3 commits into
mainfrom
chore/update-dependencies

Conversation

@jvdd

@jvdd jvdd commented May 31, 2026

Copy link
Copy Markdown
Owner

The wasm32-unknown-unknown --all-features build fails to compile:
arrow and arrow2 pull in ahash -> getrandom, and getrandom >=0.3
deliberately errors on wasm32-unknown-unknown unless the final binary
selects a randomness backend (e.g. --cfg getrandom_backend="wasm_js").

argminmax uses no randomness of its own, so this backend choice is a
downstream/binary-level decision that a library cannot make. Apache Arrow
on bare wasm32-unknown-unknown is not a supported scenario.

Split the wasm build to compile every argminmax-owned feature
(nightly_simd, float, half, ndarray) while omitting the arrow/arrow2
integrations. All other targets keep full --all-features coverage.


This pull request updates several dependencies to more recent versions and refactors the random array generation utilities in dev_utils to improve compatibility and reliability, particularly for floating-point types. The changes ensure better support for the latest versions of crates and address issues with random number generation for various numeric types.

Dependency updates:

  • Updated versions of several dependencies in Cargo.toml and dev_utils/Cargo.toml, including half (2.6 → 2.7), ndarray (0.16.1 → 0.17), rand (0.9 → 0.10), rstest (0.25 → 0.26), codspeed-criterion-compat (2.10.1 → 4.7.0), and criterion (0.5.1 → 0.8.2). [1] [2] [3]

Random array generation refactor:

  • Refactored the SampleUniformFullRange trait and its implementations to use the new rand API and to generate random arrays for integer and floating-point types more reliably. For floats, random integers are generated and then safely transmuted to floats to avoid range overflow issues. [1] [2] [3] [4]
  • Updated imports and usage of the rand crate to reflect API changes and to use ThreadRng and RngExt as appropriate.

These changes improve compatibility with the latest crate versions and make random array generation for tests and benchmarks more robust.

@codspeed-hq

codspeed-hq Bot commented May 31, 2026

Copy link
Copy Markdown

Merging this PR will improve performance by 2.54%

⚠️ Different runtime environments detected

Some benchmarks with significant performance changes were compared across different runtime environments,
which may affect the accuracy of the results.

Open the report in CodSpeed to investigate

#### 🎉 Hooray! `codspeed-rust` just leveled up to 4.7.0!

A heads-up, this is a breaking change and it might affect your current performance baseline a bit. But here's the exciting part - it's packed with new, cool features and promises improved result stability 🥳!
Curious about what's new? Visit our releases page to delve into all the awesome details about this new version.

⚡ 8 improved benchmarks
❌ 2 regressed benchmarks
✅ 158 untouched benchmarks

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Benchmark BASE HEAD Efficiency
scalar_f64_argmax_rn 714.8 µs 686.3 µs +4.15%
scalar_f64_argminmax_in 757.8 µs 686.6 µs +10.37%
scalar_f32_argminmax_rn 499.8 µs 585 µs -14.58%
scalar_f64_argmin_rn 714.8 µs 686.3 µs +4.15%
scalar_f64_argminmax_rn 686.4 µs 771.7 µs -11.06%
scalar_f32_argmin_rn 528.1 µs 499.7 µs +5.69%
scalar_f16_argmin_rn 577.1 µs 548.6 µs +5.2%
scalar_f32_argminmax_in 571 µs 499.9 µs +14.24%
scalar_f32_argmax_rn 528.2 µs 499.7 µs +5.7%
scalar_f16_argmax_rn 577.2 µs 548.6 µs +5.2%

Tip

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


Comparing chore/update-dependencies (0ecbab5) with main (ac45079)

Open in CodSpeed

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