]> git.lizzy.rs Git - rust.git/blobdiff - CONTRIBUTING.md
Explain `tests::init` function
[rust.git] / CONTRIBUTING.md
index 7dfa9d73120f5f91922f2d9b69cda7acc3ef190b..bde1921eb8ce467fbb85e5b86443ea7ebf2ce0ee 100644 (file)
@@ -147,6 +147,12 @@ does not automatically trigger a re-build of the standard library; you have to
 clear the Miri build cache manually (on Linux, `rm -rf ~/.cache/miri`;
 and on Windows, `rmdir /S "%LOCALAPPDATA%\rust-lang\miri\cache"`).
 
+### Benchmarking
+
+Miri comes with a few benchmarks; you can run `./miri bench` to run them with the locally built
+Miri. Note: this will run `./miri install` as a side-effect. Also requires `hyperfine` to be
+installed (`cargo install hyperfine`).
+
 ## Configuring `rust-analyzer`
 
 To configure `rust-analyzer` and VS Code for working on Miri, save the following
@@ -154,19 +160,24 @@ to `.vscode/settings.json` in your local Miri clone:
 
 ```json
 {
+    "rust-analyzer.rustc.source": "discover",
+    "rust-analyzer.linkedProjects": [
+        "./Cargo.toml",
+        "./cargo-miri/Cargo.toml"
+    ],
     "rust-analyzer.checkOnSave.overrideCommand": [
         "./miri",
         "check",
         "--message-format=json"
     ],
+    "rust-analyzer.buildScripts.overrideCommand": [
+        "./miri",
+        "check",
+        "--message-format=json",
+    ],
     "rust-analyzer.rustfmt.extraArgs": [
         "+nightly"
     ],
-    "rust-analyzer.rustcSource": "discover",
-    "rust-analyzer.linkedProjects": [
-        "./Cargo.toml",
-        "./cargo-miri/Cargo.toml"
-    ]
 }
 ```