3bbcafe3b5
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.
58 lines
1.4 KiB
TOML
58 lines
1.4 KiB
TOML
[package]
|
|
authors = ["Miri Team"]
|
|
description = "An experimental interpreter for Rust MIR (core driver)."
|
|
license = "MIT OR Apache-2.0"
|
|
name = "miri"
|
|
repository = "https://github.com/rust-lang/miri"
|
|
version = "0.1.0"
|
|
default-run = "miri"
|
|
edition = "2021"
|
|
|
|
[lib]
|
|
test = true # we have unit tests
|
|
doctest = false # but no doc tests
|
|
|
|
[[bin]]
|
|
name = "miri"
|
|
test = false # we have no unit tests
|
|
doctest = false # and no doc tests
|
|
|
|
[dependencies]
|
|
getrandom = { version = "0.2", features = ["std"] }
|
|
env_logger = "0.9"
|
|
log = "0.4"
|
|
shell-escape = "0.1.4"
|
|
rand = "0.8"
|
|
smallvec = "1.7"
|
|
|
|
# A noop dependency that changes in the Rust repository, it's a bit of a hack.
|
|
# See the `src/tools/rustc-workspace-hack/README.md` file in `rust-lang/rust`
|
|
# for more information.
|
|
rustc-workspace-hack = "1.0.0"
|
|
measureme = "10.0.0"
|
|
|
|
# Enable some feature flags that dev-dependencies need but dependencies
|
|
# do not. This makes `./miri install` after `./miri build` faster.
|
|
[target."cfg(unix)".dependencies]
|
|
libc = "0.2"
|
|
|
|
[dev-dependencies]
|
|
colored = "2"
|
|
ui_test = { path = "ui_test" }
|
|
regex = "1.5.5"
|
|
lazy_static = "1.4.0"
|
|
|
|
[package.metadata.rust-analyzer]
|
|
# This crate uses #[feature(rustc_private)].
|
|
# See https://github.com/rust-analyzer/rust-analyzer/pull/7891
|
|
rustc_private = true
|
|
|
|
[[test]]
|
|
name = "compiletest"
|
|
harness = false
|
|
|
|
[features]
|
|
default = ["stack-cache"]
|
|
expensive-debug-assertions = []
|
|
stack-cache = []
|