Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Index error panic #546

Open
John-Nagle opened this issue Dec 21, 2023 · 5 comments
Open

Index error panic #546

John-Nagle opened this issue Dec 21, 2023 · 5 comments

Comments

@John-Nagle
Copy link
Contributor

05:56:48 [ERROR] =========> Panic assertion failed: (i == 0 || self.free_ranges[i - 1].end < range.start) &&\n    (i >= self.free_ranges.len() || range.end < self.free_ranges[i].start) at file /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs, line 133 in thread main.
Backtrace:
 libcommon::common::commonutils::catch_panic::{{closure}}
             at /home/john/projects/sl/SL-test-viewer/libcommon/src/common/commonutils.rs:215:25
 range_alloc::RangeAllocator<T>::free_range
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs:133:9
 rend3::managers::mesh::MeshManager::remove
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/managers/mesh.rs:220:13
 rend3::renderer::eval::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/renderer/eval.rs:134:21
 rend3::renderer::Renderer::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/renderer/mod.rs:457:9
 <sharpview::AppUi as rend3_framework::App>::handle_event
             at /home/john/projects/sl/SL-test-viewer/sharpview/src/main.rs:555:39
 rend3_framework::async_start::{{closure}}::{{closure}}
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3-framework/src/lib.rs:338:9
 winit::platform_impl::platform::sticky_exit_callback
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/mod.rs:884:9
 winit::platform_impl::platform::x11::EventLoop<T>::run_return::single_iteration
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/x11/mod.rs:375:21
 winit::platform_impl::platform::x11::EventLoop<T>::run_return
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/x11/mod.rs:483:27

Until recently, I didn't change the meshes for existing objects much. Now, I'm creating and releasing meshes and objects at a high rate as the viewpoint moves around, for level of detail management purposes. So Rend3 is being exercised in a new way.

@John-Nagle
Copy link
Contributor Author

06:07:16 [ERROR] =========> Panic assertion failed: (i == 0 || self.free_ranges[i - 1].end < range.start) &&\n    (i >= self.free_ranges.len() || range.end < self.free_ranges[i].start) at file /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs, line 133 in thread main.
Backtrace:
 libcommon::common::commonutils::catch_panic::{{closure}}
             at /home/john/projects/sl/SL-test-viewer/libcommon/src/common/commonutils.rs:215:25
 range_alloc::RangeAllocator<T>::free_range
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs:133:9
 rend3::managers::mesh::MeshManager::remove
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/managers/mesh.rs:220:13
 rend3::renderer::eval::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/renderer/eval.rs:134:21
 rend3::renderer::Renderer::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3/src/renderer/mod.rs:457:9
 <sharpview::AppUi as rend3_framework::App>::handle_event
             at /home/john/projects/sl/SL-test-viewer/sharpview/src/main.rs:555:39
 rend3_framework::async_start::{{closure}}::{{closure}}
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/9065f1e/rend3-framework/src/lib.rs:338:9
 winit::platform_impl::platform::sticky_exit_callback
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/mod.rs:884:9
 winit::platform_impl::platform::x11::EventLoop<T>::run_return::single_iteration
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/x11/mod.rs:375:21
 winit::platform_impl::platform::x11::EventLoop<T>::run_return
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.28.7/src/platform_impl/linux/x11/mod.rs:483:27

Another one of the same. It's intermittent, but not a one-off.

Rend3 rev = "9065f1e"

@John-Nagle
Copy link
Contributor Author

08:07:47 [ERROR] =========> Panic assertion failed: (i == 0 || self.free_ranges[i - 1].end < range.start) &&\n    (i >= self.free_ranges.len() || range.end < self.free_ranges[i].start) at file /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs, line 133 in thread main.
Backtrace:
 libcommon::common::commonutils::catch_panic::{{closure}}
             at /home/john/projects/sl/SL-test-viewer/libcommon/src/common/commonutils.rs:215:25
 range_alloc::RangeAllocator<T>::free_range
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs:133:9
 rend3::managers::mesh::MeshManager::remove
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/a68c76a/rend3/src/managers/mesh.rs:217:13
 rend3::renderer::eval::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/a68c76a/rend3/src/renderer/eval.rs:133:21
 rend3::renderer::Renderer::evaluate_instructions
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/a68c76a/rend3/src/renderer/mod.rs:482:9
 <sharpview::AppUi as rend3_framework::App>::handle_redraw
             at /home/john/projects/sl/SL-test-viewer/sharpview/src/main.rs:662:31
 rend3_framework::async_start::{{closure}}::{{closure}}
             at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/a68c76a/rend3-framework/src/lib.rs:354:17
 winit::platform_impl::platform::x11::EventLoop<T>::single_iteration
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.8/src/platform_impl/linux/x11/mod.rs:608:17
 winit::platform_impl::platform::x11::EventLoop<T>::poll_events_with_timeout
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.8/src/platform_impl/linux/x11/mod.rs:547:9
 winit::platform_impl::platform::x11::EventLoop<T>::pump_events
             at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.8/src/platform_impl/linux/x11/mod.rs:453:13

This time with the fully arcanized version. rev = "a68c76a".

@John-Nagle
Copy link
Contributor Author

These occur frequently now in complex scenes. rev = "a68c76a", which I now know is not arcanized.

@John-Nagle
Copy link
Contributor Author

Still fails in arcanized version rev = "c7c2d85":

Panic assertion failed: (i == 0 || self.free_ranges[i - 1].end < range.start) &&
(i >= self.free_ranges.len() || range.end < self.free_ranges[i].start) at file /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs, line 133 in thread main.
Backtrace:
libcommon::common::commonutils::catch_panic::{{closure}}
at /home/john/projects/sl/SL-test-viewer/libcommon/src/common/commonutils.rs:215:25
range_alloc::RangeAllocator::free_range
at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/range-alloc-0.1.3/src/lib.rs:133:9
rend3::managers::mesh::MeshManager::remove
at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/c7c2d85/rend3/src/managers/mesh.rs:217:13
rend3::renderer::eval::evaluate_instructions
at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/c7c2d85/rend3/src/renderer/eval.rs:137:21
rend3::renderer::Renderer::evaluate_instructions
at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/c7c2d85/rend3/src/renderer/mod.rs:482:9
<sharpview::AppUi as rend3_framework::App>::handle_redraw
at /home/john/projects/sl/SL-test-viewer/sharpview/src/main.rs:656:31
rend3_framework::async_start::{{closure}}::{{closure}}
at /home/john/.cargo/git/checkouts/rend3-e03f89403de3386a/c7c2d85/rend3-framework/src/lib.rs:355:17
winit::platform_impl::platform::x11::EventLoop::single_iteration
at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.10/src/platform_impl/linux/x11/mod.rs:608:17
winit::platform_impl::platform::x11::EventLoop::poll_events_with_timeout
at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.10/src/platform_impl/linux/x11/mod.rs:547:9
winit::platform_impl::platform::x11::EventLoop::pump_events
at /home/john/.cargo/registry/src/index.crates.io-6f17d22bba15001f/winit-0.29.10/src/platform_impl/linux/x11/mod.rs:453:13

@John-Nagle
Copy link
Contributor Author

gfx-rs/range-alloc#1 seems to fix this. Survived 8 hours of testing so far. Never got past 2.5 hours before. I'll let it run overnight.

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

No branches or pull requests

1 participant