Skip to content

Commit 8cc918a

Browse files
committed
Improve the docstrings of the Lto struct.
1 parent a70fbf6 commit 8cc918a

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

compiler/rustc_session/src/config.rs

+7-5
Original file line numberDiff line numberDiff line change
@@ -75,19 +75,21 @@ impl_stable_hash_via_hash!(OptLevel);
7575

7676
/// This is what the `LtoCli` values get mapped to after resolving defaults and
7777
/// and taking other command line options into account.
78+
///
79+
/// Note that linker plugin-based LTO is a different mechanism entirely.
7880
#[derive(Clone, PartialEq)]
7981
pub enum Lto {
80-
/// Don't do any LTO whatsoever
82+
/// Don't do any LTO whatsoever.
8183
No,
8284

83-
/// Do a full crate graph LTO with ThinLTO
85+
/// Do a full-crate-graph (inter-crate) LTO with ThinLTO.
8486
Thin,
8587

86-
/// Do a local graph LTO with ThinLTO (only relevant for multiple codegen
87-
/// units).
88+
/// Do a local ThinLTO (intra-crate, over the CodeGen Units of the local crate only). This is
89+
/// only relevant if multiple CGUs are used.
8890
ThinLocal,
8991

90-
/// Do a full crate graph LTO with "fat" LTO
92+
/// Do a full-crate-graph (inter-crate) LTO with "fat" LTO.
9193
Fat,
9294
}
9395

0 commit comments

Comments
 (0)