bevyengine / bevy

A refreshingly simple data-driven game engine built in Rust
https://bevyengine.org
Apache License 2.0
35.12k stars 3.45k forks source link

`Slab not found` error when running the `loading_screen` example. #14845

Open Olle-Lukowski opened 3 weeks ago

Olle-Lukowski commented 3 weeks ago

Bevy version

current main

Relevant system information

I am on the latest stable version of macOS, latest stable rust too.

AdapterInfo { name: "Apple M3", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }

What you did

Run cargo r --example loading_screen, then, press 1, wait for load, press 2, wait for load, press 1 again, crash!

What went wrong

On the bevy website this seems to work properly, not sure if its a regression in main, or a macOS specific issue...

Full output:

2024-08-21T08:15:31.197248Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "MacOS 14.6.1 ", kernel: "23.6.0", cpu: "Apple M3", core_count: "8", memory: "16.0 GiB" }
2024-08-21T08:15:31.277083Z  INFO bevy_render::renderer: AdapterInfo { name: "Apple M3", vendor: 0, device: 0, device_type: IntegratedGpu, driver: "", driver_info: "", backend: Metal }
2024-08-21T08:15:31.685286Z  INFO bevy_winit::system: Creating new window "App" (0v1#4294967296)
thread 'Compute Task Pool (3)' panicked at crates/bevy_render/src/mesh/allocator.rs:674:21:
internal error: entered unreachable code: Slab not found
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_render::mesh::allocator::allocate_and_free_meshes`!

Additional information

Decided to try it on 0.14.1, and there it works fine. So it seems like a regression, not sure if it is macOS specific, but for now I'll tag it as such.

LikeLakers2 commented 3 weeks ago

Doesn't appear to be MacOS-specific? I tried replicating it on my machine, and got the crash too:

2024-08-21T08:54:45.861166Z  INFO bevy_diagnostic::system_information_diagnostics_plugin::internal: SystemInfo { os: "Windows 10 Home", kernel: "19045", cpu: "AMD Ryzen 5 1400 Quad-Core Processor", core_count: "4", memory: "16.0 GiB" }
2024-08-21T08:54:46.482231Z  INFO bevy_render::renderer: AdapterInfo { name: "NVIDIA GeForce RTX 3060", vendor: 4318, device: 9476, device_type: DiscreteGpu, driver: "NVIDIA", driver_info: "552.12", backend: Vulkan }
2024-08-21T08:54:47.719371Z  INFO bevy_winit::system: Creating new window "App" (0v1#4294967296)
thread 'Compute Task Pool (1)' panicked at crates\bevy_render\src\mesh\allocator.rs:674:21:
internal error: entered unreachable code: Slab not found
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Encountered a panic in system `bevy_render::mesh::allocator::allocate_and_free_meshes`!

This was on commit 6e2f96f2224032e04e77b993ad4c06d76d49039f, compiled using the stable-x86_64-pc-windows-msvc toolchain (rustc 1.80.1 (3f5fd8dd4 2024-08-06)).

brianreavis commented 3 weeks ago

Related: