Ralf Jung
893843fd45
when Miri calls a function ptr, make sure it has the right ABI
2021-03-14 15:30:37 +01:00
Mara Bos
5bd5ea21ea
Remove unwrap_none as it won't be stabilized.
...
This upgrades to the latest rustc to be able to use try_insert()
instead.
2021-03-08 16:59:20 +01:00
Tomasz Miąsko
0eb341417c
rustup to e7c23ab933
2021-02-20 00:00:00 +00:00
bors
b38dc837f2
Auto merge of #1670 - unseddd:abi, r=RalfJung
...
Add ABI check for shims
Resolves #1631
2021-01-29 19:36:30 +00:00
Nym Seddon
de4eea9d49
Add ABI check for shims
2021-01-27 22:32:25 +00:00
Thom Chiovoloni
d310620c11
Allow configuring the failure rate with -Zmiri-compare-exchange-weak-failure-rate
2021-01-26 00:13:54 -08:00
Ralf Jung
8e15f3221e
rustup
2021-01-11 12:35:13 +01:00
JCTyblaidd
e73579632b
Rework to work with machine hook.
2020-12-13 11:04:58 +00:00
JCTyBlaidd
aaf8ca4c77
Fix review changes
2020-12-13 11:04:58 +00:00
JCTyBlaidd
c45b1b16be
More tests, fix issue 1643 and detect races with allocation.
2020-12-13 11:04:58 +00:00
Ralf Jung
7bbd6bca77
rustup
2020-12-10 19:53:45 +01:00
bors
d473242ecd
Auto merge of #1617 - JCTyblaidd:data_race_detector, r=RalfJung
...
Add simple data-race detector
Partially fixes data-race detection, see #1372 , based on Dynamic Race Detection for C++11
- This does not explore weak memory behaviour, only exploring one sequentially consistent ordering.
- Data-race detection is only enabled after the first thread is created, so should have minimal overhead for non-concurrent execution.
- ~~Does not attempt to re-use thread id's so creating and joining threads lots of time in an execution will result in the vector clocks growing in size and slowing down program execution~~ It does now
2020-11-29 18:44:28 +00:00
JCTyBlaidd
3268f56a97
Fix review changes
2020-11-22 17:28:12 +00:00
JCTyBlaidd
69fb6413dd
Tidy up comments and function layout, should fix most of the review notes.
2020-11-15 18:30:26 +00:00
Ralf Jung
43673d9a87
rustup
2020-11-11 10:29:10 +01:00
JCTyBlaidd
89814f1b3f
Initial data-race detector,
...
passes all current tests but additional tests are required
2020-11-02 02:57:05 +00:00
Ralf Jung
194451345d
add an option to track raw pointer tags in Stacked Borrows
2020-10-28 12:23:35 +01:00
est31
1ae157bc9e
Replace target.target with target
...
Rustc removed the target wrapper and exposed the target directly.
Result of running:
find . -type f -exec sed -i -e 's/target\.target\([)\.,;]\)/target\1/g' {} \;
Plus one manual edit of the rust-version file
2020-10-15 21:18:23 +02:00
David Cook
7a2c6812b9
Per-thread errno storage
2020-09-02 20:57:20 -05:00
David Cook
3ba7f46058
Move panic payload state from Machine to Thread
2020-08-29 21:38:37 -05:00
Ralf Jung
664706662f
adjust diagnostics to alignment check mode
2020-08-16 17:16:53 +02:00
Ralf Jung
cb985670c1
make alignment check integer-based by default, and add an option to make it symbolic
2020-08-16 17:08:38 +02:00
Samrat Man Singh
46852d736e
Remove lifetime from FileDescriptor trait
...
Also:
- Remove type annotate `handles` declaration instead of every insert.
- Add note about flush being unnecessary when writing to stderr
2020-08-13 15:01:52 +05:30
Ralf Jung
07a4383ac8
rustup
2020-08-08 14:05:11 +02:00
bors
69d050fb6b
Auto merge of #1495 - samrat:fd-trait, r=oli-obk
...
Add FileDescriptor trait to abstract fn's on File's and Stdin,Stdout,Stderr
Related issue: #1486
Instead of mapping FDs to `FileHandle`, map them to a `FileDescriptor` trait object. The goal is to eventually have both `FileHandle` as well as `Stdin`, `Stdout` and `Stderr` implement this trait so that syscalls involving FDs can handle both `File`s as well as the standard IO streams.
This PR adds the `FileDescriptor` trait and an `impl` for `FileHandle`. I'll open a separate PR for implementing the trait for the standard IO streams.
2020-08-03 15:50:30 +00:00
Samrat Man Singh
e3956f4200
Add FileDescriptor trait to abstract fn's on File's and Std{in,out,err}
2020-08-01 20:53:50 +05:30
Ralf Jung
c77540ce13
deallocate thread-local statics when the thread dies
2020-07-27 23:32:15 +02:00
Ralf Jung
0a4e8caa8c
adjust to canonical_alloc_id removal
2020-07-27 23:32:15 +02:00
Ralf Jung
fef5fa2ae1
add a Miri extern fn to mark an allocation as being a static root for leak checking
2020-07-23 15:47:33 +02:00
Ralf Jung
dcb0f6309e
we cannot track all machine memory any more due to int-ptr-casts
2020-07-08 12:01:49 +02:00
Ralf Jung
c379793cde
add option to track call IDs
2020-07-02 10:33:54 +02:00
Ralf Jung
af5887e869
module organization: move platform-specific code to shims::{posix::{linux, macos}, windows}
2020-06-27 13:22:49 +02:00
Ralf Jung
17dd44ee92
rustup
2020-06-01 19:23:54 +02:00
Oliver Scherer
3fdab9c446
Update to rustc changes
2020-05-10 10:14:03 +02:00
Vytautas Astrauskas
69eaaadc28
Fix merge error.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
3bb1657448
Small style fix.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
688cacbdd7
Cleanup the implementation of adjust_global_const.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
552080a5b7
Fix imports.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
4609c3c520
Rename eval_maybe_thread_local_static_const to adjust_global_const.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
325c31e578
Address some of the reviewers comments.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
51b16e56cd
Generate thread local allocations in eval_maybe_thread_local_static_const.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
963e9698f9
Generate fresh allocation ids for thread locals in eval_maybe_thread_local_static_const.
2020-04-27 14:26:36 -07:00
Vytautas Astrauskas
d907fb5021
Rename ThreadSet to ThreadManager.
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
52184193c3
Fix comments in TLS.
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
ed9c7d168b
Report that we do not support foreign thread local statics.
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
aef4c95599
Fix the problem of sending pointed to thread local statics. Add a regression test.
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
8dd8f199ca
Update to support the updated API.
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
82f17ab917
Implement basic support for concurrency (Linux only).
2020-04-27 14:23:32 -07:00
Vytautas Astrauskas
192fd3d97e
Move stack and stack_mut implementation in Machine to match their position in the trait.
2020-04-20 09:19:37 +02:00
Vytautas Astrauskas
5224c72403
Move the stack to the evaluator to make Miri compile with the newest Rustc.
2020-04-20 09:19:37 +02:00