Add -Zcross-crate-inline-threshold=yes

This commit is contained in:
Ben Kimock 2023-11-06 19:55:05 -05:00
parent aea82b268a
commit fcdd99edca
10 changed files with 161 additions and 13 deletions

View file

@ -3161,10 +3161,10 @@ impl PpMode {
pub(crate) mod dep_tracking {
use super::{
BranchProtection, CFGuard, CFProtection, CrateType, DebugInfo, DebugInfoCompression,
ErrorOutputType, InstrumentCoverage, InstrumentXRay, LinkerPluginLto, LocationDetail,
LtoCli, OomStrategy, OptLevel, OutFileName, OutputType, OutputTypes, Polonius,
RemapPathScopeComponents, ResolveDocLinks, SourceFileHashAlgorithm, SplitDwarfKind,
SwitchWithOptPath, SymbolManglingVersion, TraitSolver, TrimmedDefPaths,
ErrorOutputType, InliningThreshold, InstrumentCoverage, InstrumentXRay, LinkerPluginLto,
LocationDetail, LtoCli, OomStrategy, OptLevel, OutFileName, OutputType, OutputTypes,
Polonius, RemapPathScopeComponents, ResolveDocLinks, SourceFileHashAlgorithm,
SplitDwarfKind, SwitchWithOptPath, SymbolManglingVersion, TraitSolver, TrimmedDefPaths,
};
use crate::lint;
use crate::options::WasiExecModel;
@ -3270,6 +3270,7 @@ pub(crate) mod dep_tracking {
LanguageIdentifier,
TraitSolver,
Polonius,
InliningThreshold,
);
impl<T1, T2> DepTrackingHash for (T1, T2)
@ -3435,3 +3436,16 @@ impl Polonius {
matches!(self, Polonius::Next)
}
}
#[derive(Clone, Copy, PartialEq, Hash, Debug)]
pub enum InliningThreshold {
Always,
Sometimes(usize),
Never,
}
impl Default for InliningThreshold {
fn default() -> Self {
Self::Sometimes(100)
}
}