You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#0 0x00007d697410dae4 in core::any::{impl#4}::is<&str> (self=..., self=...)
at /rustc/98aa3624be70462d6a25ed5544333e3df62f4c66/library/core/src/any.rs:200
#1 core::any::{impl#4}::downcast_ref<&str> (self=...)
at /rustc/98aa3624be70462d6a25ed5544333e3df62f4c66/library/core/src/any.rs:228
#2 core::any::{impl#5}::downcast_ref<&str> (self=...)
at /rustc/98aa3624be70462d6a25ed5544333e3df62f4c66/library/core/src/any.rs:379
#3 crankstart::panic (panic_info=<optimized out>) at src/lib.rs:297
#4 0x00007d69740ff796 in core::panicking::panic_nounwind_fmt::runtime () at library/core/src/panicking.rs:110
#5 core::panicking::panic_nounwind_fmt () at library/core/src/panicking.rs:122
#6 0x00007d69740ff88a in core::panicking::panic_misaligned_pointer_dereference ()
at library/core/src/panicking.rs:221
#7 0x00007d697410dc13 in crankstart::abort_with_addr (addr=137891872414744) at src/lib.rs:286
#8 0x00007d697410dbde in crankstart::panic (panic_info=<optimized out>) at src/lib.rs:323
#9 0x00007d69740ff796 in core::panicking::panic_nounwind_fmt::runtime () at library/core/src/panicking.rs:110
#10 core::panicking::panic_nounwind_fmt () at library/core/src/panicking.rs:122
#11 0x00007d69740ff88a in core::panicking::panic_misaligned_pointer_dereference ()
at library/core/src/panicking.rs:221
#12 0x00007d697410dc13 in crankstart::abort_with_addr (addr=137891872414744) at src/lib.rs:286
#13 0x00007d697410dbde in crankstart::panic (panic_info=<optimized out>) at src/lib.rs:323
#14 0x00007d69740ff796 in core::panicking::panic_nounwind_fmt::runtime () at library/core/src/panicking.rs:110
#15 core::panicking::panic_nounwind_fmt () at library/core/src/panicking.rs:122
#16 0x00007d69740ff88a in core::panicking::panic_misaligned_pointer_dereference ()
at library/core/src/panicking.rs:221
... and so on, ad infinitum or until the stack overflows with a segmentation fault.
The root cause is abort_with_addr trying to write to a misaligned pointer, 0xdeadbeef.
This can easily be fixed by changing the pointer to *mut u8, because this has size 1, which is guaranteed to be a multiple of the alignment which must therefore also be 1.
(Aside: It would also be nice if the abort could be suppressed with some kind of build flag, because it aborts the simulator before it has a chance to print the panic message.)
The text was updated successfully, but these errors were encountered:
ttencate
added a commit
to ttencate/crankstart
that referenced
this issue
Feb 23, 2024
... and so on, ad infinitum or until the stack overflows with a segmentation fault.
The root cause is
abort_with_addr
trying to write to a misaligned pointer,0xdeadbeef
.This can easily be fixed by changing the pointer to
*mut u8
, because this has size 1, which is guaranteed to be a multiple of the alignment which must therefore also be 1.(Aside: It would also be nice if the abort could be suppressed with some kind of build flag, because it aborts the simulator before it has a chance to print the panic message.)
The text was updated successfully, but these errors were encountered: