diff options
| author | Zalathar <Zalathar@users.noreply.github.com> | 2023-06-12 18:07:04 +1000 |
|---|---|---|
| committer | Zalathar <Zalathar@users.noreply.github.com> | 2023-06-28 11:08:10 +1000 |
| commit | a42bbd0eddca3f22923112fa99686de5b79e23e3 (patch) | |
| tree | 1184e58ccbb322639b2cddacca8da65da83617ce /src/tools/compiletest | |
| parent | 75d01f8821f6da653a10fb773c18b56803ed076c (diff) | |
| download | rust-a42bbd0eddca3f22923112fa99686de5b79e23e3.tar.gz rust-a42bbd0eddca3f22923112fa99686de5b79e23e3.zip | |
Move the `RUSTC_PROFILER_SUPPORT` check into `CachedNeedsConditions`
Diffstat (limited to 'src/tools/compiletest')
| -rw-r--r-- | src/tools/compiletest/src/header/needs.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/tools/compiletest/src/header/needs.rs b/src/tools/compiletest/src/header/needs.rs index 0e306696a90..62364ede47b 100644 --- a/src/tools/compiletest/src/header/needs.rs +++ b/src/tools/compiletest/src/header/needs.rs @@ -87,7 +87,7 @@ pub(super) fn handle_needs( }, Need { name: "needs-profiler-support", - condition: std::env::var_os("RUSTC_PROFILER_SUPPORT").is_some(), + condition: cache.profiler_support, ignore_reason: "ignored when profiler support is disabled", }, Need { @@ -195,6 +195,7 @@ pub(super) struct CachedNeedsConditions { sanitizer_memtag: bool, sanitizer_shadow_call_stack: bool, sanitizer_safestack: bool, + profiler_support: bool, xray: bool, rust_lld: bool, i686_dlltool: bool, @@ -232,6 +233,7 @@ impl CachedNeedsConditions { sanitizer_memtag: util::MEMTAG_SUPPORTED_TARGETS.contains(target), sanitizer_shadow_call_stack: util::SHADOWCALLSTACK_SUPPORTED_TARGETS.contains(target), sanitizer_safestack: util::SAFESTACK_SUPPORTED_TARGETS.contains(target), + profiler_support: std::env::var_os("RUSTC_PROFILER_SUPPORT").is_some(), xray: util::XRAY_SUPPORTED_TARGETS.contains(target), // For tests using the `needs-rust-lld` directive (e.g. for `-Zgcc-ld=lld`), we need to find |
