diff --git a/config.toml.example b/config.toml.example index 01952b21ba4..5d198abe1c7 100644 --- a/config.toml.example +++ b/config.toml.example @@ -341,7 +341,10 @@ # Debuginfo for tests run with compiletest is not controlled by this option # and needs to be enabled separately with `debuginfo-level-tests`. # -# Defaults to 2 if debug is true +# Note that debuginfo-level = 2 generates several gigabytes of debuginfo +# and will slow down the linking process significantly. +# +# Defaults to 1 if debug is true #debuginfo-level = 0 # Debuginfo level for the compiler. diff --git a/src/bootstrap/config.rs b/src/bootstrap/config.rs index d71f3170420..d64ca95d243 100644 --- a/src/bootstrap/config.rs +++ b/src/bootstrap/config.rs @@ -734,7 +734,7 @@ impl Config { let with_defaults = |debuginfo_level_specific: Option| { debuginfo_level_specific.or(debuginfo_level).unwrap_or(if debug == Some(true) { - 2 + 1 } else { 0 })