rust/tests/compile-fail
bors 57786678d4 Auto merge of #1975 - DrMeepster:backtrace_fix, r=RalfJung
Make backtraces work with #[global_allocator]

Currently, backtraces break when the global allocator is overridden because the allocator will attempt to deallocate memory allocated directly by Miri.

~~This PR fixes that by using a new memory kind and providing a function to deallocate it. We can't call the custom allocator to allocate because it's not possible to call a function in the middle of a shim.~~

This PR fixes that by adding a new version of the backtrace API accessible by setting `flags` to 1. Existing code still functions.

backtrace-rs PR: rust-lang/backtrace-rs#462

Fixes https://github.com/rust-lang/miri/issues/1996
2022-03-20 02:37:09 +00:00
..
alloc rustup 2021-11-01 16:12:38 -07:00
backtrace add new version of backtrace api using flags=1 2022-03-19 18:14:11 -07:00
concurrency also ignore 'thread leaks' with -Zmiri-ignore-leaks 2021-07-25 14:21:06 +02:00
dangling_pointers adjust Miri to Pointer type overhaul 2021-07-16 10:10:12 +02:00
data_race avoid importing C functions in alloc_write_race test 2021-05-19 15:27:58 +02:00
fs allow varargs for libc::open when it is allowed by the second argument 2022-03-05 17:29:48 -05:00
function_calls adjust output for calling convention check 2021-12-24 12:02:23 +01:00
function_pointers Update pointer error messages 2021-05-08 15:33:27 +08:00
intrinsics detect when unused bits of a SIMD bitmask are non-0 2022-03-17 13:08:01 -04:00
panic adjust output for calling convention check 2021-12-24 12:02:23 +01:00
stacked_borrows Print more in SB error diagnostics 2022-03-16 20:12:04 -04:00
sync Add tests for double destroying various pthread items 2021-12-06 21:15:02 +00:00
unaligned_pointers Make sure we notice when a u16 is loaded at offset 1 into a u8 allocation 2022-03-02 13:06:28 -05:00
validity update fn ptr tests 2022-02-25 12:06:10 -05:00
abort-terminator.rs Fix tests for C-unwind ABI changes 2021-08-07 15:57:54 +08:00
box-cell-alias.rs Print more in SB error diagnostics 2022-03-16 20:12:04 -04:00
branchless-select-i128-pointer.rs add test by @eddyb 2021-02-16 10:18:31 +01:00
breakpoint.rs Support breakpoint intrinsic 2021-03-04 07:48:28 -05:00
environ-gets-deallocated.rs
erroneous_const.rs rustup 2021-10-05 13:13:06 -07:00
extern_static.rs rustup 2021-01-31 13:12:25 +01:00
fast_math_both.rs Simplify finiteness checking 2021-05-03 10:08:42 -04:00
fast_math_first.rs Simplify finiteness checking 2021-05-03 10:08:42 -04:00
fast_math_second.rs test for infinite value in f*_fast 2021-05-03 09:56:51 -04:00
generator-pinned-moved.rs
invalid_bool.rs rustup 2021-04-25 16:57:48 +02:00
invalid_char.rs
invalid_enum_tag.rs
invalid_int.rs
issue-miri-1112.rs
memleak_rc.rs
memleak.rs
modifying_constants.rs
never_say_never.rs
never_transmute_humans.rs
never_transmute_void.rs
no_main.rs
null_pointer_deref_zst.rs add ptr_offset_from OOB test, and update test errors 2022-03-10 18:56:19 -05:00
null_pointer_deref.rs Update pointer error messages 2021-05-08 15:33:27 +08:00
null_pointer_write_zst.rs add ptr_offset_from OOB test, and update test errors 2022-03-10 18:56:19 -05:00
null_pointer_write.rs Update pointer error messages 2021-05-08 15:33:27 +08:00
pointer_partial_overwrite.rs adjust for ERR_ON_PARTIAL_PTR_OVERWRITE 2021-08-02 17:58:55 +02:00
pointer_partial_read.rs adjust for ERR_ON_PARTIAL_PTR_OVERWRITE 2021-08-02 17:58:55 +02:00
rc_as_ptr.rs
reading_half_a_pointer.rs
rustc-error.rs
shim_arg_size.rs
slice-too-big.rs
static_memory_modification1.rs
static_memory_modification2.rs
static_memory_modification3.rs
transmute_fat1.rs
transmute-pair-uninit.rs rustup 2021-02-23 09:23:49 +01:00
uninit_buffer.rs
uninit_byte_read.rs
uninit_float.rs Add tests for -Zmiri-check-number-validity 2021-11-10 11:36:42 -08:00
uninit_integer_signed.rs Add tests for -Zmiri-check-number-validity 2021-11-10 11:36:42 -08:00
uninit_integer.rs Add tests for -Zmiri-check-number-validity 2021-11-10 11:36:42 -08:00
uninit_raw_ptr.rs Add test for uninit raw ptrs 2021-11-10 11:36:42 -08:00
unreachable.rs
unsupported_foreign_function.rs Unsupported foreign non-"C"/"system"-ABI function calls are not UB 2021-03-17 21:20:04 +08:00
unsupported_signal.rs expand comment 2021-06-06 10:33:46 +02:00
zst1.rs adjust Miri to Pointer type overhaul 2021-07-16 10:10:12 +02:00
zst2.rs disable MIR opts for ZST-related tests 2021-03-25 12:44:30 +01:00
zst3.rs adjust Miri to Pointer type overhaul 2021-07-16 10:10:12 +02:00