Commit Graph

137 Commits

Author SHA1 Message Date
Oli Scherer
4f357956b8 Only support libffi on unix for now 2022-09-21 12:48:47 +00:00
Ralf Jung
2f348abafc Revert "disable extern-so ffi support for now due to licensing situation"
This reverts commit 5f3545e773.
With https://github.com/tov/libffi-rs/pull/58 landed, we no longer depend on abort_on_panic.
2022-09-02 14:39:25 +02:00
Ralf Jung
5f3545e773 disable extern-so ffi support for now due to licensing situation 2022-09-01 22:25:14 +02:00
Oli Scherer
eafc100b50 Bump ui_test to 0.3.1 2022-08-31 11:06:35 +00:00
Oli Scherer
b74654f25c Bump UI test dependency 2022-08-31 10:27:50 +00:00
Ellen Arteca
88a7882615 C FFI support for functions with int args and returns 2022-08-26 00:53:23 +00:00
Oli Scherer
fb071a14bd Use ui_test from crates.io instead of having it in-tree 2022-08-25 15:34:57 +00:00
Ralf Jung
bfd148b783 use env vars, not Cargo.toml, to configure out dev profile 2022-07-18 17:48:45 -04:00
Ralf Jung
5d5999ab13 make cache consistency checks into regular debug assertions 2022-07-14 13:00:35 -04:00
Ralf Jung
efc76af134 don't forcefully enable debug assertions, but make -debug mode usable
still set those flags on CI though, we want to catch overflow there
2022-07-14 13:00:35 -04:00
Ralf Jung
248a10eaf5 reduce regex features to reduce rebuilds 2022-07-03 12:28:57 -04:00
Ben Kimock
f3b479d556 Explain cache behavior a bit better, clean up diff 2022-07-02 19:44:55 -04:00
Ben Kimock
3bbcafe3b5 Cache lookups into the borrow stack
This adds a very simple LRU-like cache which stores the locations of
often-used tags. While the implementation is very simple, the cache hit
rate is incredible at ~99.9% on most programs, and often the element at
position 0 in the cache has a hit rate of 90%. So the sub-optimality of
this cache basicaly vanishes into the noise in a profile.

Additionally, we keep a range which denotes where there might be an item
granting Unique permission in the stack, so that when we invalidate
Uniques we do not need to scan much of the stack, and often scan nothing
at all.
2022-07-01 17:51:16 -04:00
Wesley Wiser
2f9750783c Update measureme to the latest version 2022-06-24 19:04:50 -04:00
Oli Scherer
f1756c3ddd Add a custom ui test runner and move all tests to it 2022-05-25 13:31:26 +00:00
David Tolnay
b994148714
Clean up all trailing whitespace 2022-04-30 10:40:35 -07:00
Ralf Jung
af3f683ba6 port Miri to edition 2021 2022-04-09 11:16:50 -04:00
Alex Touchet
79a1001b39 Use SPDX license format 2022-04-04 15:52:09 -07:00
Ralf Jung
9a6450af95 also accept odd number of hex digits; add README section on randomized alignment testing 2022-03-12 10:09:15 -05:00
Benoît du Garreau
0424554080 Update dependencies 2021-10-01 23:08:58 +02:00
Samuel E. Moelius III
8d797fb154 Update compiletest_rs dependency 2021-09-01 08:53:51 -04:00
Aaron Hill
16f469280e
Address review comments 2021-05-29 17:10:54 -05:00
Aaron Hill
7e9da8d30e
Add measureme integration for profiling the interpreted program
This PR uses the `measureme` crate to profile the call stack of the
program being interpreted by Miri. This is accomplished by starting a
measureme 'event' when we enter a function call, and ending the event
when we exit the call. The `measureme` tooling can be used to produce a
call stack from the generated profile data.

Limitations:
* We currently record every single entry/exit. This might generate very
  large profile outputs for programs with a large number of function
  calls. In follow-up work, we might want to explore sampling (e.g. only
  recording every N function calls).
* This does not integrate very well with Miri's concurrency support.
  Each event we record starts when we push a frame, and ends when we pop
  a frame. As a result, switching between virtual threads will cause
  events from different threads to be interleaved. Additionally, the
  recorded for a particular frame will include all of the work Miri does
  before that frame completes, including executing another thread.

The `measureme` integration is off by default, and must be enabled via
`-Zmiri-measureme=<output_name>`
2021-05-29 17:01:52 -05:00
hyd-dev
2da6bedaec
Use harness = false instead of #![feature(custom_test_frameworks)] 2021-05-01 22:28:33 +08:00
Ralf Jung
31bd77c7d8 bump miri dependencies 2021-04-04 11:48:20 +02:00
Daniel McNab
6106ee214c Add link to pr for documentation 2021-03-09 18:27:22 +00:00
Daniel McNab
1e19150d1e Opt-in to rustc_private for rust-analyzer
rust-analyzer/rust-analyzer#7891
2021-03-08 17:28:52 +00:00
Ralf Jung
6145709bfc remove miri-rustc-tests 2020-11-29 21:00:50 +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
6be8761e47 update for major version bumps 2020-09-18 12:17:09 +02:00
Jubilee Young
20942fb3a7 Remove byteorder dependency
miri hasn't actually depended on byteorder directly for a while.
Let's remove this dependency so Rust also depends less on it.
2020-08-19 22:19:32 -07:00
Ralf Jung
35964b10b0 no workspace as that is incompatible with the rustc submodule 2020-05-28 08:53:44 +02:00
Ralf Jung
7fcf92dfea re-add some fake dependencies to avoid rebuilds 2020-05-28 08:53:44 +02:00
Ralf Jung
0790f75ae4 make cargo-miri a separate crate in a workspace 2020-05-28 08:53:44 +02:00
Ralf Jung
93027da5ed bump compiletest 2020-04-10 14:57:22 +02:00
Ralf Jung
92e3032941 Cargo.toml: group all dependencies together 2020-03-15 15:15:22 +01:00
Ralf Jung
5c4dc072bd downgrade serde_json to match rustc workspace 2020-03-04 10:29:00 +01:00
Ralf Jung
47f2b12735 fix Cargo.toml 2020-02-24 14:42:45 +01:00
Aaron Hill
e530829797 Use 'cargo check' to build the sysroot and target crate
Fixes #1057

Since we are no longer using "cargo rustc", we now use the rustc
arguments passed by Cargo to determine whether we are building a
build dependency, normal dependency, or "target" (final binary or test)
crate.
2020-02-24 14:41:04 +01:00
Ralf Jung
87fb5db526 avoid recompiling Miri on install 2019-12-06 08:27:15 +01:00
Ralf Jung
e2fd9d83e2 cargo update 2019-11-26 14:28:56 +01:00
Ralf Jung
52b18b44f9 bump compiletest; remove unused feature 2019-11-18 15:10:17 +01:00
Ralf Jung
08fe5ee78c try the stable feature of compiletest 2019-11-16 09:08:30 +01:00
Mateusz Mikuła
b40351c53a Bump dependencies 2019-10-27 23:01:01 +01:00
bors
1bf282ff09 Auto merge of #1020 - RalfJung:compiletest, r=RalfJung
compiletest-nightly should work again
2019-10-24 08:53:52 +00:00
Ralf Jung
1b96a822de compiletest-nightly should work again 2019-10-24 10:31:08 +02:00
Ralf Jung
cf9340113e rustup: more flexible write_bytes avoids allocations and removes itertools dependency 2019-10-24 10:15:30 +02:00
Ralf Jung
6fb5e124d9 use compiletest_rs for stable compiler as nightly is broken 2019-10-23 10:31:08 +02:00
Ralf Jung
2690f5948a rustup: fix for write_bytes and new union rules 2019-10-22 10:13:11 +02:00
Ralf Jung
d8f06523f2 bump compiletest 2019-10-14 13:17:30 +02:00