diff --git a/benches/benches/bevy_ecs/components/mod.rs b/benches/benches/bevy_ecs/components/mod.rs index f696d33870..e77e23d730 100644 --- a/benches/benches/bevy_ecs/components/mod.rs +++ b/benches/benches/bevy_ecs/components/mod.rs @@ -1,11 +1,11 @@ use criterion::*; +mod add_remove; mod add_remove_big_sparse_set; mod add_remove_big_table; mod add_remove_sparse_set; mod add_remove_table; mod add_remove_very_big_table; -mod add_remove; mod archetype_updates; mod insert_simple; mod insert_simple_unbatched; diff --git a/benches/benches/bevy_ecs/fragmentation/mod.rs b/benches/benches/bevy_ecs/fragmentation/mod.rs index ae44aae4a4..0f9396a409 100644 --- a/benches/benches/bevy_ecs/fragmentation/mod.rs +++ b/benches/benches/bevy_ecs/fragmentation/mod.rs @@ -1,8 +1,8 @@ use bevy_ecs::prelude::*; use bevy_ecs::system::SystemState; +use core::hint::black_box; use criterion::*; use glam::*; -use core::hint::black_box; criterion_group!(fragmentation_benches, iter_frag_empty); diff --git a/benches/benches/bevy_ecs/main.rs b/benches/benches/bevy_ecs/main.rs index b60492b41f..7c1c8684ce 100644 --- a/benches/benches/bevy_ecs/main.rs +++ b/benches/benches/bevy_ecs/main.rs @@ -1,4 +1,7 @@ -#![expect(dead_code, reason = "Many fields are unused/unread as they are just for benchmarking purposes.")] +#![expect( + dead_code, + reason = "Many fields are unused/unread as they are just for benchmarking purposes." +)] use criterion::criterion_main; diff --git a/benches/benches/bevy_math/main.rs b/benches/benches/bevy_math/main.rs index 56f2904bcd..7b84b6d60f 100644 --- a/benches/benches/bevy_math/main.rs +++ b/benches/benches/bevy_math/main.rs @@ -2,6 +2,4 @@ use criterion::criterion_main; mod bezier; -criterion_main!( - bezier::benches, -); +criterion_main!(bezier::benches); diff --git a/benches/benches/bevy_picking/main.rs b/benches/benches/bevy_picking/main.rs index c9177c0080..d3939d82ee 100644 --- a/benches/benches/bevy_picking/main.rs +++ b/benches/benches/bevy_picking/main.rs @@ -2,6 +2,4 @@ use criterion::criterion_main; mod ray_mesh_intersection; -criterion_main!( - ray_mesh_intersection::benches, -); +criterion_main!(ray_mesh_intersection::benches); diff --git a/benches/benches/bevy_reflect/list.rs b/benches/benches/bevy_reflect/list.rs index c02205e3f9..d9c92dd03e 100644 --- a/benches/benches/bevy_reflect/list.rs +++ b/benches/benches/bevy_reflect/list.rs @@ -2,8 +2,8 @@ use core::{iter, time::Duration}; use bevy_reflect::{DynamicList, List}; use criterion::{ - black_box, criterion_group, measurement::Measurement, BatchSize, - BenchmarkGroup, BenchmarkId, Criterion, Throughput, + black_box, criterion_group, measurement::Measurement, BatchSize, BenchmarkGroup, BenchmarkId, + Criterion, Throughput, }; criterion_group!( diff --git a/benches/benches/bevy_reflect/map.rs b/benches/benches/bevy_reflect/map.rs index 8857cb9fac..69963316b6 100644 --- a/benches/benches/bevy_reflect/map.rs +++ b/benches/benches/bevy_reflect/map.rs @@ -3,8 +3,8 @@ use core::{fmt::Write, iter, time::Duration}; use bevy_reflect::{DynamicMap, Map}; use bevy_utils::HashMap; use criterion::{ - black_box, criterion_group, measurement::Measurement, BatchSize, - BenchmarkGroup, BenchmarkId, Criterion, Throughput, + black_box, criterion_group, measurement::Measurement, BatchSize, BenchmarkGroup, BenchmarkId, + Criterion, Throughput, }; criterion_group!( diff --git a/benches/benches/bevy_reflect/path.rs b/benches/benches/bevy_reflect/path.rs index 576884191d..fa5582982b 100644 --- a/benches/benches/bevy_reflect/path.rs +++ b/benches/benches/bevy_reflect/path.rs @@ -1,9 +1,7 @@ use core::{fmt::Write, str, time::Duration}; use bevy_reflect::ParsedPath; -use criterion::{ - black_box, criterion_group, BatchSize, BenchmarkId, Criterion, Throughput, -}; +use criterion::{black_box, criterion_group, BatchSize, BenchmarkId, Criterion, Throughput}; use rand::{distributions::Uniform, Rng, SeedableRng}; use rand_chacha::ChaCha8Rng; diff --git a/benches/benches/bevy_reflect/struct.rs b/benches/benches/bevy_reflect/struct.rs index 9b73a1d850..5fc3a462c5 100644 --- a/benches/benches/bevy_reflect/struct.rs +++ b/benches/benches/bevy_reflect/struct.rs @@ -1,9 +1,7 @@ use core::time::Duration; use bevy_reflect::{DynamicStruct, GetField, PartialReflect, Reflect, Struct}; -use criterion::{ - black_box, criterion_group, BatchSize, BenchmarkId, Criterion, Throughput, -}; +use criterion::{black_box, criterion_group, BatchSize, BenchmarkId, Criterion, Throughput}; criterion_group!( benches, diff --git a/benches/benches/bevy_render/main.rs b/benches/benches/bevy_render/main.rs index e3987123eb..7a369bc905 100644 --- a/benches/benches/bevy_render/main.rs +++ b/benches/benches/bevy_render/main.rs @@ -3,7 +3,4 @@ use criterion::criterion_main; mod render_layers; mod torus; -criterion_main!( - render_layers::benches, - torus::benches, -); +criterion_main!(render_layers::benches, torus::benches); diff --git a/benches/benches/bevy_render/render_layers.rs b/benches/benches/bevy_render/render_layers.rs index 409079f202..42dd5356b5 100644 --- a/benches/benches/bevy_render/render_layers.rs +++ b/benches/benches/bevy_render/render_layers.rs @@ -6,13 +6,8 @@ fn render_layers(c: &mut Criterion) { c.bench_function("layers_intersect", |b| { let layer_a = RenderLayers::layer(1).with(2); let layer_b = RenderLayers::layer(1); - b.iter(|| { - black_box(layer_a.intersects(&layer_b)) - }); + b.iter(|| black_box(layer_a.intersects(&layer_b))); }); } -criterion_group!( - benches, - render_layers, -); +criterion_group!(benches, render_layers);