about summary refs log tree commit diff
path: root/src/tools/miri
AgeCommit message (Collapse)AuthorLines
2024-09-16Refator DependencyBuilder constructionOli Scherer-14/+15
2024-09-16Bump ui testOli Scherer-1991/+1884
2024-09-17Refactor FileDescription::read/writetiif-113/+206
2024-09-16layout computation: eagerly error for unexpected unsized fieldsLukas Markeffsky-7/+6
2024-09-16make `LayoutCx` not genericLukas Markeffsky-2/+2
2024-09-16fix clippy lintsRalf Jung-2/+2
2024-09-16fmtThe Miri Cronjob Bot-2/+2
2024-09-16Merge from rustcThe Miri Cronjob Bot-155/+537
2024-09-16Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-09-15Rollup merge of #130342 - RalfJung:slice-idx-overflow, r=saethlinMatthias Krüger-31/+53
interpret, miri: fix dealing with overflow during slice indexing and allocation This is mostly to fix https://github.com/rust-lang/rust/issues/130284. I then realized we're using somewhat sketchy arguments for a similar multiplication in `copy`/`copy_nonoverlapping`/`write_bytes`, so I made them all share the same function that checks exactly the right thing. (The intrinsics would previously fail on allocations larger than `1 << 47` bytes... which are theoretically possible maybe? Anyway it seems conceptually wrong to use any other bound than `isize::MAX` here.)
2024-09-15Rollup merge of #129828 - RalfJung:miri-data-race, r=saethlinMatthias Krüger-112/+483
miri: treat non-memory local variables properly for data race detection Fixes https://github.com/rust-lang/miri/issues/3242 Miri has an optimization where some local variables are not represented in memory until something forces them to be stored in memory (most notably, creating a pointer/reference to the local will do that). However, for a subsystem triggering on memory accesses -- such as the data race detector -- this means that the memory access seems to happen only when the local is moved to memory, instead of at the time that it actually happens. This can lead to UB reports in programs that do not actually have UB. This PR fixes that by adding machine hooks for reads and writes to such efficiently represented local variables. The data race system tracks those very similar to how it would track reads and writes to addressable memory, and when a local is moved to memory, the clocks get overwritten with the information stored for the local.
2024-09-15use early return for race_detecting() logicRalf Jung-156/+152
2024-09-15we can test more things on Solarish, and update its status in the READMERalf Jung-3/+3
2024-09-15test std::time APIs on FreeBSD and SolarishRalf Jung-7/+7
2024-09-15add Android pthread supportRalf Jung-7/+7
2024-09-15make pthread-threadname nicer with cfg-ifRalf Jung-18/+39
2024-09-15enable std::sync tests on SolarishRalf Jung-2/+2
2024-09-15move two tests to a better locationRalf Jung-0/+0
2024-09-15pthread: add FreeBSD, remove PTHREAD_MUTEX_NORMAL_FLAG hackRalf Jung-52/+43
On FreeBSD, DEFAULT maps to ERRORCK. This clashes with the existing PTHREAD_MUTEX_NORMAL_FLAG: hack so we replace it by a different hack that works better cross-platform. Also fix a case of "accidental early UB" in a UB test -- pthread_mutexattr_t must be initialized.
2024-09-15unix/sync: cleanupRalf Jung-81/+29
2024-09-15also use compute_size_in_bytes for relevant multiplications in MiriRalf Jung-31/+53
2024-09-14Auto merge of #3884 - Mandragorian:detect_cond_move, r=RalfJungbors-57/+182
detect when pthread_cond_t is moved Closes #3749
2024-09-14detect when pthread_cond_t is movedKonstantinos Andrikopoulos-57/+182
Closes #3749
2024-09-14simd_shuffle: require index argument to be a vectorRalf Jung-12/+1
2024-09-14Merge from rustcThe Miri Cronjob Bot-303/+215
2024-09-14Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-09-13Auto merge of #3881 - RalfJung:miri-run, r=RalfJungbors-55/+144
./miri run: directly run binary instead of using 'cargo run' This avoids re-building miri without dev dependencies, so it makes `./miri run` a lot faster if `./miri test` was already executed before.
2024-09-13./miri run: directly run binary instead of using 'cargo run'Ralf Jung-55/+144
2024-09-13Auto merge of #130215 - RalfJung:interpret-simd, r=compiler-errorsbors-147/+150
interpret: simplify SIMD type handling This is possible as a follow-up to https://github.com/rust-lang/rust/pull/129403
2024-09-13interpret: simplify SIMD type handlingRalf Jung-147/+150
2024-09-13Update tests for hidden references to mutable staticObei Sideg-0/+35
2024-09-13smoke-test './miri run --dep'Ralf Jung-1/+3
2024-09-13Rollup merge of #130245 - RalfJung:miri-alloc-backtrace, r=AmanieuStuart Cook-156/+65
make basic allocation functions track_caller in Miri for nicer backtraces This matches what we did with basic pointer and atomic operations.
2024-09-12enable all pthread tests on SolarishRalf Jung-2/+2
2024-09-12add non-portable linux pthread initializers to layout sanity checkRalf Jung-10/+23
2024-09-12Remove an unused piece of logicOli Scherer-4/+1
2024-09-12Merge from rustcThe Miri Cronjob Bot-9/+36
2024-09-12Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-09-11Rollup merge of #130239 - RalfJung:miri-ptr-offset-unsigned, r=compiler-errorsJubilee-0/+22
miri: fix overflow detection for unsigned pointer offset This is the Miri part of https://github.com/rust-lang/rust/pull/130229. This is already UB in codegen so we better make Miri detect it; updating the docs may take time if we have to follow some approval process, but let's make Miri match reality ASAP. r? ``@scottmcm``
2024-09-11make basic allocation functions track_caller in Miri for nicer backtracesRalf Jung-156/+65
2024-09-11miri: fix overflow detection for unsigned pointer offsetRalf Jung-0/+22
2024-09-11miri: support vector index arguments in simd_shuffleRalf Jung-9/+14
2024-09-11also allow illumos to use mmap for its stack guardRalf Jung-2/+2
2024-09-11Merge from rustcThe Miri Cronjob Bot-30/+30
2024-09-11Preparing for merge from rustcThe Miri Cronjob Bot-1/+1
2024-09-10Auto merge of #129403 - scottmcm:only-array-simd, r=compiler-errorsbors-30/+30
Ban non-array SIMD Nearing the end of https://github.com/rust-lang/compiler-team/issues/621 ! Currently blocked on ~~https://github.com/rust-lang/compiler-builtins/pull/673~~ ~~https://github.com/rust-lang/compiler-builtins/pull/674~~ ~~https://github.com/rust-lang/rust/pull/129400~~ ~~https://github.com/rust-lang/rust/pull/129481~~ for windows.
2024-09-10miri: treat non-memory local variables properly for data race detectionRalf Jung-7/+382
2024-09-10fmtRalf Jung-48/+62
2024-09-10Merge from rustcRalf Jung-19/+569
2024-09-10Preparing for merge from rustcRalf Jung-1/+1