diff options
| author | Josh Stone <jistone@redhat.com> | 2023-11-16 10:42:23 -0800 |
|---|---|---|
| committer | Josh Stone <jistone@redhat.com> | 2023-11-16 10:42:23 -0800 |
| commit | 776146e9ebb6bbe17a37bfad955f3dac95317275 (patch) | |
| tree | 5878045ede7319510d8f3aa174750d5ece2329fa /src/bootstrap | |
| parent | 0ea7ddcc35a2fcaa5da8a7dcfc118c9fb4a63b95 (diff) | |
bootstrap: only show PGO warnings when verbose
Building rustc with `--rust-profile-use` is currently dumping a lot of warnings of "no profile data available for function" from `rustc_smir` and `stable_mir`. These simply aren't exercised by the current profile- gathering steps, but that's to be expected for new or experimental functionality. I think for most people, these warnings will be just noise, so it makes sense to only have them in verbose builds.
Diffstat (limited to 'src/bootstrap')
| -rw-r--r-- | src/bootstrap/src/core/build_steps/compile.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/bootstrap/src/core/build_steps/compile.rs b/src/bootstrap/src/core/build_steps/compile.rs index af69860df1c..51e4195827f 100644 --- a/src/bootstrap/src/core/build_steps/compile.rs +++ b/src/bootstrap/src/core/build_steps/compile.rs @@ -887,7 +887,9 @@ impl Step for Rustc { } else if let Some(path) = &builder.config.rust_profile_use { if compiler.stage == 1 { cargo.rustflag(&format!("-Cprofile-use={path}")); - cargo.rustflag("-Cllvm-args=-pgo-warn-missing-function"); + if builder.is_verbose() { + cargo.rustflag("-Cllvm-args=-pgo-warn-missing-function"); + } true } else { false |
