File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -350,6 +350,22 @@ TEST(Benchmark, DestroyMany) {
350350 timer.elapsed ();
351351}
352352
353+ TEST (Benchmark, DestroyManyMulti) {
354+ entt::registry registry;
355+ std::vector<entt::entity> entities (1000000 );
356+ auto view = registry.view <position>();
357+
358+ std::cout << " Destroying 1000000 entities at once, multiple components" << std::endl;
359+
360+ registry.create (entities.begin (), entities.end ());
361+ registry.insert <position>(entities.begin (), entities.end ());
362+ registry.insert <velocity>(entities.begin (), entities.end ());
363+
364+ timer timer;
365+ registry.destroy (view.begin (), view.end ());
366+ timer.elapsed ();
367+ }
368+
353369TEST (Benchmark, IterateSingleComponent1M) {
354370 entt::registry registry;
355371
You can’t perform that action at this time.
0 commit comments