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
hkratz opened this issue
Oct 16, 2021
· 3 comments
Labels
A-runtimeArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsC-bugCategory: This is a bug.O-ArmTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state
Running the following code with both stable (1.55.0) and nightly (2021-10-15) compiled for aarch64-apple-darwin on aarch64-apple-darwin segfaults instead of aborting:
fnmain(){let t = [0_u8;128*1024*1024];println!("{}", t[1000]);}
Output:
~/dev/spikes/stacksizetest
$ cargo +nightly-aarch64-apple-darwin run
Finished dev [unoptimized + debuginfo] target(s) in 0.00s
Running `target/debug/stacksizetest`
Segmentation fault: 11
Debug/release does not matter.
On x86_64-apple-darwin the program aborts as expected:
cargo +stable-x86_64-apple-darwin run
Compiling stacksizetest v0.1.0 (/Users/hans/dev/spikes/stacksizetest)
Finished dev [unoptimized + debuginfo] target(s) in 1.02s
Running `target/debug/stacksizetest`
thread 'main' has overflowed its stack
fatal runtime error: stack overflow
Abort trap: 6
Same happens for aarch64-unknown-linux-gnu.
The text was updated successfully, but these errors were encountered:
rustbot
added
A-runtime
Area: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflows
O-Arm
Target: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state
O-macos
Operating system: macOS
labels
Oct 16, 2021
hkratz
changed the title
Stack overflow segfaults instead of aborting on aarch64-apple-darwin for simple program
Stack overflow segfaults instead of aborting on aarch64 for simple program
Oct 16, 2021
A-runtimeArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsC-bugCategory: This is a bug.O-ArmTarget: 32-bit Arm processors (armv6, armv7, thumb...), including 64-bit Arm in AArch32 state
Running the following code with both stable (1.55.0) and nightly (2021-10-15) compiled for aarch64-apple-darwin on aarch64-apple-darwin segfaults instead of aborting:
Output:
Debug/release does not matter.
On x86_64-apple-darwin the program aborts as expected:
Same happens for aarch64-unknown-linux-gnu.
The text was updated successfully, but these errors were encountered: