Skip to content

Commit

Permalink
chore(deps): bump rand from 0.8.5 to 0.9.0 (#317)
Browse files Browse the repository at this point in the history
Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matthijs Brobbel <[email protected]>
  • Loading branch information
dependabot[bot] and mbrobbel authored Jan 27, 2025
1 parent 1ba2de1 commit 5d8eb9c
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 26 deletions.
36 changes: 30 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ chrono = { version = "0.4.39", default-features = false, features = ["now"] }
criterion = { version = "0.5.1", default-features = false, features = [
"html_reports",
] }
rand = { version = "0.8.5", default-features = false, features = ["small_rng"] }
rand = { version = "0.9.0", default-features = false, features = ["small_rng"] }
rustversion = { version = "1.0.19", default-features = false }
parquet = { version = "54.0.0", default-features = false, features = ["arrow"] }
uuid = { version = "1.12.1", default-features = false }
Expand Down
4 changes: 2 additions & 2 deletions benches/narrow/bitmap/iter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ pub(super) fn bench(c: &mut Criterion) {
for size in [12345] {
for null_fraction in [0., 0.5, 1.] {
let input = (0..size)
.map(|_| rng.gen_bool(1. - null_fraction))
.map(|_| rng.random_bool(1. - null_fraction))
.collect::<Vec<_>>();
group.throughput(Throughput::Elements(size as u64));
group.bench_with_input(
Expand All @@ -33,7 +33,7 @@ pub(super) fn bench(c: &mut Criterion) {
for size in [12345] {
for null_fraction in [0., 0.5, 1.] {
let input = (0..size)
.map(|_| rng.gen_bool(1. - null_fraction))
.map(|_| rng.random_bool(1. - null_fraction))
.collect::<Vec<_>>();
let narrow_bitmap = Bitmap::<BoxBuffer>::from_iter(&input);
group.throughput(Throughput::Elements(size as u64));
Expand Down
2 changes: 1 addition & 1 deletion benches/narrow/versus/arrow/primitive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ where
for null_fraction in [0., 0.5, 1.] {
let input = (0..size)
.map(|v| num_traits::cast(v % max).unwrap())
.map(|v| rng.gen_bool(1. - null_fraction).then_some(v))
.map(|v| rng.random_bool(1. - null_fraction).then_some(v))
.collect::<Vec<Option<T::Native>>>();
group.throughput(criterion::Throughput::Elements(size as u64));
group.bench_with_input(
Expand Down
32 changes: 16 additions & 16 deletions examples/tpch_lineitem.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,23 +189,23 @@ fn make_native_row_oriented(size: usize) -> Vec<LineItem> {

(0..size)
.map(|_| LineItem {
l_orderkey: rng.gen_range(0..i64::MAX),
l_partkey: rng.gen_range(0..i64::MAX),
l_suppkey: rng.gen_range(0..i64::MAX),
l_linenumber: rng.gen_range(0..i64::MAX),
l_quantity: rng.gen_range(0f64..42f64),
l_extendedprice: rng.gen_range(0f64..1337f64),
l_discount: rng.gen_range(0f64..0.1),
l_tax: rng.gen_range(0f64..0.3),
l_returnflag: rng.gen_range(0..u8::MAX),
l_linestatus: rng.gen_range(0..u8::MAX),
l_shipdate: DateTime::from_timestamp_nanos(rng.gen_range(0..i64::MAX)),
l_commitdate: DateTime::from_timestamp_nanos(rng.gen_range(0..i64::MAX)),
l_receiptdate: DateTime::from_timestamp_nanos(rng.gen_range(0..i64::MAX)),
l_shipinstruct: [rng.gen_range(0..u8::MAX); 25],
l_shipmode: [rng.gen_range(0..u8::MAX); 10],
l_orderkey: rng.random_range(0..i64::MAX),
l_partkey: rng.random_range(0..i64::MAX),
l_suppkey: rng.random_range(0..i64::MAX),
l_linenumber: rng.random_range(0..i64::MAX),
l_quantity: rng.random_range(0f64..42f64),
l_extendedprice: rng.random_range(0f64..1337f64),
l_discount: rng.random_range(0f64..0.1),
l_tax: rng.random_range(0f64..0.3),
l_returnflag: rng.random_range(0..u8::MAX),
l_linestatus: rng.random_range(0..u8::MAX),
l_shipdate: DateTime::from_timestamp_nanos(rng.random_range(0..i64::MAX)),
l_commitdate: DateTime::from_timestamp_nanos(rng.random_range(0..i64::MAX)),
l_receiptdate: DateTime::from_timestamp_nanos(rng.random_range(0..i64::MAX)),
l_shipinstruct: [rng.random_range(0..u8::MAX); 25],
l_shipmode: [rng.random_range(0..u8::MAX); 10],
l_comment: String::from_iter(
(0..rng.gen_range(0..44)).map(|_| rng.gen_range('a'..='z')),
(0..rng.random_range(0..44)).map(|_| rng.random_range('a'..='z')),
),
})
.collect()
Expand Down

1 comment on commit 5d8eb9c

@mbrobbel
Copy link
Owner

Choose a reason for hiding this comment

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

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'narrow'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 2.

Benchmark suite Current: 5d8eb9c Previous: 1ba2de1 Ratio
FixedSizePrimitiveArray::<arrow_array::types::UInt16Type, true>::from_iter/narrow/1/65536 164846 ns/iter (± 1626) 69493 ns/iter (± 830) 2.37

This comment was automatically generated by workflow using github-action-benchmark.

CC: @mbrobbel

Please sign in to comment.