diff options
| author | Tyler Mandry <tmandry@gmail.com> | 2020-08-31 19:18:14 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-08-31 19:18:14 -0700 |
| commit | 6d834a4046f9591ea9678ce9be2adbbb4a9aeedd (patch) | |
| tree | d987ffc6fd70ab04b630bb6eb0c7e8eae43d8519 /compiler/rustc_session/src/options.rs | |
| parent | b67582449339a8c90a18aec2e93f6fc3560acb2f (diff) | |
| parent | ddb054aee898dd74261fa8f50fe0c6541e5ceaf3 (diff) | |
| download | rust-6d834a4046f9591ea9678ce9be2adbbb4a9aeedd.tar.gz rust-6d834a4046f9591ea9678ce9be2adbbb4a9aeedd.zip | |
Rollup merge of #76002 - richkadel:llvm-coverage-map-gen-6b.3, r=tmandry
Fix `-Z instrument-coverage` on MSVC Found that `-C link-dead-code` (which was enabled automatically under `-Z instrument-coverage`) was causing the linking error that resulted in segmentation faults in coverage instrumented binaries. Link dead code is now disabled under MSVC, allowing `-Z instrument-coverage` to be enabled under MSVC for the first time. More details are included in Issue #76038 . Note this PR makes it possible to support `Z instrument-coverage` but does not enable instrument coverage for MSVC in existing tests. It will be enabled in another PR to follow this one (both PRs coming from original PR #75828). r? @tmandry FYI: @wesleywiser
Diffstat (limited to 'compiler/rustc_session/src/options.rs')
| -rw-r--r-- | compiler/rustc_session/src/options.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/rustc_session/src/options.rs b/compiler/rustc_session/src/options.rs index 82330d9a533..ee30c16108a 100644 --- a/compiler/rustc_session/src/options.rs +++ b/compiler/rustc_session/src/options.rs @@ -885,9 +885,9 @@ options! {DebuggingOptions, DebuggingSetter, basic_debugging_options, "instrument the generated code to support LLVM source-based code coverage \ reports (note, the compiler build config must include `profiler = true`, \ and is mutually exclusive with `-C profile-generate`/`-C profile-use`); \ - implies `-C link-dead-code` (unless explicitly disabled)` and \ - `-Z symbol-mangling-version=v0`; and disables/overrides some optimization \ - options (default: no)"), + implies `-C link-dead-code` (unless targeting MSVC, or explicitly disabled) \ + and `-Z symbol-mangling-version=v0`; disables/overrides some Rust \ + optimizations (default: no)"), instrument_mcount: bool = (false, parse_bool, [TRACKED], "insert function instrument code for mcount-based tracing (default: no)"), keep_hygiene_data: bool = (false, parse_bool, [UNTRACKED], |
