Skip to content

Commit 3d54f19

Browse files
committed
Don't bother logging an arbitrary subset of the compiletest config
Running `./x --verbose` will still print out the command-line arguments, and setting `RUST_LOG=compiletest` will now log the full config instead of a subset.
1 parent f2824da commit 3d54f19

File tree

2 files changed

+3
-48
lines changed

2 files changed

+3
-48
lines changed

src/tools/compiletest/src/bin/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ use std::env;
22
use std::io::IsTerminal;
33
use std::sync::Arc;
44

5-
use compiletest::{early_config_check, log_config, parse_config, run_tests};
5+
use compiletest::{early_config_check, parse_config, run_tests};
66

77
fn main() {
88
tracing_subscriber::fmt::init();
@@ -19,6 +19,5 @@ fn main() {
1919

2020
early_config_check(&config);
2121

22-
log_config(&config);
2322
run_tests(config);
2423
}

src/tools/compiletest/src/lib.rs

Lines changed: 2 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ use crate::common::{
4444
};
4545
use crate::directives::DirectivesCache;
4646
use crate::executor::{CollectedTest, ColorConfig};
47-
use crate::util::logv;
4847

4948
/// Creates the `Config` instance for this invocation of compiletest.
5049
///
@@ -477,51 +476,6 @@ pub fn parse_config(args: Vec<String>) -> Config {
477476
}
478477
}
479478

480-
pub fn log_config(config: &Config) {
481-
let c = config;
482-
logv(c, "configuration:".to_string());
483-
logv(c, format!("compile_lib_path: {}", config.compile_lib_path));
484-
logv(c, format!("run_lib_path: {}", config.run_lib_path));
485-
logv(c, format!("rustc_path: {}", config.rustc_path));
486-
logv(c, format!("cargo_path: {:?}", config.cargo_path));
487-
logv(c, format!("rustdoc_path: {:?}", config.rustdoc_path));
488-
489-
logv(c, format!("src_root: {}", config.src_root));
490-
logv(c, format!("src_test_suite_root: {}", config.src_test_suite_root));
491-
492-
logv(c, format!("build_root: {}", config.build_root));
493-
logv(c, format!("build_test_suite_root: {}", config.build_test_suite_root));
494-
495-
logv(c, format!("sysroot_base: {}", config.sysroot_base));
496-
497-
logv(c, format!("stage: {}", config.stage));
498-
logv(c, format!("stage_id: {}", config.stage_id));
499-
logv(c, format!("mode: {}", config.mode));
500-
logv(c, format!("run_ignored: {}", config.run_ignored));
501-
logv(c, format!("filters: {:?}", config.filters));
502-
logv(c, format!("skip: {:?}", config.skip));
503-
logv(c, format!("filter_exact: {}", config.filter_exact));
504-
logv(
505-
c,
506-
format!("force_pass_mode: {}", opt_str(&config.force_pass_mode.map(|m| format!("{}", m))),),
507-
);
508-
logv(c, format!("runner: {}", opt_str(&config.runner)));
509-
logv(c, format!("host-rustcflags: {:?}", config.host_rustcflags));
510-
logv(c, format!("target-rustcflags: {:?}", config.target_rustcflags));
511-
logv(c, format!("target: {}", config.target));
512-
logv(c, format!("host: {}", config.host));
513-
logv(c, format!("android-cross-path: {}", config.android_cross_path));
514-
logv(c, format!("adb_path: {}", config.adb_path));
515-
logv(c, format!("adb_test_dir: {}", config.adb_test_dir));
516-
logv(c, format!("adb_device_status: {}", config.adb_device_status));
517-
logv(c, format!("ar: {}", config.ar));
518-
logv(c, format!("target-linker: {:?}", config.target_linker));
519-
logv(c, format!("host-linker: {:?}", config.host_linker));
520-
logv(c, format!("verbose: {}", config.verbose));
521-
logv(c, format!("minicore_path: {}", config.minicore_path));
522-
logv(c, "\n".to_string());
523-
}
524-
525479
pub fn opt_str(maybestr: &Option<String>) -> &str {
526480
match *maybestr {
527481
None => "(none)",
@@ -538,6 +492,8 @@ pub fn opt_str2(maybestr: Option<String>) -> String {
538492

539493
/// Called by `main` after the config has been parsed.
540494
pub fn run_tests(config: Arc<Config>) {
495+
debug!(?config, "run_tests");
496+
541497
// If we want to collect rustfix coverage information,
542498
// we first make sure that the coverage file does not exist.
543499
// It will be created later on.

0 commit comments

Comments
 (0)