Skip to main content

rustc_session/
options.rs

1use std::collections::BTreeMap;
2use std::num::{IntErrorKind, NonZero};
3use std::path::PathBuf;
4use std::str;
5
6use rustc_abi::Align;
7use rustc_data_structures::fx::FxIndexMap;
8use rustc_data_structures::profiling::TimePassesFormat;
9use rustc_data_structures::stable_hasher::StableHasher;
10use rustc_errors::{ColorConfig, LanguageIdentifier, TerminalUrl};
11use rustc_feature::UnstableFeatures;
12use rustc_hashes::Hash64;
13use rustc_hir::attrs::CollapseMacroDebuginfo;
14use rustc_macros::{BlobDecodable, Encodable};
15use rustc_span::edition::Edition;
16use rustc_span::{RealFileName, RemapPathScopeComponents, SourceFileHashAlgorithm};
17use rustc_target::spec::{
18    CodeModel, FramePointer, LinkerFlavorCli, MergeFunctions, OnBrokenPipe, PanicStrategy,
19    RelocModel, RelroLevel, SanitizerSet, SplitDebuginfo, StackProtector, SymbolVisibility,
20    TargetTuple, TlsModel,
21};
22
23use crate::config::*;
24use crate::search_paths::SearchPath;
25use crate::utils::NativeLib;
26use crate::{EarlyDiagCtxt, Session, lint};
27
28macro_rules! insert {
29    ($opt_name:ident, $opt_expr:expr, $sub_hashes:expr) => {
30        if $sub_hashes
31            .insert(stringify!($opt_name), $opt_expr as &dyn dep_tracking::DepTrackingHash)
32            .is_some()
33        {
34            panic!("duplicate key in CLI DepTrackingHash: {}", stringify!($opt_name))
35        }
36    };
37}
38
39macro_rules! hash_opt {
40    ($opt_name:ident, $opt_expr:expr, $sub_hashes:expr, $_for_crate_hash: ident, [UNTRACKED]) => {{}};
41    ($opt_name:ident, $opt_expr:expr, $sub_hashes:expr, $_for_crate_hash: ident, [TRACKED]) => {{ insert!($opt_name, $opt_expr, $sub_hashes) }};
42    ($opt_name:ident, $opt_expr:expr, $sub_hashes:expr, $for_crate_hash: ident, [TRACKED_NO_CRATE_HASH]) => {{
43        if !$for_crate_hash {
44            insert!($opt_name, $opt_expr, $sub_hashes)
45        }
46    }};
47    ($opt_name:ident, $opt_expr:expr, $sub_hashes:expr, $_for_crate_hash: ident, [SUBSTRUCT]) => {{}};
48}
49
50macro_rules! hash_substruct {
51    ($opt_name:ident, $opt_expr:expr, $error_format:expr, $for_crate_hash:expr, $hasher:expr, [UNTRACKED]) => {{}};
52    ($opt_name:ident, $opt_expr:expr, $error_format:expr, $for_crate_hash:expr, $hasher:expr, [TRACKED]) => {{}};
53    ($opt_name:ident, $opt_expr:expr, $error_format:expr, $for_crate_hash:expr, $hasher:expr, [TRACKED_NO_CRATE_HASH]) => {{}};
54    ($opt_name:ident, $opt_expr:expr, $error_format:expr, $for_crate_hash:expr, $hasher:expr, [SUBSTRUCT]) => {
55        use crate::config::dep_tracking::DepTrackingHash;
56        $opt_expr.dep_tracking_hash($for_crate_hash, $error_format).hash(
57            $hasher,
58            $error_format,
59            $for_crate_hash,
60        );
61    };
62}
63
64/// Extended target modifier info.
65/// For example, when external target modifier is '-Zregparm=2':
66/// Target modifier enum value + user value ('2') from external crate
67/// is converted into description: prefix ('Z'), name ('regparm'), tech value ('Some(2)').
68pub struct ExtendedTargetModifierInfo {
69    /// Flag prefix (usually, 'C' for codegen flags or 'Z' for unstable flags)
70    pub prefix: String,
71    /// Flag name
72    pub name: String,
73    /// Flag parsed technical value
74    pub tech_value: String,
75}
76
77/// A recorded -Zopt_name=opt_value (or -Copt_name=opt_value)
78/// which alter the ABI or effectiveness of exploit mitigations.
79#[derive(#[automatically_derived]
impl ::core::fmt::Debug for TargetModifier {
    #[inline]
    fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
        ::core::fmt::Formatter::debug_struct_field2_finish(f,
            "TargetModifier", "opt", &self.opt, "value_name",
            &&self.value_name)
    }
}Debug, #[automatically_derived]
impl ::core::clone::Clone for TargetModifier {
    #[inline]
    fn clone(&self) -> TargetModifier {
        TargetModifier {
            opt: ::core::clone::Clone::clone(&self.opt),
            value_name: ::core::clone::Clone::clone(&self.value_name),
        }
    }
}Clone, #[automatically_derived]
impl ::core::cmp::PartialEq for TargetModifier {
    #[inline]
    fn eq(&self, other: &TargetModifier) -> bool {
        self.opt == other.opt && self.value_name == other.value_name
    }
}PartialEq, #[automatically_derived]
impl ::core::cmp::Eq for TargetModifier {
    #[inline]
    #[doc(hidden)]
    #[coverage(off)]
    fn assert_receiver_is_total_eq(&self) {
        let _: ::core::cmp::AssertParamIsEq<OptionsTargetModifiers>;
        let _: ::core::cmp::AssertParamIsEq<String>;
    }
}Eq, #[automatically_derived]
impl ::core::cmp::PartialOrd for TargetModifier {
    #[inline]
    fn partial_cmp(&self, other: &TargetModifier)
        -> ::core::option::Option<::core::cmp::Ordering> {
        match ::core::cmp::PartialOrd::partial_cmp(&self.opt, &other.opt) {
            ::core::option::Option::Some(::core::cmp::Ordering::Equal) =>
                ::core::cmp::PartialOrd::partial_cmp(&self.value_name,
                    &other.value_name),
            cmp => cmp,
        }
    }
}PartialOrd, #[automatically_derived]
impl ::core::cmp::Ord for TargetModifier {
    #[inline]
    fn cmp(&self, other: &TargetModifier) -> ::core::cmp::Ordering {
        match ::core::cmp::Ord::cmp(&self.opt, &other.opt) {
            ::core::cmp::Ordering::Equal =>
                ::core::cmp::Ord::cmp(&self.value_name, &other.value_name),
            cmp => cmp,
        }
    }
}Ord, const _: () =
    {
        impl<__E: ::rustc_span::SpanEncoder> ::rustc_serialize::Encodable<__E>
            for TargetModifier {
            fn encode(&self, __encoder: &mut __E) {
                match *self {
                    TargetModifier {
                        opt: ref __binding_0, value_name: ref __binding_1 } => {
                        ::rustc_serialize::Encodable::<__E>::encode(__binding_0,
                            __encoder);
                        ::rustc_serialize::Encodable::<__E>::encode(__binding_1,
                            __encoder);
                    }
                }
            }
        }
    };Encodable, const _: () =
    {
        impl<__D: ::rustc_span::BlobDecoder> ::rustc_serialize::Decodable<__D>
            for TargetModifier {
            fn decode(__decoder: &mut __D) -> Self {
                TargetModifier {
                    opt: ::rustc_serialize::Decodable::decode(__decoder),
                    value_name: ::rustc_serialize::Decodable::decode(__decoder),
                }
            }
        }
    };BlobDecodable)]
80pub struct TargetModifier {
81    /// Option enum value
82    pub opt: OptionsTargetModifiers,
83    /// User-provided option value (before parsing)
84    pub value_name: String,
85}
86
87mod target_modifier_consistency_check {
88    use super::*;
89    pub(super) fn sanitizer(l: &TargetModifier, r: Option<&TargetModifier>) -> bool {
90        let mut lparsed: SanitizerSet = Default::default();
91        let lval = if l.value_name.is_empty() { None } else { Some(l.value_name.as_str()) };
92        parse::parse_sanitizers(&mut lparsed, lval);
93
94        let mut rparsed: SanitizerSet = Default::default();
95        let rval = r.filter(|v| !v.value_name.is_empty()).map(|v| v.value_name.as_str());
96        parse::parse_sanitizers(&mut rparsed, rval);
97
98        // Some sanitizers need to be target modifiers, and some do not.
99        // For now, we should mark all sanitizers as target modifiers except for these:
100        // AddressSanitizer, LeakSanitizer
101        let tmod_sanitizers = SanitizerSet::MEMORY
102            | SanitizerSet::THREAD
103            | SanitizerSet::HWADDRESS
104            | SanitizerSet::CFI
105            | SanitizerSet::MEMTAG
106            | SanitizerSet::SHADOWCALLSTACK
107            | SanitizerSet::KCFI
108            | SanitizerSet::KERNELADDRESS
109            | SanitizerSet::SAFESTACK
110            | SanitizerSet::DATAFLOW;
111
112        lparsed & tmod_sanitizers == rparsed & tmod_sanitizers
113    }
114    pub(super) fn sanitizer_cfi_normalize_integers(
115        sess: &Session,
116        l: &TargetModifier,
117        r: Option<&TargetModifier>,
118    ) -> bool {
119        // For kCFI, the helper flag -Zsanitizer-cfi-normalize-integers should also be a target modifier
120        if sess.sanitizers().contains(SanitizerSet::KCFI) {
121            if let Some(r) = r {
122                return l.extend().tech_value == r.extend().tech_value;
123            } else {
124                return false;
125            }
126        }
127        true
128    }
129}
130
131impl TargetModifier {
132    pub fn extend(&self) -> ExtendedTargetModifierInfo {
133        self.opt.reparse(&self.value_name)
134    }
135    // Custom consistency check for target modifiers (or default `l.tech_value == r.tech_value`)
136    // When other is None, consistency with default value is checked
137    pub fn consistent(&self, sess: &Session, other: Option<&TargetModifier>) -> bool {
138        if !(other.is_none() || self.opt == other.unwrap().opt) {
    ::core::panicking::panic("assertion failed: other.is_none() || self.opt == other.unwrap().opt")
};assert!(other.is_none() || self.opt == other.unwrap().opt);
139        match self.opt {
140            OptionsTargetModifiers::UnstableOptions(unstable) => match unstable {
141                UnstableOptionsTargetModifiers::sanitizer => {
142                    return target_modifier_consistency_check::sanitizer(self, other);
143                }
144                UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers => {
145                    return target_modifier_consistency_check::sanitizer_cfi_normalize_integers(
146                        sess, self, other,
147                    );
148                }
149                _ => {}
150            },
151            _ => {}
152        };
153        match other {
154            Some(other) => self.extend().tech_value == other.extend().tech_value,
155            None => false,
156        }
157    }
158}
159
160fn tmod_push_impl(
161    opt: OptionsTargetModifiers,
162    tmod_vals: &BTreeMap<OptionsTargetModifiers, String>,
163    tmods: &mut Vec<TargetModifier>,
164) {
165    if let Some(v) = tmod_vals.get(&opt) {
166        tmods.push(TargetModifier { opt, value_name: v.clone() })
167    }
168}
169
170macro_rules! tmod_push {
171    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr) => {
172        if *$opt_expr != $init {
173            tmod_push_impl(
174                OptionsTargetModifiers::$struct_name($tmod_enum_name::$opt_name),
175                $tmod_vals,
176                $mods,
177            );
178        }
179    };
180}
181
182macro_rules! gather_tmods {
183    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
184        [SUBSTRUCT], [TARGET_MODIFIER]) => {
185        compile_error!("SUBSTRUCT can't be target modifier");
186    };
187    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
188        [UNTRACKED], [TARGET_MODIFIER]) => {
189        tmod_push!($struct_name, $tmod_enum_name, $opt_name, $opt_expr, $init, $mods, $tmod_vals)
190    };
191    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
192        [TRACKED], [TARGET_MODIFIER]) => {
193        tmod_push!($struct_name, $tmod_enum_name, $opt_name, $opt_expr, $init, $mods, $tmod_vals)
194    };
195    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
196        [TRACKED_NO_CRATE_HASH], [TARGET_MODIFIER]) => {
197        tmod_push!($struct_name, $tmod_enum_name, $opt_name, $opt_expr, $init, $mods, $tmod_vals)
198    };
199    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
200        [SUBSTRUCT], []) => {
201        $opt_expr.gather_target_modifiers($mods, $tmod_vals);
202    };
203    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
204        [UNTRACKED], []) => {{}};
205    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
206        [TRACKED], []) => {{}};
207    ($struct_name:ident, $tmod_enum_name:ident, $opt_name:ident, $opt_expr:expr, $init:expr, $mods:expr, $tmod_vals:expr,
208        [TRACKED_NO_CRATE_HASH], []) => {{}};
209}
210
211macro_rules! gather_tmods_top_level {
212    ($_opt_name:ident, $opt_expr:expr, $mods:expr, $tmod_vals:expr, [SUBSTRUCT $substruct_enum:ident]) => {
213        $opt_expr.gather_target_modifiers($mods, $tmod_vals);
214    };
215    ($opt_name:ident, $opt_expr:expr, $mods:expr, $tmod_vals:expr, [$non_substruct:ident TARGET_MODIFIER]) => {
216        compile_error!("Top level option can't be target modifier");
217    };
218    ($opt_name:ident, $opt_expr:expr, $mods:expr, $tmod_vals:expr, [$non_substruct:ident]) => {};
219}
220
221/// Macro for generating OptionsTargetsModifiers top-level enum with impl.
222/// Will generate something like:
223/// ```rust,ignore (illustrative)
224/// pub enum OptionsTargetModifiers {
225///     CodegenOptions(CodegenOptionsTargetModifiers),
226///     UnstableOptions(UnstableOptionsTargetModifiers),
227/// }
228/// impl OptionsTargetModifiers {
229///     pub fn reparse(&self, user_value: &str) -> ExtendedTargetModifierInfo {
230///         match self {
231///             Self::CodegenOptions(v) => v.reparse(user_value),
232///             Self::UnstableOptions(v) => v.reparse(user_value),
233///         }
234///     }
235///     pub fn is_target_modifier(flag_name: &str) -> bool {
236///         CodegenOptionsTargetModifiers::is_target_modifier(flag_name) ||
237///         UnstableOptionsTargetModifiers::is_target_modifier(flag_name)
238///     }
239/// }
240/// ```
241macro_rules! top_level_tmod_enum {
242    ($( {$($optinfo:tt)*} ),* $(,)*) => {
243        top_level_tmod_enum! { @parse {}, (user_value){}; $($($optinfo)*|)* }
244    };
245    // Termination
246    (
247        @parse
248        {$($variant:tt($substruct_enum:tt))*},
249        ($user_value:ident){$($pout:tt)*};
250    ) => {
251        #[allow(non_camel_case_types)]
252        #[derive(PartialEq, Eq, PartialOrd, Ord, Debug, Copy, Clone, Encodable, BlobDecodable)]
253        pub enum OptionsTargetModifiers {
254            $($variant($substruct_enum)),*
255        }
256        impl OptionsTargetModifiers {
257            #[allow(unused_variables)]
258            pub fn reparse(&self, $user_value: &str) -> ExtendedTargetModifierInfo {
259                #[allow(unreachable_patterns)]
260                match self {
261                    $($pout)*
262                    _ => panic!("unknown target modifier option: {:?}", *self)
263                }
264            }
265            pub fn is_target_modifier(flag_name: &str) -> bool {
266                $($substruct_enum::is_target_modifier(flag_name))||*
267            }
268        }
269    };
270    // Adding SUBSTRUCT option group into $eout
271    (
272        @parse {$($eout:tt)*}, ($puser_value:ident){$($pout:tt)*};
273            [SUBSTRUCT $substruct_enum:ident $variant:ident] |
274        $($tail:tt)*
275    ) => {
276        top_level_tmod_enum! {
277            @parse
278            {
279                $($eout)*
280                $variant($substruct_enum)
281            },
282            ($puser_value){
283                $($pout)*
284                Self::$variant(v) => v.reparse($puser_value),
285            };
286            $($tail)*
287        }
288    };
289    // Skipping non-target-modifier and non-substruct
290    (
291        @parse {$($eout:tt)*}, ($puser_value:ident){$($pout:tt)*};
292            [$non_substruct:ident] |
293        $($tail:tt)*
294    ) => {
295        top_level_tmod_enum! {
296            @parse
297            {
298                $($eout)*
299            },
300            ($puser_value){
301                $($pout)*
302            };
303            $($tail)*
304        }
305    };
306}
307
308macro_rules! top_level_options {
309    ( $( #[$top_level_attr:meta] )* pub struct Options { $(
310        $( #[$attr:meta] )*
311        $opt:ident : $t:ty [$dep_tracking_marker:ident $( $tmod:ident $variant:ident )?],
312    )* } ) => (
313        top_level_tmod_enum!( {$([$dep_tracking_marker $($tmod $variant),*])|*} );
314
315        #[derive(Clone)]
316        $( #[$top_level_attr] )*
317        pub struct Options {
318            $(
319                $( #[$attr] )*
320                pub $opt: $t
321            ),*,
322            pub target_modifiers: BTreeMap<OptionsTargetModifiers, String>,
323        }
324
325        impl Options {
326            pub fn dep_tracking_hash(&self, for_crate_hash: bool) -> Hash64 {
327                let mut sub_hashes = BTreeMap::new();
328                $({
329                    hash_opt!($opt,
330                                &self.$opt,
331                                &mut sub_hashes,
332                                for_crate_hash,
333                                [$dep_tracking_marker]);
334                })*
335                let mut hasher = StableHasher::new();
336                dep_tracking::stable_hash(sub_hashes,
337                                          &mut hasher,
338                                          self.error_format,
339                                          for_crate_hash);
340                $({
341                    hash_substruct!($opt,
342                        &self.$opt,
343                        self.error_format,
344                        for_crate_hash,
345                        &mut hasher,
346                        [$dep_tracking_marker]);
347                })*
348                hasher.finish()
349            }
350
351            pub fn gather_target_modifiers(&self) -> Vec<TargetModifier> {
352                let mut mods = Vec::<TargetModifier>::new();
353                $({
354                    gather_tmods_top_level!($opt,
355                        &self.$opt, &mut mods, &self.target_modifiers,
356                        [$dep_tracking_marker $($tmod),*]);
357                })*
358                mods.sort_by(|a, b| a.opt.cmp(&b.opt));
359                mods
360            }
361        }
362    );
363}
364
365#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialEq for OptionsTargetModifiers {
    #[inline]
    fn eq(&self, other: &OptionsTargetModifiers) -> bool {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        __self_discr == __arg1_discr &&
            match (self, other) {
                (OptionsTargetModifiers::UnstableOptions(__self_0),
                    OptionsTargetModifiers::UnstableOptions(__arg1_0)) =>
                    __self_0 == __arg1_0,
                (OptionsTargetModifiers::CodegenOptions(__self_0),
                    OptionsTargetModifiers::CodegenOptions(__arg1_0)) =>
                    __self_0 == __arg1_0,
                _ => unsafe { ::core::intrinsics::unreachable() }
            }
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Eq for OptionsTargetModifiers {
    #[inline]
    #[doc(hidden)]
    #[coverage(off)]
    fn assert_receiver_is_total_eq(&self) {
        let _: ::core::cmp::AssertParamIsEq<UnstableOptionsTargetModifiers>;
        let _: ::core::cmp::AssertParamIsEq<CodegenOptionsTargetModifiers>;
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialOrd for OptionsTargetModifiers {
    #[inline]
    fn partial_cmp(&self, other: &OptionsTargetModifiers)
        -> ::core::option::Option<::core::cmp::Ordering> {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        match (self, other) {
            (OptionsTargetModifiers::UnstableOptions(__self_0),
                OptionsTargetModifiers::UnstableOptions(__arg1_0)) =>
                ::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
            (OptionsTargetModifiers::CodegenOptions(__self_0),
                OptionsTargetModifiers::CodegenOptions(__arg1_0)) =>
                ::core::cmp::PartialOrd::partial_cmp(__self_0, __arg1_0),
            _ =>
                ::core::cmp::PartialOrd::partial_cmp(&__self_discr,
                    &__arg1_discr),
        }
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Ord for OptionsTargetModifiers {
    #[inline]
    fn cmp(&self, other: &OptionsTargetModifiers) -> ::core::cmp::Ordering {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        match ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr) {
            ::core::cmp::Ordering::Equal =>
                match (self, other) {
                    (OptionsTargetModifiers::UnstableOptions(__self_0),
                        OptionsTargetModifiers::UnstableOptions(__arg1_0)) =>
                        ::core::cmp::Ord::cmp(__self_0, __arg1_0),
                    (OptionsTargetModifiers::CodegenOptions(__self_0),
                        OptionsTargetModifiers::CodegenOptions(__arg1_0)) =>
                        ::core::cmp::Ord::cmp(__self_0, __arg1_0),
                    _ => unsafe { ::core::intrinsics::unreachable() }
                },
            cmp => cmp,
        }
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::fmt::Debug for OptionsTargetModifiers {
    #[inline]
    fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
        match self {
            OptionsTargetModifiers::UnstableOptions(__self_0) =>
                ::core::fmt::Formatter::debug_tuple_field1_finish(f,
                    "UnstableOptions", &__self_0),
            OptionsTargetModifiers::CodegenOptions(__self_0) =>
                ::core::fmt::Formatter::debug_tuple_field1_finish(f,
                    "CodegenOptions", &__self_0),
        }
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::marker::Copy for OptionsTargetModifiers { }
#[automatically_derived]
#[doc(hidden)]
#[allow(non_camel_case_types)]
unsafe impl ::core::clone::TrivialClone for OptionsTargetModifiers { }
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::clone::Clone for OptionsTargetModifiers {
    #[inline]
    fn clone(&self) -> OptionsTargetModifiers {
        let _:
                ::core::clone::AssertParamIsClone<UnstableOptionsTargetModifiers>;
        let _:
                ::core::clone::AssertParamIsClone<CodegenOptionsTargetModifiers>;
        *self
    }
}
const _: () =
    {
        impl<__E: ::rustc_span::SpanEncoder> ::rustc_serialize::Encodable<__E>
            for OptionsTargetModifiers {
            fn encode(&self, __encoder: &mut __E) {
                let disc =
                    match *self {
                        OptionsTargetModifiers::UnstableOptions(ref __binding_0) =>
                            {
                            0usize
                        }
                        OptionsTargetModifiers::CodegenOptions(ref __binding_0) => {
                            1usize
                        }
                    };
                ::rustc_serialize::Encoder::emit_u8(__encoder, disc as u8);
                match *self {
                    OptionsTargetModifiers::UnstableOptions(ref __binding_0) =>
                        {
                        ::rustc_serialize::Encodable::<__E>::encode(__binding_0,
                            __encoder);
                    }
                    OptionsTargetModifiers::CodegenOptions(ref __binding_0) => {
                        ::rustc_serialize::Encodable::<__E>::encode(__binding_0,
                            __encoder);
                    }
                }
            }
        }
    };
const _: () =
    {
        impl<__D: ::rustc_span::BlobDecoder> ::rustc_serialize::Decodable<__D>
            for OptionsTargetModifiers {
            fn decode(__decoder: &mut __D) -> Self {
                match ::rustc_serialize::Decoder::read_u8(__decoder) as usize
                    {
                    0usize => {
                        OptionsTargetModifiers::UnstableOptions(::rustc_serialize::Decodable::decode(__decoder))
                    }
                    1usize => {
                        OptionsTargetModifiers::CodegenOptions(::rustc_serialize::Decodable::decode(__decoder))
                    }
                    n => {
                        ::core::panicking::panic_fmt(format_args!("invalid enum variant tag while decoding `OptionsTargetModifiers`, expected 0..2, actual {0}",
                                n));
                    }
                }
            }
        }
    };
impl OptionsTargetModifiers {
    #[allow(unused_variables)]
    pub fn reparse(&self, user_value: &str) -> ExtendedTargetModifierInfo {

        #[allow(unreachable_patterns)]
        match self {
            Self::UnstableOptions(v) => v.reparse(user_value),
            Self::CodegenOptions(v) => v.reparse(user_value),
            _ => {
                ::core::panicking::panic_fmt(format_args!("unknown target modifier option: {0:?}",
                        *self));
            }
        }
    }
    pub fn is_target_modifier(flag_name: &str) -> bool {
        UnstableOptionsTargetModifiers::is_target_modifier(flag_name) ||
            CodegenOptionsTargetModifiers::is_target_modifier(flag_name)
    }
}
#[doc = r" The top-level command-line options struct."]
#[doc = r""]
#[doc =
r" For each option, one has to specify how it behaves with regard to the"]
#[doc =
r" dependency tracking system of incremental compilation. This is done via the"]
#[doc = r" square-bracketed directive after the field type. The options are:"]
#[doc = r""]
#[doc = r" - `[TRACKED]`"]
#[doc =
r" A change in the given field will cause the compiler to completely clear the"]
#[doc = r" incremental compilation cache before proceeding."]
#[doc = r""]
#[doc = r" - `[TRACKED_NO_CRATE_HASH]`"]
#[doc =
r" Same as `[TRACKED]`, but will not affect the crate hash. This is useful for options that"]
#[doc = r" only affect the incremental cache."]
#[doc = r""]
#[doc = r" - `[UNTRACKED]`"]
#[doc = r" Incremental compilation is not influenced by this option."]
#[doc = r""]
#[doc = r" - `[SUBSTRUCT]`"]
#[doc = r" Second-level sub-structs containing more options."]
#[doc = r""]
#[doc =
r" If you add a new option to this struct or one of the sub-structs like"]
#[doc =
r" `CodegenOptions`, think about how it influences incremental compilation. If in"]
#[doc =
r#" doubt, specify `[TRACKED]`, which is always "correct" but might lead to"#]
#[doc = r" unnecessary re-compilation."]
#[rustc_lint_opt_ty]
pub struct Options {
    #[doc =
    r" The crate config requested for the session, which may be combined"]
    #[doc =
    r" with additional crate configurations during the compile process."]
    #[rustc_lint_opt_deny_field_access("use `TyCtxt::crate_types` instead of this field")]
    pub crate_types: Vec<CrateType>,
    pub optimize: OptLevel,
    #[doc =
    r" Include the `debug_assertions` flag in dependency tracking, since it"]
    #[doc = r" can influence whether overflow checks are done or not."]
    pub debug_assertions: bool,
    pub debuginfo: DebugInfo,
    pub lint_opts: Vec<(String, lint::Level)>,
    pub lint_cap: Option<lint::Level>,
    pub describe_lints: bool,
    pub output_types: OutputTypes,
    pub search_paths: Vec<SearchPath>,
    pub libs: Vec<NativeLib>,
    pub sysroot: Sysroot,
    pub target_triple: TargetTuple,
    #[doc =
    r" Effective logical environment used by `env!`/`option_env!` macros"]
    pub logical_env: FxIndexMap<String, String>,
    pub test: bool,
    pub error_format: ErrorOutputType,
    pub diagnostic_width: Option<usize>,
    #[doc = r" If `Some`, enable incremental compilation, using the given"]
    #[doc = r" directory to store intermediate results."]
    pub incremental: Option<PathBuf>,
    pub assert_incr_state: Option<IncrementalStateAssertion>,
    #[doc = r" Set by the `Config::hash_untracked_state` callback for custom"]
    #[doc = r" drivers to invalidate the incremental cache"]
    #[rustc_lint_opt_deny_field_access("should only be used via `Config::hash_untracked_state`")]
    pub untracked_state_hash: Hash64,
    pub unstable_opts: UnstableOptions,
    pub prints: Vec<PrintRequest>,
    pub cg: CodegenOptions,
    pub externs: Externs,
    pub crate_name: Option<String>,
    #[doc = r" Indicates how the compiler should treat unstable features."]
    pub unstable_features: UnstableFeatures,
    #[doc =
    r" Indicates whether this run of the compiler is actually rustdoc. This"]
    #[doc =
    r" is currently just a hack and will be removed eventually, so please"]
    #[doc = r" try to not rely on this too much."]
    pub actually_rustdoc: bool,
    #[doc = r" Whether name resolver should resolve documentation links."]
    pub resolve_doc_links: ResolveDocLinks,
    #[doc = r" Control path trimming."]
    pub trimmed_def_paths: bool,
    #[doc =
    r" Specifications of codegen units / ThinLTO which are forced as a"]
    #[doc =
    r" result of parsing command line options. These are not necessarily"]
    #[doc = r" what rustc was invoked with, but massaged a bit to agree with"]
    #[doc =
    r" commands like `--emit llvm-ir` which they're often incompatible with"]
    #[doc = r" if we otherwise use the defaults of rustc."]
    #[rustc_lint_opt_deny_field_access("use `Session::codegen_units` instead of this field")]
    pub cli_forced_codegen_units: Option<usize>,
    #[rustc_lint_opt_deny_field_access("use `Session::lto` instead of this field")]
    pub cli_forced_local_thinlto_off: bool,
    #[doc =
    r" Remap source path prefixes in all output (messages, object files, debug, etc.)."]
    pub remap_path_prefix: Vec<(PathBuf, PathBuf)>,
    #[doc =
    r" Defines which scopes of paths should be remapped by `--remap-path-prefix`."]
    pub remap_path_scope: RemapPathScopeComponents,
    #[doc =
    r" Base directory containing the `library/` directory for the Rust standard library."]
    #[doc = r" Right now it's always `$sysroot/lib/rustlib/src/rust`"]
    #[doc = r" (i.e. the `rustup` `rust-src` component)."]
    #[doc = r""]
    #[doc =
    r" This directory is what the virtual `/rustc/$hash` is translated back to,"]
    #[doc =
    r" if Rust was built with path remapping to `/rustc/$hash` enabled"]
    #[doc = r" (the `rust.remap-debuginfo` option in `bootstrap.toml`)."]
    pub real_rust_source_base_dir: Option<PathBuf>,
    #[doc =
    r" Base directory containing the `compiler/` directory for the rustc sources."]
    #[doc = r" Right now it's always `$sysroot/lib/rustlib/rustc-src/rust`"]
    #[doc = r" (i.e. the `rustup` `rustc-dev` component)."]
    #[doc = r""]
    #[doc =
    r" This directory is what the virtual `/rustc-dev/$hash` is translated back to,"]
    #[doc =
    r" if Rust was built with path remapping to `/rustc/$hash` enabled"]
    #[doc = r" (the `rust.remap-debuginfo` option in `bootstrap.toml`)."]
    pub real_rustc_dev_source_base_dir: Option<PathBuf>,
    pub edition: Edition,
    #[doc =
    r" `true` if we're emitting JSON blobs about each artifact produced"]
    #[doc = r" by the compiler."]
    pub json_artifact_notifications: bool,
    #[doc =
    r" `true` if we're emitting JSON timings with the start and end of"]
    #[doc = r" high-level compilation sections"]
    pub json_timings: bool,
    #[doc =
    r" `true` if we're emitting a JSON blob containing the unused externs"]
    pub json_unused_externs: JsonUnusedExterns,
    #[doc =
    r" `true` if we're emitting a JSON job containing a future-incompat report for lints"]
    pub json_future_incompat: bool,
    pub pretty: Option<PpMode>,
    #[doc = r" The (potentially remapped) working directory"]
    #[rustc_lint_opt_deny_field_access("use `SourceMap::working_dir` instead of this field")]
    pub working_dir: RealFileName,
    pub color: ColorConfig,
    pub verbose: bool,
    pub target_modifiers: BTreeMap<OptionsTargetModifiers, String>,
}
#[automatically_derived]
impl ::core::clone::Clone for Options {
    #[inline]
    fn clone(&self) -> Options {
        Options {
            crate_types: ::core::clone::Clone::clone(&self.crate_types),
            optimize: ::core::clone::Clone::clone(&self.optimize),
            debug_assertions: ::core::clone::Clone::clone(&self.debug_assertions),
            debuginfo: ::core::clone::Clone::clone(&self.debuginfo),
            lint_opts: ::core::clone::Clone::clone(&self.lint_opts),
            lint_cap: ::core::clone::Clone::clone(&self.lint_cap),
            describe_lints: ::core::clone::Clone::clone(&self.describe_lints),
            output_types: ::core::clone::Clone::clone(&self.output_types),
            search_paths: ::core::clone::Clone::clone(&self.search_paths),
            libs: ::core::clone::Clone::clone(&self.libs),
            sysroot: ::core::clone::Clone::clone(&self.sysroot),
            target_triple: ::core::clone::Clone::clone(&self.target_triple),
            logical_env: ::core::clone::Clone::clone(&self.logical_env),
            test: ::core::clone::Clone::clone(&self.test),
            error_format: ::core::clone::Clone::clone(&self.error_format),
            diagnostic_width: ::core::clone::Clone::clone(&self.diagnostic_width),
            incremental: ::core::clone::Clone::clone(&self.incremental),
            assert_incr_state: ::core::clone::Clone::clone(&self.assert_incr_state),
            untracked_state_hash: ::core::clone::Clone::clone(&self.untracked_state_hash),
            unstable_opts: ::core::clone::Clone::clone(&self.unstable_opts),
            prints: ::core::clone::Clone::clone(&self.prints),
            cg: ::core::clone::Clone::clone(&self.cg),
            externs: ::core::clone::Clone::clone(&self.externs),
            crate_name: ::core::clone::Clone::clone(&self.crate_name),
            unstable_features: ::core::clone::Clone::clone(&self.unstable_features),
            actually_rustdoc: ::core::clone::Clone::clone(&self.actually_rustdoc),
            resolve_doc_links: ::core::clone::Clone::clone(&self.resolve_doc_links),
            trimmed_def_paths: ::core::clone::Clone::clone(&self.trimmed_def_paths),
            cli_forced_codegen_units: ::core::clone::Clone::clone(&self.cli_forced_codegen_units),
            cli_forced_local_thinlto_off: ::core::clone::Clone::clone(&self.cli_forced_local_thinlto_off),
            remap_path_prefix: ::core::clone::Clone::clone(&self.remap_path_prefix),
            remap_path_scope: ::core::clone::Clone::clone(&self.remap_path_scope),
            real_rust_source_base_dir: ::core::clone::Clone::clone(&self.real_rust_source_base_dir),
            real_rustc_dev_source_base_dir: ::core::clone::Clone::clone(&self.real_rustc_dev_source_base_dir),
            edition: ::core::clone::Clone::clone(&self.edition),
            json_artifact_notifications: ::core::clone::Clone::clone(&self.json_artifact_notifications),
            json_timings: ::core::clone::Clone::clone(&self.json_timings),
            json_unused_externs: ::core::clone::Clone::clone(&self.json_unused_externs),
            json_future_incompat: ::core::clone::Clone::clone(&self.json_future_incompat),
            pretty: ::core::clone::Clone::clone(&self.pretty),
            working_dir: ::core::clone::Clone::clone(&self.working_dir),
            color: ::core::clone::Clone::clone(&self.color),
            verbose: ::core::clone::Clone::clone(&self.verbose),
            target_modifiers: ::core::clone::Clone::clone(&self.target_modifiers),
        }
    }
}
impl Options {
    pub fn dep_tracking_hash(&self, for_crate_hash: bool) -> Hash64 {
        let mut sub_hashes = BTreeMap::new();
        {
            {
                if (&mut sub_hashes).insert("crate_types",
                            &self.crate_types as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "crate_types"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("optimize",
                            &self.optimize as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "optimize"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debug_assertions",
                            &self.debug_assertions as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debug_assertions"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debuginfo",
                            &self.debuginfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debuginfo"));
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("lint_opts",
                                &self.lint_opts as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "lint_opts"));
                        }
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("lint_cap",
                                &self.lint_cap as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "lint_cap"));
                        }
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("output_types",
                            &self.output_types as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "output_types"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("libs",
                            &self.libs as &dyn dep_tracking::DepTrackingHash).is_some()
                    {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "libs"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("target_triple",
                            &self.target_triple as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "target_triple"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("logical_env",
                            &self.logical_env as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "logical_env"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("test",
                            &self.test as &dyn dep_tracking::DepTrackingHash).is_some()
                    {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "test"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("untracked_state_hash",
                                &self.untracked_state_hash as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "untracked_state_hash"));
                        }
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("crate_name",
                            &self.crate_name as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "crate_name"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("unstable_features",
                            &self.unstable_features as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "unstable_features"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("actually_rustdoc",
                            &self.actually_rustdoc as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "actually_rustdoc"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("resolve_doc_links",
                            &self.resolve_doc_links as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "resolve_doc_links"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("trimmed_def_paths",
                            &self.trimmed_def_paths as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "trimmed_def_paths"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("remap_path_prefix",
                                &self.remap_path_prefix as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "remap_path_prefix"));
                        }
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("remap_path_scope",
                                &self.remap_path_scope as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "remap_path_scope"));
                        }
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("real_rust_source_base_dir",
                                &self.real_rust_source_base_dir as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "real_rust_source_base_dir"));
                        }
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("real_rustc_dev_source_base_dir",
                                &self.real_rustc_dev_source_base_dir as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "real_rustc_dev_source_base_dir"));
                        }
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("edition",
                            &self.edition as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "edition"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("json_artifact_notifications",
                            &self.json_artifact_notifications as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "json_artifact_notifications"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("json_future_incompat",
                            &self.json_future_incompat as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "json_future_incompat"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("working_dir",
                            &self.working_dir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "working_dir"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("verbose",
                                &self.verbose as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "verbose"));
                        }
                    }
                }
            };
        }
        let mut hasher = StableHasher::new();
        dep_tracking::stable_hash(sub_hashes, &mut hasher, self.error_format,
            for_crate_hash);
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            use crate::config::dep_tracking::DepTrackingHash;
            (&self.unstable_opts).dep_tracking_hash(for_crate_hash,
                    self.error_format).hash(&mut hasher, self.error_format,
                for_crate_hash);
            ;
        }
        { {}; }
        {
            use crate::config::dep_tracking::DepTrackingHash;
            (&self.cg).dep_tracking_hash(for_crate_hash,
                    self.error_format).hash(&mut hasher, self.error_format,
                for_crate_hash);
            ;
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        hasher.finish()
    }
    pub fn gather_target_modifiers(&self) -> Vec<TargetModifier> {
        let mut mods = Vec::<TargetModifier>::new();
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        {
            (&self.unstable_opts).gather_target_modifiers(&mut mods,
                &self.target_modifiers);
            ;
        }
        { ; }
        {
            (&self.cg).gather_target_modifiers(&mut mods,
                &self.target_modifiers);
            ;
        }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        { ; }
        mods.sort_by(|a, b| a.opt.cmp(&b.opt));
        mods
    }
}top_level_options!(
366    /// The top-level command-line options struct.
367    ///
368    /// For each option, one has to specify how it behaves with regard to the
369    /// dependency tracking system of incremental compilation. This is done via the
370    /// square-bracketed directive after the field type. The options are:
371    ///
372    /// - `[TRACKED]`
373    /// A change in the given field will cause the compiler to completely clear the
374    /// incremental compilation cache before proceeding.
375    ///
376    /// - `[TRACKED_NO_CRATE_HASH]`
377    /// Same as `[TRACKED]`, but will not affect the crate hash. This is useful for options that
378    /// only affect the incremental cache.
379    ///
380    /// - `[UNTRACKED]`
381    /// Incremental compilation is not influenced by this option.
382    ///
383    /// - `[SUBSTRUCT]`
384    /// Second-level sub-structs containing more options.
385    ///
386    /// If you add a new option to this struct or one of the sub-structs like
387    /// `CodegenOptions`, think about how it influences incremental compilation. If in
388    /// doubt, specify `[TRACKED]`, which is always "correct" but might lead to
389    /// unnecessary re-compilation.
390    #[rustc_lint_opt_ty]
391    pub struct Options {
392        /// The crate config requested for the session, which may be combined
393        /// with additional crate configurations during the compile process.
394        #[rustc_lint_opt_deny_field_access("use `TyCtxt::crate_types` instead of this field")]
395        crate_types: Vec<CrateType> [TRACKED],
396        optimize: OptLevel [TRACKED],
397        /// Include the `debug_assertions` flag in dependency tracking, since it
398        /// can influence whether overflow checks are done or not.
399        debug_assertions: bool [TRACKED],
400        debuginfo: DebugInfo [TRACKED],
401        lint_opts: Vec<(String, lint::Level)> [TRACKED_NO_CRATE_HASH],
402        lint_cap: Option<lint::Level> [TRACKED_NO_CRATE_HASH],
403        describe_lints: bool [UNTRACKED],
404        output_types: OutputTypes [TRACKED],
405        search_paths: Vec<SearchPath> [UNTRACKED],
406        libs: Vec<NativeLib> [TRACKED],
407        sysroot: Sysroot [UNTRACKED],
408
409        target_triple: TargetTuple [TRACKED],
410
411        /// Effective logical environment used by `env!`/`option_env!` macros
412        logical_env: FxIndexMap<String, String> [TRACKED],
413
414        test: bool [TRACKED],
415        error_format: ErrorOutputType [UNTRACKED],
416        diagnostic_width: Option<usize> [UNTRACKED],
417
418        /// If `Some`, enable incremental compilation, using the given
419        /// directory to store intermediate results.
420        incremental: Option<PathBuf> [UNTRACKED],
421        assert_incr_state: Option<IncrementalStateAssertion> [UNTRACKED],
422        /// Set by the `Config::hash_untracked_state` callback for custom
423        /// drivers to invalidate the incremental cache
424        #[rustc_lint_opt_deny_field_access("should only be used via `Config::hash_untracked_state`")]
425        untracked_state_hash: Hash64 [TRACKED_NO_CRATE_HASH],
426
427        unstable_opts: UnstableOptions [SUBSTRUCT UnstableOptionsTargetModifiers UnstableOptions],
428        prints: Vec<PrintRequest> [UNTRACKED],
429        cg: CodegenOptions [SUBSTRUCT CodegenOptionsTargetModifiers CodegenOptions],
430        externs: Externs [UNTRACKED],
431        crate_name: Option<String> [TRACKED],
432        /// Indicates how the compiler should treat unstable features.
433        unstable_features: UnstableFeatures [TRACKED],
434
435        /// Indicates whether this run of the compiler is actually rustdoc. This
436        /// is currently just a hack and will be removed eventually, so please
437        /// try to not rely on this too much.
438        actually_rustdoc: bool [TRACKED],
439        /// Whether name resolver should resolve documentation links.
440        resolve_doc_links: ResolveDocLinks [TRACKED],
441
442        /// Control path trimming.
443        trimmed_def_paths: bool [TRACKED],
444
445        /// Specifications of codegen units / ThinLTO which are forced as a
446        /// result of parsing command line options. These are not necessarily
447        /// what rustc was invoked with, but massaged a bit to agree with
448        /// commands like `--emit llvm-ir` which they're often incompatible with
449        /// if we otherwise use the defaults of rustc.
450        #[rustc_lint_opt_deny_field_access("use `Session::codegen_units` instead of this field")]
451        cli_forced_codegen_units: Option<usize> [UNTRACKED],
452        #[rustc_lint_opt_deny_field_access("use `Session::lto` instead of this field")]
453        cli_forced_local_thinlto_off: bool [UNTRACKED],
454
455        /// Remap source path prefixes in all output (messages, object files, debug, etc.).
456        remap_path_prefix: Vec<(PathBuf, PathBuf)> [TRACKED_NO_CRATE_HASH],
457        /// Defines which scopes of paths should be remapped by `--remap-path-prefix`.
458        remap_path_scope: RemapPathScopeComponents [TRACKED_NO_CRATE_HASH],
459
460        /// Base directory containing the `library/` directory for the Rust standard library.
461        /// Right now it's always `$sysroot/lib/rustlib/src/rust`
462        /// (i.e. the `rustup` `rust-src` component).
463        ///
464        /// This directory is what the virtual `/rustc/$hash` is translated back to,
465        /// if Rust was built with path remapping to `/rustc/$hash` enabled
466        /// (the `rust.remap-debuginfo` option in `bootstrap.toml`).
467        real_rust_source_base_dir: Option<PathBuf> [TRACKED_NO_CRATE_HASH],
468
469        /// Base directory containing the `compiler/` directory for the rustc sources.
470        /// Right now it's always `$sysroot/lib/rustlib/rustc-src/rust`
471        /// (i.e. the `rustup` `rustc-dev` component).
472        ///
473        /// This directory is what the virtual `/rustc-dev/$hash` is translated back to,
474        /// if Rust was built with path remapping to `/rustc/$hash` enabled
475        /// (the `rust.remap-debuginfo` option in `bootstrap.toml`).
476        real_rustc_dev_source_base_dir: Option<PathBuf> [TRACKED_NO_CRATE_HASH],
477
478        edition: Edition [TRACKED],
479
480        /// `true` if we're emitting JSON blobs about each artifact produced
481        /// by the compiler.
482        json_artifact_notifications: bool [TRACKED],
483
484        /// `true` if we're emitting JSON timings with the start and end of
485        /// high-level compilation sections
486        json_timings: bool [UNTRACKED],
487
488        /// `true` if we're emitting a JSON blob containing the unused externs
489        json_unused_externs: JsonUnusedExterns [UNTRACKED],
490
491        /// `true` if we're emitting a JSON job containing a future-incompat report for lints
492        json_future_incompat: bool [TRACKED],
493
494        pretty: Option<PpMode> [UNTRACKED],
495
496        /// The (potentially remapped) working directory
497        #[rustc_lint_opt_deny_field_access("use `SourceMap::working_dir` instead of this field")]
498        working_dir: RealFileName [TRACKED],
499
500        color: ColorConfig [UNTRACKED],
501
502        verbose: bool [TRACKED_NO_CRATE_HASH],
503    }
504);
505
506macro_rules! tmod_enum_opt {
507    ($struct_name:ident, $tmod_enum_name:ident, $opt:ident, $v:ident) => {
508        Some(OptionsTargetModifiers::$struct_name($tmod_enum_name::$opt))
509    };
510    ($struct_name:ident, $tmod_enum_name:ident, $opt:ident, ) => {
511        None
512    };
513}
514
515macro_rules! tmod_enum {
516    ($tmod_enum_name:ident, $prefix:expr, $( {$($optinfo:tt)*} ),* $(,)*) => {
517        tmod_enum! { $tmod_enum_name, $prefix, @parse {}, (user_value){}; $($($optinfo)*|)* }
518    };
519    // Termination
520    (
521        $tmod_enum_name:ident, $prefix:expr,
522        @parse
523        {$($eout:tt)*},
524        ($user_value:ident){$($pout:tt)*};
525    ) => {
526        #[allow(non_camel_case_types)]
527        #[derive(PartialEq, Eq, PartialOrd, Ord, Debug, Copy, Clone, Encodable, BlobDecodable)]
528        pub enum $tmod_enum_name {
529            $($eout),*
530        }
531        impl $tmod_enum_name {
532            #[allow(unused_variables)]
533            pub fn reparse(&self, $user_value: &str) -> ExtendedTargetModifierInfo {
534                #[allow(unreachable_patterns)]
535                match self {
536                    $($pout)*
537                    _ => panic!("unknown target modifier option: {:?}", *self)
538                }
539            }
540            pub fn is_target_modifier(flag_name: &str) -> bool {
541                match flag_name.replace('-', "_").as_str() {
542                    $(stringify!($eout) => true,)*
543                    _ => false,
544                }
545            }
546        }
547    };
548    // Adding target-modifier option into $eout
549    (
550        $tmod_enum_name:ident, $prefix:expr,
551        @parse {$($eout:tt)*}, ($puser_value:ident){$($pout:tt)*};
552            $opt:ident, $parse:ident, $t:ty, [TARGET_MODIFIER] |
553        $($tail:tt)*
554    ) => {
555        tmod_enum! {
556            $tmod_enum_name, $prefix,
557            @parse
558            {
559                $($eout)*
560                $opt
561            },
562            ($puser_value){
563                $($pout)*
564                Self::$opt => {
565                    let mut parsed : $t = Default::default();
566                    let val = if $puser_value.is_empty() { None } else { Some($puser_value) };
567                    parse::$parse(&mut parsed, val);
568                    ExtendedTargetModifierInfo {
569                        prefix: $prefix.to_string(),
570                        name: stringify!($opt).to_string().replace('_', "-"),
571                        tech_value: format!("{:?}", parsed),
572                    }
573                },
574            };
575            $($tail)*
576        }
577    };
578    // Skipping non-target-modifier
579    (
580        $tmod_enum_name:ident, $prefix:expr,
581        @parse {$($eout:tt)*}, ($puser_value:ident){$($pout:tt)*};
582            $opt:ident, $parse:ident, $t:ty, [] |
583        $($tail:tt)*
584    ) => {
585        tmod_enum! {
586            $tmod_enum_name, $prefix,
587            @parse
588            {
589                $($eout)*
590            },
591            ($puser_value){
592                $($pout)*
593            };
594            $($tail)*
595        }
596    };
597}
598
599/// Defines all `CodegenOptions`/`DebuggingOptions` fields and parsers all at once. The goal of this
600/// macro is to define an interface that can be programmatically used by the option parser
601/// to initialize the struct without hardcoding field names all over the place.
602///
603/// The goal is to invoke this macro once with the correct fields, and then this macro generates all
604/// necessary code. The main gotcha of this macro is the `cgsetters` module which is a bunch of
605/// generated code to parse an option into its respective field in the struct. There are a few
606/// hand-written parsers for parsing specific types of values in this module.
607macro_rules! options {
608    ($struct_name:ident, $tmod_enum_name:ident, $stat:ident, $optmod:ident, $prefix:expr, $outputname:expr,
609     $($( #[$attr:meta] )* $opt:ident : $t:ty = (
610        $init:expr,
611        $parse:ident,
612        [$dep_tracking_marker:ident $( $tmod:ident )?],
613        $desc:expr
614        $(, deprecated_do_nothing: $dnn:literal )?)
615     ),* ,) =>
616(
617    #[derive(Clone)]
618    #[rustc_lint_opt_ty]
619    pub struct $struct_name { $( $( #[$attr] )* pub $opt: $t),* }
620
621    tmod_enum!( $tmod_enum_name, $prefix, {$($opt, $parse, $t, [$($tmod),*])|*} );
622
623    impl Default for $struct_name {
624        fn default() -> $struct_name {
625            $struct_name { $($opt: $init),* }
626        }
627    }
628
629    impl $struct_name {
630        pub fn build(
631            early_dcx: &EarlyDiagCtxt,
632            matches: &getopts::Matches,
633            target_modifiers: &mut BTreeMap<OptionsTargetModifiers, String>,
634        ) -> $struct_name {
635            build_options(early_dcx, matches, target_modifiers, $stat, $prefix, $outputname)
636        }
637
638        fn dep_tracking_hash(&self, for_crate_hash: bool, error_format: ErrorOutputType) -> Hash64 {
639            let mut sub_hashes = BTreeMap::new();
640            $({
641                hash_opt!($opt,
642                            &self.$opt,
643                            &mut sub_hashes,
644                            for_crate_hash,
645                            [$dep_tracking_marker]);
646            })*
647            let mut hasher = StableHasher::new();
648            dep_tracking::stable_hash(sub_hashes,
649                                        &mut hasher,
650                                        error_format,
651                                        for_crate_hash
652                                        );
653            hasher.finish()
654        }
655
656        pub fn gather_target_modifiers(
657            &self,
658            _mods: &mut Vec<TargetModifier>,
659            _tmod_vals: &BTreeMap<OptionsTargetModifiers, String>,
660        ) {
661            $({
662                gather_tmods!($struct_name, $tmod_enum_name, $opt, &self.$opt, $init, _mods, _tmod_vals,
663                    [$dep_tracking_marker], [$($tmod),*]);
664            })*
665        }
666    }
667
668    pub const $stat: OptionDescrs<$struct_name> =
669        &[ $( OptionDesc{ name: stringify!($opt), setter: $optmod::$opt,
670            type_desc: desc::$parse, desc: $desc, is_deprecated_and_do_nothing: false $( || $dnn )?,
671            tmod: tmod_enum_opt!($struct_name, $tmod_enum_name, $opt, $($tmod),*) } ),* ];
672
673    mod $optmod {
674    $(
675        pub(super) fn $opt(cg: &mut super::$struct_name, v: Option<&str>) -> bool {
676            super::parse::$parse(&mut redirect_field!(cg.$opt), v)
677        }
678    )*
679    }
680
681) }
682
683impl CodegenOptions {
684    // JUSTIFICATION: defn of the suggested wrapper fn
685    #[allow(rustc::bad_opt_access)]
686    pub fn instrument_coverage(&self) -> InstrumentCoverage {
687        self.instrument_coverage
688    }
689}
690
691// Sometimes different options need to build a common structure.
692// That structure can be kept in one of the options' fields, the others become dummy.
693macro_rules! redirect_field {
694    ($cg:ident.link_arg) => {
695        $cg.link_args
696    };
697    ($cg:ident.pre_link_arg) => {
698        $cg.pre_link_args
699    };
700    ($cg:ident.$field:ident) => {
701        $cg.$field
702    };
703}
704
705type OptionSetter<O> = fn(&mut O, v: Option<&str>) -> bool;
706type OptionDescrs<O> = &'static [OptionDesc<O>];
707
708pub struct OptionDesc<O> {
709    name: &'static str,
710    setter: OptionSetter<O>,
711    // description for return value/type from mod desc
712    type_desc: &'static str,
713    // description for option from options table
714    desc: &'static str,
715    is_deprecated_and_do_nothing: bool,
716    tmod: Option<OptionsTargetModifiers>,
717}
718
719impl<O> OptionDesc<O> {
720    pub fn name(&self) -> &'static str {
721        self.name
722    }
723
724    pub fn desc(&self) -> &'static str {
725        self.desc
726    }
727}
728
729fn build_options<O: Default>(
730    early_dcx: &EarlyDiagCtxt,
731    matches: &getopts::Matches,
732    target_modifiers: &mut BTreeMap<OptionsTargetModifiers, String>,
733    descrs: OptionDescrs<O>,
734    prefix: &str,
735    outputname: &str,
736) -> O {
737    let mut op = O::default();
738    for option in matches.opt_strs(prefix) {
739        let (key, value) = match option.split_once('=') {
740            None => (option, None),
741            Some((k, v)) => (k.to_string(), Some(v)),
742        };
743
744        let option_to_lookup = key.replace('-', "_");
745        match descrs.iter().find(|opt_desc| opt_desc.name == option_to_lookup) {
746            Some(OptionDesc {
747                name: _,
748                setter,
749                type_desc,
750                desc,
751                is_deprecated_and_do_nothing,
752                tmod,
753            }) => {
754                if *is_deprecated_and_do_nothing {
755                    // deprecation works for prefixed options only
756                    if !!prefix.is_empty() {
    ::core::panicking::panic("assertion failed: !prefix.is_empty()")
};assert!(!prefix.is_empty());
757                    early_dcx.early_warn(::alloc::__export::must_use({
        ::alloc::fmt::format(format_args!("`-{0} {1}`: {2}", prefix, key,
                desc))
    })format!("`-{prefix} {key}`: {desc}"));
758                }
759                if !setter(&mut op, value) {
760                    match value {
761                        None => early_dcx.early_fatal(
762                            ::alloc::__export::must_use({
        ::alloc::fmt::format(format_args!("{0} option `{1}` requires {2} ({3} {1}=<value>)",
                outputname, key, type_desc, prefix))
    })format!(
763                                "{outputname} option `{key}` requires {type_desc} ({prefix} {key}=<value>)"
764                            ),
765                        ),
766                        Some(value) => early_dcx.early_fatal(
767                            ::alloc::__export::must_use({
        ::alloc::fmt::format(format_args!("incorrect value `{0}` for {1} option `{2}` - {3} was expected",
                value, outputname, key, type_desc))
    })format!(
768                                "incorrect value `{value}` for {outputname} option `{key}` - {type_desc} was expected"
769                            ),
770                        ),
771                    }
772                }
773                if let Some(tmod) = *tmod {
774                    let v = value.map_or(String::new(), ToOwned::to_owned);
775                    target_modifiers.insert(tmod, v);
776                }
777            }
778            None => early_dcx.early_fatal(::alloc::__export::must_use({
        ::alloc::fmt::format(format_args!("unknown {0} option: `{1}`",
                outputname, key))
    })format!("unknown {outputname} option: `{key}`")),
779        }
780    }
781    op
782}
783
784#[allow(non_upper_case_globals)]
785mod desc {
786    pub(crate) const parse_no_value: &str = "no value";
787    pub(crate) const parse_bool: &str =
788        "one of: `y`, `yes`, `on`, `true`, `n`, `no`, `off` or `false`";
789    pub(crate) const parse_opt_bool: &str = parse_bool;
790    pub(crate) const parse_string: &str = "a string";
791    pub(crate) const parse_opt_string: &str = parse_string;
792    pub(crate) const parse_string_push: &str = parse_string;
793    pub(crate) const parse_opt_langid: &str = "a language identifier";
794    pub(crate) const parse_opt_pathbuf: &str = "a path";
795    pub(crate) const parse_list: &str = "a space-separated list of strings";
796    pub(crate) const parse_list_with_polarity: &str =
797        "a comma-separated list of strings, with elements beginning with + or -";
798    pub(crate) const parse_autodiff: &str = "a comma separated list of settings: `Enable`, `PrintSteps`, `PrintTA`, `PrintTAFn`, `PrintAA`, `PrintPerf`, `PrintModBefore`, `PrintModAfter`, `PrintModFinal`, `PrintPasses`, `NoPostopt`, `LooseTypes`, `Inline`, `NoTT`";
799    pub(crate) const parse_offload: &str =
800        "a comma separated list of settings: `Host=<Absolute-Path>`, `Device`, `Test`";
801    pub(crate) const parse_comma_list: &str = "a comma-separated list of strings";
802    pub(crate) const parse_opt_comma_list: &str = parse_comma_list;
803    pub(crate) const parse_number: &str = "a number";
804    pub(crate) const parse_opt_number: &str = parse_number;
805    pub(crate) const parse_frame_pointer: &str = "one of `true`/`yes`/`on`, `false`/`no`/`off`, or (with -Zunstable-options) `non-leaf` or `always`";
806    pub(crate) const parse_threads: &str = parse_number;
807    pub(crate) const parse_time_passes_format: &str = "`text` (default) or `json`";
808    pub(crate) const parse_passes: &str = "a space-separated list of passes, or `all`";
809    pub(crate) const parse_panic_strategy: &str = "either `unwind`, `abort`, or `immediate-abort`";
810    pub(crate) const parse_on_broken_pipe: &str = "either `kill`, `error`, or `inherit`";
811    pub(crate) const parse_patchable_function_entry: &str = "either two comma separated integers (total_nops,prefix_nops), with prefix_nops <= total_nops, or one integer (total_nops)";
812    pub(crate) const parse_opt_panic_strategy: &str = parse_panic_strategy;
813    pub(crate) const parse_relro_level: &str = "one of: `full`, `partial`, or `off`";
814    pub(crate) const parse_sanitizers: &str = "comma separated list of sanitizers: `address`, `cfi`, `dataflow`, `hwaddress`, `kcfi`, `kernel-address`, `leak`, `memory`, `memtag`, `safestack`, `shadow-call-stack`, `thread`, or 'realtime'";
815    pub(crate) const parse_sanitizer_memory_track_origins: &str = "0, 1, or 2";
816    pub(crate) const parse_cfguard: &str =
817        "either a boolean (`yes`, `no`, `on`, `off`, etc), `checks`, or `nochecks`";
818    pub(crate) const parse_cfprotection: &str = "`none`|`no`|`n` (default), `branch`, `return`, or `full`|`yes`|`y` (equivalent to `branch` and `return`)";
819    pub(crate) const parse_debuginfo: &str = "either an integer (0, 1, 2), `none`, `line-directives-only`, `line-tables-only`, `limited`, or `full`";
820    pub(crate) const parse_debuginfo_compression: &str = "one of `none`, `zlib`, or `zstd`";
821    pub(crate) const parse_mir_strip_debuginfo: &str =
822        "one of `none`, `locals-in-tiny-functions`, or `all-locals`";
823    pub(crate) const parse_collapse_macro_debuginfo: &str = "one of `no`, `external`, or `yes`";
824    pub(crate) const parse_strip: &str = "either `none`, `debuginfo`, or `symbols`";
825    pub(crate) const parse_linker_flavor: &str = ::rustc_target::spec::LinkerFlavorCli::one_of();
826    pub(crate) const parse_dump_mono_stats: &str = "`markdown` (default) or `json`";
827    pub(crate) const parse_instrument_coverage: &str = parse_bool;
828    pub(crate) const parse_coverage_options: &str = "`block` | `branch` | `condition`";
829    pub(crate) const parse_instrument_xray: &str = "either a boolean (`yes`, `no`, `on`, `off`, etc), or a comma separated list of settings: `always` or `never` (mutually exclusive), `ignore-loops`, `instruction-threshold=N`, `skip-entry`, `skip-exit`";
830    pub(crate) const parse_unpretty: &str = "`string` or `string=string`";
831    pub(crate) const parse_treat_err_as_bug: &str = "either no value or a non-negative number";
832    pub(crate) const parse_next_solver_config: &str =
833        "either `globally` (when used without an argument), `coherence` (default) or `no`";
834    pub(crate) const parse_lto: &str =
835        "either a boolean (`yes`, `no`, `on`, `off`, etc), `thin`, `fat`, or omitted";
836    pub(crate) const parse_linker_plugin_lto: &str =
837        "either a boolean (`yes`, `no`, `on`, `off`, etc), or the path to the linker plugin";
838    pub(crate) const parse_location_detail: &str = "either `none`, or a comma separated list of location details to track: `file`, `line`, or `column`";
839    pub(crate) const parse_fmt_debug: &str = "either `full`, `shallow`, or `none`";
840    pub(crate) const parse_switch_with_opt_path: &str =
841        "an optional path to the profiling data output directory";
842    pub(crate) const parse_merge_functions: &str =
843        "one of: `disabled`, `trampolines`, or `aliases`";
844    pub(crate) const parse_symbol_mangling_version: &str =
845        "one of: `legacy`, `v0` (RFC 2603), or `hashed`";
846    pub(crate) const parse_opt_symbol_visibility: &str =
847        "one of: `hidden`, `protected`, or `interposable`";
848    pub(crate) const parse_cargo_src_file_hash: &str =
849        "one of `blake3`, `md5`, `sha1`, or `sha256`";
850    pub(crate) const parse_src_file_hash: &str = "one of `md5`, `sha1`, or `sha256`";
851    pub(crate) const parse_relocation_model: &str =
852        "one of supported relocation models (`rustc --print relocation-models`)";
853    pub(crate) const parse_code_model: &str =
854        "one of supported code models (`rustc --print code-models`)";
855    pub(crate) const parse_tls_model: &str =
856        "one of supported TLS models (`rustc --print tls-models`)";
857    pub(crate) const parse_target_feature: &str = parse_string;
858    pub(crate) const parse_terminal_url: &str =
859        "either a boolean (`yes`, `no`, `on`, `off`, etc), or `auto`";
860    pub(crate) const parse_wasi_exec_model: &str = "either `command` or `reactor`";
861    pub(crate) const parse_split_debuginfo: &str =
862        "one of supported split-debuginfo modes (`off`, `packed`, or `unpacked`)";
863    pub(crate) const parse_split_dwarf_kind: &str =
864        "one of supported split dwarf modes (`split` or `single`)";
865    pub(crate) const parse_link_self_contained: &str = "one of: `y`, `yes`, `on`, `n`, `no`, `off`, or a list of enabled (`+` prefix) and disabled (`-` prefix) \
866        components: `crto`, `libc`, `unwind`, `linker`, `sanitizers`, `mingw`";
867    pub(crate) const parse_linker_features: &str =
868        "a list of enabled (`+` prefix) and disabled (`-` prefix) features: `lld`";
869    pub(crate) const parse_polonius: &str = "either no value or `legacy` (the default), or `next`";
870    pub(crate) const parse_annotate_moves: &str =
871        "either a boolean (`yes`, `no`, `on`, `off`, etc.), or a size limit in bytes";
872    pub(crate) const parse_stack_protector: &str =
873        "one of (`none` (default), `basic`, `strong`, or `all`)";
874    pub(crate) const parse_branch_protection: &str = "a `,` separated combination of `bti`, `gcs`, `pac-ret`, (optionally with `pc`, `b-key`, `leaf` if `pac-ret` is set)";
875    pub(crate) const parse_proc_macro_execution_strategy: &str =
876        "one of supported execution strategies (`same-thread`, or `cross-thread`)";
877    pub(crate) const parse_inlining_threshold: &str =
878        "either a boolean (`yes`, `no`, `on`, `off`, etc), or a non-negative number";
879    pub(crate) const parse_llvm_module_flag: &str = "<key>:<type>:<value>:<behavior>. Type must currently be `u32`. Behavior should be one of (`error`, `warning`, `require`, `override`, `append`, `appendunique`, `max`, `min`)";
880    pub(crate) const parse_function_return: &str = "`keep` or `thunk-extern`";
881    pub(crate) const parse_wasm_c_abi: &str = "`spec`";
882    pub(crate) const parse_mir_include_spans: &str =
883        "either a boolean (`yes`, `no`, `on`, `off`, etc), or `nll` (default: `nll`)";
884    pub(crate) const parse_align: &str = "a number that is a power of 2 between 1 and 2^29";
885}
886
887pub mod parse {
888    use std::str::FromStr;
889
890    pub(crate) use super::*;
891    pub(crate) const MAX_THREADS_CAP: usize = 256;
892
893    /// This is for boolean options that don't take a value, and are true simply
894    /// by existing on the command-line.
895    ///
896    /// This style of option is deprecated, and is mainly used by old options
897    /// beginning with `no-`.
898    pub(crate) fn parse_no_value(slot: &mut bool, v: Option<&str>) -> bool {
899        match v {
900            None => {
901                *slot = true;
902                true
903            }
904            // Trying to specify a value is always forbidden.
905            Some(_) => false,
906        }
907    }
908
909    /// Use this for any boolean option that has a static default.
910    pub(crate) fn parse_bool(slot: &mut bool, v: Option<&str>) -> bool {
911        match v {
912            Some("y") | Some("yes") | Some("on") | Some("true") | None => {
913                *slot = true;
914                true
915            }
916            Some("n") | Some("no") | Some("off") | Some("false") => {
917                *slot = false;
918                true
919            }
920            _ => false,
921        }
922    }
923
924    /// Use this for any boolean option that lacks a static default. (The
925    /// actions taken when such an option is not specified will depend on
926    /// other factors, such as other options, or target options.)
927    pub(crate) fn parse_opt_bool(slot: &mut Option<bool>, v: Option<&str>) -> bool {
928        match v {
929            Some("y") | Some("yes") | Some("on") | Some("true") | None => {
930                *slot = Some(true);
931                true
932            }
933            Some("n") | Some("no") | Some("off") | Some("false") => {
934                *slot = Some(false);
935                true
936            }
937            _ => false,
938        }
939    }
940
941    /// Parses whether polonius is enabled, and if so, which version.
942    pub(crate) fn parse_polonius(slot: &mut Polonius, v: Option<&str>) -> bool {
943        match v {
944            Some("legacy") | None => {
945                *slot = Polonius::Legacy;
946                true
947            }
948            Some("next") => {
949                *slot = Polonius::Next;
950                true
951            }
952            _ => false,
953        }
954    }
955
956    pub(crate) fn parse_annotate_moves(slot: &mut AnnotateMoves, v: Option<&str>) -> bool {
957        let mut bslot = false;
958        let mut nslot = 0u64;
959
960        *slot = match v {
961            // No value provided: -Z annotate-moves (enable with default limit)
962            None => AnnotateMoves::Enabled(None),
963            // Explicit boolean value provided: -Z annotate-moves=yes/no
964            s @ Some(_) if parse_bool(&mut bslot, s) => {
965                if bslot {
966                    AnnotateMoves::Enabled(None)
967                } else {
968                    AnnotateMoves::Disabled
969                }
970            }
971            // With numeric limit provided: -Z annotate-moves=1234
972            s @ Some(_) if parse_number(&mut nslot, s) => AnnotateMoves::Enabled(Some(nslot)),
973            _ => return false,
974        };
975
976        true
977    }
978
979    /// Use this for any string option that has a static default.
980    pub(crate) fn parse_string(slot: &mut String, v: Option<&str>) -> bool {
981        match v {
982            Some(s) => {
983                *slot = s.to_string();
984                true
985            }
986            None => false,
987        }
988    }
989
990    /// Use this for any string option that lacks a static default.
991    pub(crate) fn parse_opt_string(slot: &mut Option<String>, v: Option<&str>) -> bool {
992        match v {
993            Some(s) => {
994                *slot = Some(s.to_string());
995                true
996            }
997            None => false,
998        }
999    }
1000
1001    /// Parse an optional language identifier, e.g. `en-US` or `zh-CN`.
1002    pub(crate) fn parse_opt_langid(slot: &mut Option<LanguageIdentifier>, v: Option<&str>) -> bool {
1003        match v {
1004            Some(s) => {
1005                *slot = rustc_errors::LanguageIdentifier::from_str(s).ok();
1006                true
1007            }
1008            None => false,
1009        }
1010    }
1011
1012    pub(crate) fn parse_opt_pathbuf(slot: &mut Option<PathBuf>, v: Option<&str>) -> bool {
1013        match v {
1014            Some(s) => {
1015                *slot = Some(PathBuf::from(s));
1016                true
1017            }
1018            None => false,
1019        }
1020    }
1021
1022    pub(crate) fn parse_string_push(slot: &mut Vec<String>, v: Option<&str>) -> bool {
1023        match v {
1024            Some(s) => {
1025                slot.push(s.to_string());
1026                true
1027            }
1028            None => false,
1029        }
1030    }
1031
1032    pub(crate) fn parse_list(slot: &mut Vec<String>, v: Option<&str>) -> bool {
1033        match v {
1034            Some(s) => {
1035                slot.extend(s.split_whitespace().map(|s| s.to_string()));
1036                true
1037            }
1038            None => false,
1039        }
1040    }
1041
1042    pub(crate) fn parse_list_with_polarity(
1043        slot: &mut Vec<(String, bool)>,
1044        v: Option<&str>,
1045    ) -> bool {
1046        match v {
1047            Some(s) => {
1048                for s in s.split(',') {
1049                    let Some(pass_name) = s.strip_prefix(&['+', '-'][..]) else { return false };
1050                    slot.push((pass_name.to_string(), &s[..1] == "+"));
1051                }
1052                true
1053            }
1054            None => false,
1055        }
1056    }
1057
1058    pub(crate) fn parse_fmt_debug(opt: &mut FmtDebug, v: Option<&str>) -> bool {
1059        *opt = match v {
1060            Some("full") => FmtDebug::Full,
1061            Some("shallow") => FmtDebug::Shallow,
1062            Some("none") => FmtDebug::None,
1063            _ => return false,
1064        };
1065        true
1066    }
1067
1068    pub(crate) fn parse_location_detail(ld: &mut LocationDetail, v: Option<&str>) -> bool {
1069        if let Some(v) = v {
1070            ld.line = false;
1071            ld.file = false;
1072            ld.column = false;
1073            if v == "none" {
1074                return true;
1075            }
1076            for s in v.split(',') {
1077                match s {
1078                    "file" => ld.file = true,
1079                    "line" => ld.line = true,
1080                    "column" => ld.column = true,
1081                    _ => return false,
1082                }
1083            }
1084            true
1085        } else {
1086            false
1087        }
1088    }
1089
1090    pub(crate) fn parse_comma_list(slot: &mut Vec<String>, v: Option<&str>) -> bool {
1091        match v {
1092            Some(s) => {
1093                let mut v: Vec<_> = s.split(',').map(|s| s.to_string()).collect();
1094                v.sort_unstable();
1095                *slot = v;
1096                true
1097            }
1098            None => false,
1099        }
1100    }
1101
1102    pub(crate) fn parse_opt_comma_list(slot: &mut Option<Vec<String>>, v: Option<&str>) -> bool {
1103        match v {
1104            Some(s) => {
1105                let mut v: Vec<_> = s.split(',').map(|s| s.to_string()).collect();
1106                v.sort_unstable();
1107                *slot = Some(v);
1108                true
1109            }
1110            None => false,
1111        }
1112    }
1113
1114    pub(crate) fn parse_threads(slot: &mut usize, v: Option<&str>) -> bool {
1115        let ret = match v.and_then(|s| s.parse().ok()) {
1116            Some(0) => {
1117                *slot = std::thread::available_parallelism().map_or(1, NonZero::<usize>::get);
1118                true
1119            }
1120            Some(i) => {
1121                *slot = i;
1122                true
1123            }
1124            None => false,
1125        };
1126        // We want to cap the number of threads here to avoid large numbers like 999999 and compiler panics.
1127        // This solution was suggested here https://github.com/rust-lang/rust/issues/117638#issuecomment-1800925067
1128        *slot = slot.clone().min(MAX_THREADS_CAP);
1129        ret
1130    }
1131
1132    /// Use this for any numeric option that has a static default.
1133    pub(crate) fn parse_number<T: Copy + FromStr>(slot: &mut T, v: Option<&str>) -> bool {
1134        match v.and_then(|s| s.parse().ok()) {
1135            Some(i) => {
1136                *slot = i;
1137                true
1138            }
1139            None => false,
1140        }
1141    }
1142
1143    /// Use this for any numeric option that lacks a static default.
1144    pub(crate) fn parse_opt_number<T: Copy + FromStr>(
1145        slot: &mut Option<T>,
1146        v: Option<&str>,
1147    ) -> bool {
1148        match v {
1149            Some(s) => {
1150                *slot = s.parse().ok();
1151                slot.is_some()
1152            }
1153            None => false,
1154        }
1155    }
1156
1157    pub(crate) fn parse_frame_pointer(slot: &mut FramePointer, v: Option<&str>) -> bool {
1158        let mut yes = false;
1159        match v {
1160            _ if parse_bool(&mut yes, v) && yes => slot.ratchet(FramePointer::Always),
1161            _ if parse_bool(&mut yes, v) => slot.ratchet(FramePointer::MayOmit),
1162            Some("always") => slot.ratchet(FramePointer::Always),
1163            Some("non-leaf") => slot.ratchet(FramePointer::NonLeaf),
1164            _ => return false,
1165        };
1166        true
1167    }
1168
1169    pub(crate) fn parse_passes(slot: &mut Passes, v: Option<&str>) -> bool {
1170        match v {
1171            Some("all") => {
1172                *slot = Passes::All;
1173                true
1174            }
1175            v => {
1176                let mut passes = ::alloc::vec::Vec::new()vec![];
1177                if parse_list(&mut passes, v) {
1178                    slot.extend(passes);
1179                    true
1180                } else {
1181                    false
1182                }
1183            }
1184        }
1185    }
1186
1187    pub(crate) fn parse_opt_panic_strategy(
1188        slot: &mut Option<PanicStrategy>,
1189        v: Option<&str>,
1190    ) -> bool {
1191        match v {
1192            Some("unwind") => *slot = Some(PanicStrategy::Unwind),
1193            Some("abort") => *slot = Some(PanicStrategy::Abort),
1194            Some("immediate-abort") => *slot = Some(PanicStrategy::ImmediateAbort),
1195            _ => return false,
1196        }
1197        true
1198    }
1199
1200    pub(crate) fn parse_panic_strategy(slot: &mut PanicStrategy, v: Option<&str>) -> bool {
1201        match v {
1202            Some("unwind") => *slot = PanicStrategy::Unwind,
1203            Some("abort") => *slot = PanicStrategy::Abort,
1204            Some("immediate-abort") => *slot = PanicStrategy::ImmediateAbort,
1205            _ => return false,
1206        }
1207        true
1208    }
1209
1210    pub(crate) fn parse_on_broken_pipe(slot: &mut OnBrokenPipe, v: Option<&str>) -> bool {
1211        match v {
1212            // OnBrokenPipe::Default can't be explicitly specified
1213            Some("kill") => *slot = OnBrokenPipe::Kill,
1214            Some("error") => *slot = OnBrokenPipe::Error,
1215            Some("inherit") => *slot = OnBrokenPipe::Inherit,
1216            _ => return false,
1217        }
1218        true
1219    }
1220
1221    pub(crate) fn parse_patchable_function_entry(
1222        slot: &mut PatchableFunctionEntry,
1223        v: Option<&str>,
1224    ) -> bool {
1225        let mut total_nops = 0;
1226        let mut prefix_nops = 0;
1227
1228        if !parse_number(&mut total_nops, v) {
1229            let parts = v.and_then(|v| v.split_once(',')).unzip();
1230            if !parse_number(&mut total_nops, parts.0) {
1231                return false;
1232            }
1233            if !parse_number(&mut prefix_nops, parts.1) {
1234                return false;
1235            }
1236        }
1237
1238        if let Some(pfe) =
1239            PatchableFunctionEntry::from_total_and_prefix_nops(total_nops, prefix_nops)
1240        {
1241            *slot = pfe;
1242            return true;
1243        }
1244        false
1245    }
1246
1247    pub(crate) fn parse_relro_level(slot: &mut Option<RelroLevel>, v: Option<&str>) -> bool {
1248        match v {
1249            Some(s) => match s.parse::<RelroLevel>() {
1250                Ok(level) => *slot = Some(level),
1251                _ => return false,
1252            },
1253            _ => return false,
1254        }
1255        true
1256    }
1257
1258    pub(crate) fn parse_sanitizers(slot: &mut SanitizerSet, v: Option<&str>) -> bool {
1259        if let Some(v) = v {
1260            for s in v.split(',') {
1261                *slot |= match s {
1262                    "address" => SanitizerSet::ADDRESS,
1263                    "cfi" => SanitizerSet::CFI,
1264                    "dataflow" => SanitizerSet::DATAFLOW,
1265                    "kcfi" => SanitizerSet::KCFI,
1266                    "kernel-address" => SanitizerSet::KERNELADDRESS,
1267                    "leak" => SanitizerSet::LEAK,
1268                    "memory" => SanitizerSet::MEMORY,
1269                    "memtag" => SanitizerSet::MEMTAG,
1270                    "shadow-call-stack" => SanitizerSet::SHADOWCALLSTACK,
1271                    "thread" => SanitizerSet::THREAD,
1272                    "hwaddress" => SanitizerSet::HWADDRESS,
1273                    "safestack" => SanitizerSet::SAFESTACK,
1274                    "realtime" => SanitizerSet::REALTIME,
1275                    _ => return false,
1276                }
1277            }
1278            true
1279        } else {
1280            false
1281        }
1282    }
1283
1284    pub(crate) fn parse_sanitizer_memory_track_origins(slot: &mut usize, v: Option<&str>) -> bool {
1285        match v {
1286            Some("2") | None => {
1287                *slot = 2;
1288                true
1289            }
1290            Some("1") => {
1291                *slot = 1;
1292                true
1293            }
1294            Some("0") => {
1295                *slot = 0;
1296                true
1297            }
1298            Some(_) => false,
1299        }
1300    }
1301
1302    pub(crate) fn parse_strip(slot: &mut Strip, v: Option<&str>) -> bool {
1303        match v {
1304            Some("none") => *slot = Strip::None,
1305            Some("debuginfo") => *slot = Strip::Debuginfo,
1306            Some("symbols") => *slot = Strip::Symbols,
1307            _ => return false,
1308        }
1309        true
1310    }
1311
1312    pub(crate) fn parse_cfguard(slot: &mut CFGuard, v: Option<&str>) -> bool {
1313        if v.is_some() {
1314            let mut bool_arg = None;
1315            if parse_opt_bool(&mut bool_arg, v) {
1316                *slot = if bool_arg.unwrap() { CFGuard::Checks } else { CFGuard::Disabled };
1317                return true;
1318            }
1319        }
1320
1321        *slot = match v {
1322            None => CFGuard::Checks,
1323            Some("checks") => CFGuard::Checks,
1324            Some("nochecks") => CFGuard::NoChecks,
1325            Some(_) => return false,
1326        };
1327        true
1328    }
1329
1330    pub(crate) fn parse_cfprotection(slot: &mut CFProtection, v: Option<&str>) -> bool {
1331        if v.is_some() {
1332            let mut bool_arg = None;
1333            if parse_opt_bool(&mut bool_arg, v) {
1334                *slot = if bool_arg.unwrap() { CFProtection::Full } else { CFProtection::None };
1335                return true;
1336            }
1337        }
1338
1339        *slot = match v {
1340            None | Some("none") => CFProtection::None,
1341            Some("branch") => CFProtection::Branch,
1342            Some("return") => CFProtection::Return,
1343            Some("full") => CFProtection::Full,
1344            Some(_) => return false,
1345        };
1346        true
1347    }
1348
1349    pub(crate) fn parse_debuginfo(slot: &mut DebugInfo, v: Option<&str>) -> bool {
1350        match v {
1351            Some("0") | Some("none") => *slot = DebugInfo::None,
1352            Some("line-directives-only") => *slot = DebugInfo::LineDirectivesOnly,
1353            Some("line-tables-only") => *slot = DebugInfo::LineTablesOnly,
1354            Some("1") | Some("limited") => *slot = DebugInfo::Limited,
1355            Some("2") | Some("full") => *slot = DebugInfo::Full,
1356            _ => return false,
1357        }
1358        true
1359    }
1360
1361    pub(crate) fn parse_debuginfo_compression(
1362        slot: &mut DebugInfoCompression,
1363        v: Option<&str>,
1364    ) -> bool {
1365        match v {
1366            Some("none") => *slot = DebugInfoCompression::None,
1367            Some("zlib") => *slot = DebugInfoCompression::Zlib,
1368            Some("zstd") => *slot = DebugInfoCompression::Zstd,
1369            _ => return false,
1370        };
1371        true
1372    }
1373
1374    pub(crate) fn parse_mir_strip_debuginfo(slot: &mut MirStripDebugInfo, v: Option<&str>) -> bool {
1375        match v {
1376            Some("none") => *slot = MirStripDebugInfo::None,
1377            Some("locals-in-tiny-functions") => *slot = MirStripDebugInfo::LocalsInTinyFunctions,
1378            Some("all-locals") => *slot = MirStripDebugInfo::AllLocals,
1379            _ => return false,
1380        };
1381        true
1382    }
1383
1384    pub(crate) fn parse_linker_flavor(slot: &mut Option<LinkerFlavorCli>, v: Option<&str>) -> bool {
1385        match v.and_then(|v| LinkerFlavorCli::from_str(v).ok()) {
1386            Some(lf) => *slot = Some(lf),
1387            _ => return false,
1388        }
1389        true
1390    }
1391
1392    pub(crate) fn parse_opt_symbol_visibility(
1393        slot: &mut Option<SymbolVisibility>,
1394        v: Option<&str>,
1395    ) -> bool {
1396        if let Some(v) = v {
1397            if let Ok(vis) = SymbolVisibility::from_str(v) {
1398                *slot = Some(vis);
1399            } else {
1400                return false;
1401            }
1402        }
1403        true
1404    }
1405
1406    pub(crate) fn parse_unpretty(slot: &mut Option<String>, v: Option<&str>) -> bool {
1407        match v {
1408            None => false,
1409            Some(s) if s.split('=').count() <= 2 => {
1410                *slot = Some(s.to_string());
1411                true
1412            }
1413            _ => false,
1414        }
1415    }
1416
1417    pub(crate) fn parse_time_passes_format(slot: &mut TimePassesFormat, v: Option<&str>) -> bool {
1418        match v {
1419            None => true,
1420            Some("json") => {
1421                *slot = TimePassesFormat::Json;
1422                true
1423            }
1424            Some("text") => {
1425                *slot = TimePassesFormat::Text;
1426                true
1427            }
1428            Some(_) => false,
1429        }
1430    }
1431
1432    pub(crate) fn parse_dump_mono_stats(slot: &mut DumpMonoStatsFormat, v: Option<&str>) -> bool {
1433        match v {
1434            None => true,
1435            Some("json") => {
1436                *slot = DumpMonoStatsFormat::Json;
1437                true
1438            }
1439            Some("markdown") => {
1440                *slot = DumpMonoStatsFormat::Markdown;
1441                true
1442            }
1443            Some(_) => false,
1444        }
1445    }
1446
1447    pub(crate) fn parse_offload(slot: &mut Vec<Offload>, v: Option<&str>) -> bool {
1448        let Some(v) = v else {
1449            *slot = ::alloc::vec::Vec::new()vec![];
1450            return true;
1451        };
1452        let mut v: Vec<&str> = v.split(",").collect();
1453        v.sort_unstable();
1454        for &val in v.iter() {
1455            // Split each entry on '=' if it has an argument
1456            let (key, arg) = match val.split_once('=') {
1457                Some((k, a)) => (k, Some(a)),
1458                None => (val, None),
1459            };
1460
1461            let variant = match key {
1462                "Host" => {
1463                    if let Some(p) = arg {
1464                        Offload::Host(p.to_string())
1465                    } else {
1466                        return false;
1467                    }
1468                }
1469                "Device" => {
1470                    if let Some(_) = arg {
1471                        // Device does not accept a value
1472                        return false;
1473                    }
1474                    Offload::Device
1475                }
1476                "Test" => {
1477                    if let Some(_) = arg {
1478                        // Test does not accept a value
1479                        return false;
1480                    }
1481                    Offload::Test
1482                }
1483                _ => {
1484                    // FIXME(ZuseZ4): print an error saying which value is not recognized
1485                    return false;
1486                }
1487            };
1488            slot.push(variant);
1489        }
1490
1491        true
1492    }
1493
1494    pub(crate) fn parse_autodiff(slot: &mut Vec<AutoDiff>, v: Option<&str>) -> bool {
1495        let Some(v) = v else {
1496            *slot = ::alloc::vec::Vec::new()vec![];
1497            return true;
1498        };
1499        let mut v: Vec<&str> = v.split(",").collect();
1500        v.sort_unstable();
1501        for &val in v.iter() {
1502            // Split each entry on '=' if it has an argument
1503            let (key, arg) = match val.split_once('=') {
1504                Some((k, a)) => (k, Some(a)),
1505                None => (val, None),
1506            };
1507
1508            let variant = match key {
1509                "Enable" => AutoDiff::Enable,
1510                "PrintTA" => AutoDiff::PrintTA,
1511                "PrintTAFn" => {
1512                    if let Some(fun) = arg {
1513                        AutoDiff::PrintTAFn(fun.to_string())
1514                    } else {
1515                        return false;
1516                    }
1517                }
1518                "PrintAA" => AutoDiff::PrintAA,
1519                "PrintPerf" => AutoDiff::PrintPerf,
1520                "PrintSteps" => AutoDiff::PrintSteps,
1521                "PrintModBefore" => AutoDiff::PrintModBefore,
1522                "PrintModAfter" => AutoDiff::PrintModAfter,
1523                "PrintModFinal" => AutoDiff::PrintModFinal,
1524                "NoPostopt" => AutoDiff::NoPostopt,
1525                "PrintPasses" => AutoDiff::PrintPasses,
1526                "LooseTypes" => AutoDiff::LooseTypes,
1527                "Inline" => AutoDiff::Inline,
1528                "NoTT" => AutoDiff::NoTT,
1529                _ => {
1530                    // FIXME(ZuseZ4): print an error saying which value is not recognized
1531                    return false;
1532                }
1533            };
1534            slot.push(variant);
1535        }
1536
1537        true
1538    }
1539
1540    pub(crate) fn parse_instrument_coverage(
1541        slot: &mut InstrumentCoverage,
1542        v: Option<&str>,
1543    ) -> bool {
1544        if v.is_some() {
1545            let mut bool_arg = false;
1546            if parse_bool(&mut bool_arg, v) {
1547                *slot = if bool_arg { InstrumentCoverage::Yes } else { InstrumentCoverage::No };
1548                return true;
1549            }
1550        }
1551
1552        let Some(v) = v else {
1553            *slot = InstrumentCoverage::Yes;
1554            return true;
1555        };
1556
1557        // Parse values that have historically been accepted by stable compilers,
1558        // even though they're currently just aliases for boolean values.
1559        *slot = match v {
1560            "all" => InstrumentCoverage::Yes,
1561            "0" => InstrumentCoverage::No,
1562            _ => return false,
1563        };
1564        true
1565    }
1566
1567    pub(crate) fn parse_coverage_options(slot: &mut CoverageOptions, v: Option<&str>) -> bool {
1568        let Some(v) = v else { return true };
1569
1570        for option in v.split(',') {
1571            match option {
1572                "block" => slot.level = CoverageLevel::Block,
1573                "branch" => slot.level = CoverageLevel::Branch,
1574                "condition" => slot.level = CoverageLevel::Condition,
1575                "discard-all-spans-in-codegen" => slot.discard_all_spans_in_codegen = true,
1576                _ => return false,
1577            }
1578        }
1579        true
1580    }
1581
1582    pub(crate) fn parse_instrument_xray(
1583        slot: &mut Option<InstrumentXRay>,
1584        v: Option<&str>,
1585    ) -> bool {
1586        if v.is_some() {
1587            let mut bool_arg = None;
1588            if parse_opt_bool(&mut bool_arg, v) {
1589                *slot = if bool_arg.unwrap() { Some(InstrumentXRay::default()) } else { None };
1590                return true;
1591            }
1592        }
1593
1594        let options = slot.get_or_insert_default();
1595        let mut seen_always = false;
1596        let mut seen_never = false;
1597        let mut seen_ignore_loops = false;
1598        let mut seen_instruction_threshold = false;
1599        let mut seen_skip_entry = false;
1600        let mut seen_skip_exit = false;
1601        for option in v.into_iter().flat_map(|v| v.split(',')) {
1602            match option {
1603                "always" if !seen_always && !seen_never => {
1604                    options.always = true;
1605                    options.never = false;
1606                    seen_always = true;
1607                }
1608                "never" if !seen_never && !seen_always => {
1609                    options.never = true;
1610                    options.always = false;
1611                    seen_never = true;
1612                }
1613                "ignore-loops" if !seen_ignore_loops => {
1614                    options.ignore_loops = true;
1615                    seen_ignore_loops = true;
1616                }
1617                option
1618                    if option.starts_with("instruction-threshold")
1619                        && !seen_instruction_threshold =>
1620                {
1621                    let Some(("instruction-threshold", n)) = option.split_once('=') else {
1622                        return false;
1623                    };
1624                    match n.parse() {
1625                        Ok(n) => options.instruction_threshold = Some(n),
1626                        Err(_) => return false,
1627                    }
1628                    seen_instruction_threshold = true;
1629                }
1630                "skip-entry" if !seen_skip_entry => {
1631                    options.skip_entry = true;
1632                    seen_skip_entry = true;
1633                }
1634                "skip-exit" if !seen_skip_exit => {
1635                    options.skip_exit = true;
1636                    seen_skip_exit = true;
1637                }
1638                _ => return false,
1639            }
1640        }
1641        true
1642    }
1643
1644    pub(crate) fn parse_treat_err_as_bug(
1645        slot: &mut Option<NonZero<usize>>,
1646        v: Option<&str>,
1647    ) -> bool {
1648        match v {
1649            Some(s) => match s.parse() {
1650                Ok(val) => {
1651                    *slot = Some(val);
1652                    true
1653                }
1654                Err(e) => {
1655                    *slot = None;
1656                    e.kind() == &IntErrorKind::Zero
1657                }
1658            },
1659            None => {
1660                *slot = NonZero::new(1);
1661                true
1662            }
1663        }
1664    }
1665
1666    pub(crate) fn parse_next_solver_config(slot: &mut NextSolverConfig, v: Option<&str>) -> bool {
1667        if let Some(config) = v {
1668            *slot = match config {
1669                "no" => NextSolverConfig { coherence: false, globally: false },
1670                "coherence" => NextSolverConfig { coherence: true, globally: false },
1671                "globally" => NextSolverConfig { coherence: true, globally: true },
1672                _ => return false,
1673            };
1674        } else {
1675            *slot = NextSolverConfig { coherence: true, globally: true };
1676        }
1677
1678        true
1679    }
1680
1681    pub(crate) fn parse_lto(slot: &mut LtoCli, v: Option<&str>) -> bool {
1682        if v.is_some() {
1683            let mut bool_arg = None;
1684            if parse_opt_bool(&mut bool_arg, v) {
1685                *slot = if bool_arg.unwrap() { LtoCli::Yes } else { LtoCli::No };
1686                return true;
1687            }
1688        }
1689
1690        *slot = match v {
1691            None => LtoCli::NoParam,
1692            Some("thin") => LtoCli::Thin,
1693            Some("fat") => LtoCli::Fat,
1694            Some(_) => return false,
1695        };
1696        true
1697    }
1698
1699    pub(crate) fn parse_linker_plugin_lto(slot: &mut LinkerPluginLto, v: Option<&str>) -> bool {
1700        if v.is_some() {
1701            let mut bool_arg = None;
1702            if parse_opt_bool(&mut bool_arg, v) {
1703                *slot = if bool_arg.unwrap() {
1704                    LinkerPluginLto::LinkerPluginAuto
1705                } else {
1706                    LinkerPluginLto::Disabled
1707                };
1708                return true;
1709            }
1710        }
1711
1712        *slot = match v {
1713            None => LinkerPluginLto::LinkerPluginAuto,
1714            Some(path) => LinkerPluginLto::LinkerPlugin(PathBuf::from(path)),
1715        };
1716        true
1717    }
1718
1719    pub(crate) fn parse_switch_with_opt_path(
1720        slot: &mut SwitchWithOptPath,
1721        v: Option<&str>,
1722    ) -> bool {
1723        *slot = match v {
1724            None => SwitchWithOptPath::Enabled(None),
1725            Some(path) => SwitchWithOptPath::Enabled(Some(PathBuf::from(path))),
1726        };
1727        true
1728    }
1729
1730    pub(crate) fn parse_merge_functions(
1731        slot: &mut Option<MergeFunctions>,
1732        v: Option<&str>,
1733    ) -> bool {
1734        match v.and_then(|s| MergeFunctions::from_str(s).ok()) {
1735            Some(mergefunc) => *slot = Some(mergefunc),
1736            _ => return false,
1737        }
1738        true
1739    }
1740
1741    pub(crate) fn parse_relocation_model(slot: &mut Option<RelocModel>, v: Option<&str>) -> bool {
1742        match v.and_then(|s| RelocModel::from_str(s).ok()) {
1743            Some(relocation_model) => *slot = Some(relocation_model),
1744            None if v == Some("default") => *slot = None,
1745            _ => return false,
1746        }
1747        true
1748    }
1749
1750    pub(crate) fn parse_code_model(slot: &mut Option<CodeModel>, v: Option<&str>) -> bool {
1751        match v.and_then(|s| CodeModel::from_str(s).ok()) {
1752            Some(code_model) => *slot = Some(code_model),
1753            _ => return false,
1754        }
1755        true
1756    }
1757
1758    pub(crate) fn parse_tls_model(slot: &mut Option<TlsModel>, v: Option<&str>) -> bool {
1759        match v.and_then(|s| TlsModel::from_str(s).ok()) {
1760            Some(tls_model) => *slot = Some(tls_model),
1761            _ => return false,
1762        }
1763        true
1764    }
1765
1766    pub(crate) fn parse_terminal_url(slot: &mut TerminalUrl, v: Option<&str>) -> bool {
1767        *slot = match v {
1768            Some("on" | "" | "yes" | "y") | None => TerminalUrl::Yes,
1769            Some("off" | "no" | "n") => TerminalUrl::No,
1770            Some("auto") => TerminalUrl::Auto,
1771            _ => return false,
1772        };
1773        true
1774    }
1775
1776    pub(crate) fn parse_symbol_mangling_version(
1777        slot: &mut Option<SymbolManglingVersion>,
1778        v: Option<&str>,
1779    ) -> bool {
1780        *slot = match v {
1781            Some("legacy") => Some(SymbolManglingVersion::Legacy),
1782            Some("v0") => Some(SymbolManglingVersion::V0),
1783            Some("hashed") => Some(SymbolManglingVersion::Hashed),
1784            _ => return false,
1785        };
1786        true
1787    }
1788
1789    pub(crate) fn parse_src_file_hash(
1790        slot: &mut Option<SourceFileHashAlgorithm>,
1791        v: Option<&str>,
1792    ) -> bool {
1793        match v.and_then(|s| SourceFileHashAlgorithm::from_str(s).ok()) {
1794            Some(hash_kind) => *slot = Some(hash_kind),
1795            _ => return false,
1796        }
1797        true
1798    }
1799
1800    pub(crate) fn parse_cargo_src_file_hash(
1801        slot: &mut Option<SourceFileHashAlgorithm>,
1802        v: Option<&str>,
1803    ) -> bool {
1804        match v.and_then(|s| SourceFileHashAlgorithm::from_str(s).ok()) {
1805            Some(hash_kind) => {
1806                *slot = Some(hash_kind);
1807            }
1808            _ => return false,
1809        }
1810        true
1811    }
1812
1813    pub(crate) fn parse_target_feature(slot: &mut String, v: Option<&str>) -> bool {
1814        match v {
1815            Some(s) => {
1816                if !slot.is_empty() {
1817                    slot.push(',');
1818                }
1819                slot.push_str(s);
1820                true
1821            }
1822            None => false,
1823        }
1824    }
1825
1826    pub(crate) fn parse_link_self_contained(slot: &mut LinkSelfContained, v: Option<&str>) -> bool {
1827        // Whenever `-C link-self-contained` is passed without a value, it's an opt-in
1828        // just like `parse_opt_bool`, the historical value of this flag.
1829        //
1830        // 1. Parse historical single bool values
1831        let s = v.unwrap_or("y");
1832        match s {
1833            "y" | "yes" | "on" => {
1834                slot.set_all_explicitly(true);
1835                return true;
1836            }
1837            "n" | "no" | "off" => {
1838                slot.set_all_explicitly(false);
1839                return true;
1840            }
1841            _ => {}
1842        }
1843
1844        // 2. Parse a list of enabled and disabled components.
1845        for comp in s.split(',') {
1846            if slot.handle_cli_component(comp).is_none() {
1847                return false;
1848            }
1849        }
1850
1851        true
1852    }
1853
1854    /// Parse a comma-separated list of enabled and disabled linker features.
1855    pub(crate) fn parse_linker_features(slot: &mut LinkerFeaturesCli, v: Option<&str>) -> bool {
1856        match v {
1857            Some(s) => {
1858                for feature in s.split(',') {
1859                    if slot.handle_cli_feature(feature).is_none() {
1860                        return false;
1861                    }
1862                }
1863
1864                true
1865            }
1866            None => false,
1867        }
1868    }
1869
1870    pub(crate) fn parse_wasi_exec_model(slot: &mut Option<WasiExecModel>, v: Option<&str>) -> bool {
1871        match v {
1872            Some("command") => *slot = Some(WasiExecModel::Command),
1873            Some("reactor") => *slot = Some(WasiExecModel::Reactor),
1874            _ => return false,
1875        }
1876        true
1877    }
1878
1879    pub(crate) fn parse_split_debuginfo(
1880        slot: &mut Option<SplitDebuginfo>,
1881        v: Option<&str>,
1882    ) -> bool {
1883        match v.and_then(|s| SplitDebuginfo::from_str(s).ok()) {
1884            Some(e) => *slot = Some(e),
1885            _ => return false,
1886        }
1887        true
1888    }
1889
1890    pub(crate) fn parse_split_dwarf_kind(slot: &mut SplitDwarfKind, v: Option<&str>) -> bool {
1891        match v.and_then(|s| SplitDwarfKind::from_str(s).ok()) {
1892            Some(e) => *slot = e,
1893            _ => return false,
1894        }
1895        true
1896    }
1897
1898    pub(crate) fn parse_stack_protector(slot: &mut StackProtector, v: Option<&str>) -> bool {
1899        match v.and_then(|s| StackProtector::from_str(s).ok()) {
1900            Some(ssp) => *slot = ssp,
1901            _ => return false,
1902        }
1903        true
1904    }
1905
1906    pub(crate) fn parse_branch_protection(
1907        slot: &mut Option<BranchProtection>,
1908        v: Option<&str>,
1909    ) -> bool {
1910        match v {
1911            Some(s) => {
1912                let slot = slot.get_or_insert_default();
1913                for opt in s.split(',') {
1914                    match opt {
1915                        "bti" => slot.bti = true,
1916                        "pac-ret" if slot.pac_ret.is_none() => {
1917                            slot.pac_ret = Some(PacRet { leaf: false, pc: false, key: PAuthKey::A })
1918                        }
1919                        "leaf" => match slot.pac_ret.as_mut() {
1920                            Some(pac) => pac.leaf = true,
1921                            _ => return false,
1922                        },
1923                        "b-key" => match slot.pac_ret.as_mut() {
1924                            Some(pac) => pac.key = PAuthKey::B,
1925                            _ => return false,
1926                        },
1927                        "pc" => match slot.pac_ret.as_mut() {
1928                            Some(pac) => pac.pc = true,
1929                            _ => return false,
1930                        },
1931                        "gcs" => slot.gcs = true,
1932                        _ => return false,
1933                    };
1934                }
1935            }
1936            _ => return false,
1937        }
1938        true
1939    }
1940
1941    pub(crate) fn parse_collapse_macro_debuginfo(
1942        slot: &mut CollapseMacroDebuginfo,
1943        v: Option<&str>,
1944    ) -> bool {
1945        if v.is_some() {
1946            let mut bool_arg = None;
1947            if parse_opt_bool(&mut bool_arg, v) {
1948                *slot = if bool_arg.unwrap() {
1949                    CollapseMacroDebuginfo::Yes
1950                } else {
1951                    CollapseMacroDebuginfo::No
1952                };
1953                return true;
1954            }
1955        }
1956
1957        *slot = match v {
1958            Some("external") => CollapseMacroDebuginfo::External,
1959            _ => return false,
1960        };
1961        true
1962    }
1963
1964    pub(crate) fn parse_proc_macro_execution_strategy(
1965        slot: &mut ProcMacroExecutionStrategy,
1966        v: Option<&str>,
1967    ) -> bool {
1968        *slot = match v {
1969            Some("same-thread") => ProcMacroExecutionStrategy::SameThread,
1970            Some("cross-thread") => ProcMacroExecutionStrategy::CrossThread,
1971            _ => return false,
1972        };
1973        true
1974    }
1975
1976    pub(crate) fn parse_inlining_threshold(slot: &mut InliningThreshold, v: Option<&str>) -> bool {
1977        match v {
1978            Some("always" | "yes") => {
1979                *slot = InliningThreshold::Always;
1980            }
1981            Some("never") => {
1982                *slot = InliningThreshold::Never;
1983            }
1984            Some(v) => {
1985                if let Ok(threshold) = v.parse() {
1986                    *slot = InliningThreshold::Sometimes(threshold);
1987                } else {
1988                    return false;
1989                }
1990            }
1991            None => return false,
1992        }
1993        true
1994    }
1995
1996    pub(crate) fn parse_llvm_module_flag(
1997        slot: &mut Vec<(String, u32, String)>,
1998        v: Option<&str>,
1999    ) -> bool {
2000        let elements = v.unwrap_or_default().split(':').collect::<Vec<_>>();
2001        let [key, md_type, value, behavior] = elements.as_slice() else {
2002            return false;
2003        };
2004        if *md_type != "u32" {
2005            // Currently we only support u32 metadata flags, but require the
2006            // type for forward-compatibility.
2007            return false;
2008        }
2009        let Ok(value) = value.parse::<u32>() else {
2010            return false;
2011        };
2012        let behavior = behavior.to_lowercase();
2013        let all_behaviors =
2014            ["error", "warning", "require", "override", "append", "appendunique", "max", "min"];
2015        if !all_behaviors.contains(&behavior.as_str()) {
2016            return false;
2017        }
2018
2019        slot.push((key.to_string(), value, behavior));
2020        true
2021    }
2022
2023    pub(crate) fn parse_function_return(slot: &mut FunctionReturn, v: Option<&str>) -> bool {
2024        match v {
2025            Some("keep") => *slot = FunctionReturn::Keep,
2026            Some("thunk-extern") => *slot = FunctionReturn::ThunkExtern,
2027            _ => return false,
2028        }
2029        true
2030    }
2031
2032    pub(crate) fn parse_wasm_c_abi(_slot: &mut (), v: Option<&str>) -> bool {
2033        v == Some("spec")
2034    }
2035
2036    pub(crate) fn parse_mir_include_spans(slot: &mut MirIncludeSpans, v: Option<&str>) -> bool {
2037        *slot = match v {
2038            Some("on" | "yes" | "y" | "true") | None => MirIncludeSpans::On,
2039            Some("off" | "no" | "n" | "false") => MirIncludeSpans::Off,
2040            Some("nll") => MirIncludeSpans::Nll,
2041            _ => return false,
2042        };
2043
2044        true
2045    }
2046
2047    pub(crate) fn parse_align(slot: &mut Option<Align>, v: Option<&str>) -> bool {
2048        let mut bytes = 0u64;
2049        if !parse_number(&mut bytes, v) {
2050            return false;
2051        }
2052
2053        let Ok(align) = Align::from_bytes(bytes) else {
2054            return false;
2055        };
2056
2057        *slot = Some(align);
2058
2059        true
2060    }
2061}
2062
2063#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialEq for CodegenOptionsTargetModifiers {
    #[inline]
    fn eq(&self, other: &CodegenOptionsTargetModifiers) -> bool {
        match *self {}
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Eq for CodegenOptionsTargetModifiers {
    #[inline]
    #[doc(hidden)]
    #[coverage(off)]
    fn assert_receiver_is_total_eq(&self) {}
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialOrd for CodegenOptionsTargetModifiers {
    #[inline]
    fn partial_cmp(&self, other: &CodegenOptionsTargetModifiers)
        -> ::core::option::Option<::core::cmp::Ordering> {
        match *self {}
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Ord for CodegenOptionsTargetModifiers {
    #[inline]
    fn cmp(&self, other: &CodegenOptionsTargetModifiers)
        -> ::core::cmp::Ordering {
        match *self {}
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::fmt::Debug for CodegenOptionsTargetModifiers {
    #[inline]
    fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
        match *self {}
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::marker::Copy for CodegenOptionsTargetModifiers { }
#[automatically_derived]
#[doc(hidden)]
#[allow(non_camel_case_types)]
unsafe impl ::core::clone::TrivialClone for CodegenOptionsTargetModifiers { }
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::clone::Clone for CodegenOptionsTargetModifiers {
    #[inline]
    fn clone(&self) -> CodegenOptionsTargetModifiers { *self }
}
const _: () =
    {
        impl<__E: ::rustc_span::SpanEncoder> ::rustc_serialize::Encodable<__E>
            for CodegenOptionsTargetModifiers {
            fn encode(&self, __encoder: &mut __E) { match *self {} }
        }
    };
const _: () =
    {
        impl<__D: ::rustc_span::BlobDecoder> ::rustc_serialize::Decodable<__D>
            for CodegenOptionsTargetModifiers {
            fn decode(__decoder: &mut __D) -> Self {
                {
                    ::core::panicking::panic_fmt(format_args!("`CodegenOptionsTargetModifiers` has no variants to decode"));
                }
            }
        }
    };
impl CodegenOptionsTargetModifiers {
    #[allow(unused_variables)]
    pub fn reparse(&self, user_value: &str) -> ExtendedTargetModifierInfo {

        #[allow(unreachable_patterns)]
        match self {
            _ => {
                ::core::panicking::panic_fmt(format_args!("unknown target modifier option: {0:?}",
                        *self));
            }
        }
    }
    pub fn is_target_modifier(flag_name: &str) -> bool {
        match flag_name.replace('-', "_").as_str() { _ => false, }
    }
}
impl Default for CodegenOptions {
    fn default() -> CodegenOptions {
        CodegenOptions {
            ar: String::new(),
            code_model: None,
            codegen_units: None,
            collapse_macro_debuginfo: CollapseMacroDebuginfo::Unspecified,
            control_flow_guard: CFGuard::Disabled,
            debug_assertions: None,
            debuginfo: DebugInfo::None,
            default_linker_libraries: false,
            dlltool: None,
            dwarf_version: None,
            embed_bitcode: true,
            extra_filename: String::new(),
            force_frame_pointers: FramePointer::MayOmit,
            force_unwind_tables: None,
            help: false,
            incremental: None,
            inline_threshold: None,
            instrument_coverage: InstrumentCoverage::No,
            jump_tables: true,
            link_arg: (),
            link_args: Vec::new(),
            link_dead_code: None,
            link_self_contained: LinkSelfContained::default(),
            linker: None,
            linker_features: LinkerFeaturesCli::default(),
            linker_flavor: None,
            linker_plugin_lto: LinkerPluginLto::Disabled,
            llvm_args: Vec::new(),
            lto: LtoCli::Unspecified,
            metadata: Vec::new(),
            no_prepopulate_passes: false,
            no_redzone: None,
            no_stack_check: false,
            no_vectorize_loops: false,
            no_vectorize_slp: false,
            opt_level: "0".to_string(),
            overflow_checks: None,
            panic: None,
            passes: Vec::new(),
            prefer_dynamic: false,
            profile_generate: SwitchWithOptPath::Disabled,
            profile_use: None,
            relocation_model: None,
            relro_level: None,
            remark: Passes::Some(Vec::new()),
            rpath: false,
            save_temps: false,
            soft_float: false,
            split_debuginfo: None,
            strip: Strip::None,
            symbol_mangling_version: None,
            target_cpu: None,
            target_feature: String::new(),
            unsafe_allow_abi_mismatch: Vec::new(),
        }
    }
}
impl CodegenOptions {
    pub fn build(early_dcx: &EarlyDiagCtxt, matches: &getopts::Matches,
        target_modifiers: &mut BTreeMap<OptionsTargetModifiers, String>)
        -> CodegenOptions {
        build_options(early_dcx, matches, target_modifiers, CG_OPTIONS, "C",
            "codegen")
    }
    fn dep_tracking_hash(&self, for_crate_hash: bool,
        error_format: ErrorOutputType) -> Hash64 {
        let mut sub_hashes = BTreeMap::new();
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("code_model",
                            &self.code_model as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "code_model"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("collapse_macro_debuginfo",
                            &self.collapse_macro_debuginfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "collapse_macro_debuginfo"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("control_flow_guard",
                            &self.control_flow_guard as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "control_flow_guard"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debug_assertions",
                            &self.debug_assertions as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debug_assertions"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debuginfo",
                            &self.debuginfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debuginfo"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("dwarf_version",
                            &self.dwarf_version as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "dwarf_version"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("embed_bitcode",
                            &self.embed_bitcode as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "embed_bitcode"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("force_frame_pointers",
                            &self.force_frame_pointers as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "force_frame_pointers"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("force_unwind_tables",
                            &self.force_unwind_tables as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "force_unwind_tables"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("instrument_coverage",
                            &self.instrument_coverage as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "instrument_coverage"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("jump_tables",
                            &self.jump_tables as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "jump_tables"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("link_dead_code",
                            &self.link_dead_code as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "link_dead_code"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("linker_plugin_lto",
                            &self.linker_plugin_lto as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "linker_plugin_lto"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("llvm_args",
                            &self.llvm_args as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "llvm_args"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("lto",
                            &self.lto as &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "lto"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("metadata",
                            &self.metadata as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "metadata"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_prepopulate_passes",
                            &self.no_prepopulate_passes as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_prepopulate_passes"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_redzone",
                            &self.no_redzone as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_redzone"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("no_vectorize_loops",
                            &self.no_vectorize_loops as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_vectorize_loops"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_vectorize_slp",
                            &self.no_vectorize_slp as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_vectorize_slp"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("opt_level",
                            &self.opt_level as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "opt_level"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("overflow_checks",
                            &self.overflow_checks as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "overflow_checks"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("panic",
                            &self.panic as &dyn dep_tracking::DepTrackingHash).is_some()
                    {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "panic"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("passes",
                            &self.passes as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "passes"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("prefer_dynamic",
                            &self.prefer_dynamic as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "prefer_dynamic"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("profile_generate",
                            &self.profile_generate as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "profile_generate"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("profile_use",
                            &self.profile_use as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "profile_use"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("relocation_model",
                            &self.relocation_model as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "relocation_model"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("relro_level",
                            &self.relro_level as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "relro_level"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("soft_float",
                            &self.soft_float as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "soft_float"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("split_debuginfo",
                            &self.split_debuginfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "split_debuginfo"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("symbol_mangling_version",
                            &self.symbol_mangling_version as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "symbol_mangling_version"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("target_cpu",
                            &self.target_cpu as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "target_cpu"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("target_feature",
                            &self.target_feature as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "target_feature"));
                    }
                }
            };
        }
        { {}; }
        let mut hasher = StableHasher::new();
        dep_tracking::stable_hash(sub_hashes, &mut hasher, error_format,
            for_crate_hash);
        hasher.finish()
    }
    pub fn gather_target_modifiers(&self, _mods: &mut Vec<TargetModifier>,
        _tmod_vals: &BTreeMap<OptionsTargetModifiers, String>) {
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
    }
}
pub const CG_OPTIONS: OptionDescrs<CodegenOptions> =
    &[OptionDesc {
                    name: "ar",
                    setter: cgopts::ar,
                    type_desc: desc::parse_string,
                    desc: "this option is deprecated and does nothing",
                    is_deprecated_and_do_nothing: false || true,
                    tmod: None,
                },
                OptionDesc {
                    name: "code_model",
                    setter: cgopts::code_model,
                    type_desc: desc::parse_code_model,
                    desc: "choose the code model to use (`rustc --print code-models` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "codegen_units",
                    setter: cgopts::codegen_units,
                    type_desc: desc::parse_opt_number,
                    desc: "divide crate into N units to optimize in parallel",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "collapse_macro_debuginfo",
                    setter: cgopts::collapse_macro_debuginfo,
                    type_desc: desc::parse_collapse_macro_debuginfo,
                    desc: "set option to collapse debuginfo for macros",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "control_flow_guard",
                    setter: cgopts::control_flow_guard,
                    type_desc: desc::parse_cfguard,
                    desc: "use Windows Control Flow Guard (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "debug_assertions",
                    setter: cgopts::debug_assertions,
                    type_desc: desc::parse_opt_bool,
                    desc: "explicitly enable the `cfg(debug_assertions)` directive",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "debuginfo",
                    setter: cgopts::debuginfo,
                    type_desc: desc::parse_debuginfo,
                    desc: "debug info emission level (0-2, none, line-directives-only, \
        line-tables-only, limited, or full; default: 0)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "default_linker_libraries",
                    setter: cgopts::default_linker_libraries,
                    type_desc: desc::parse_bool,
                    desc: "allow the linker to link its default libraries (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dlltool",
                    setter: cgopts::dlltool,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "import library generation tool (ignored except when targeting windows-gnu)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dwarf_version",
                    setter: cgopts::dwarf_version,
                    type_desc: desc::parse_opt_number,
                    desc: "version of DWARF debug information to emit (default: 2 or 4, depending on platform)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "embed_bitcode",
                    setter: cgopts::embed_bitcode,
                    type_desc: desc::parse_bool,
                    desc: "emit bitcode in rlibs (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "extra_filename",
                    setter: cgopts::extra_filename,
                    type_desc: desc::parse_string,
                    desc: "extra data to put in each output filename",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "force_frame_pointers",
                    setter: cgopts::force_frame_pointers,
                    type_desc: desc::parse_frame_pointer,
                    desc: "force use of the frame pointers",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "force_unwind_tables",
                    setter: cgopts::force_unwind_tables,
                    type_desc: desc::parse_opt_bool,
                    desc: "force use of unwind tables",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "help",
                    setter: cgopts::help,
                    type_desc: desc::parse_no_value,
                    desc: "Print codegen options",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "incremental",
                    setter: cgopts::incremental,
                    type_desc: desc::parse_opt_string,
                    desc: "enable incremental compilation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_threshold",
                    setter: cgopts::inline_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "this option is deprecated and does nothing \
        (consider using `-Cllvm-args=--inline-threshold=...`)",
                    is_deprecated_and_do_nothing: false || true,
                    tmod: None,
                },
                OptionDesc {
                    name: "instrument_coverage",
                    setter: cgopts::instrument_coverage,
                    type_desc: desc::parse_instrument_coverage,
                    desc: "instrument the generated code to support LLVM source-based code coverage reports \
        (note, the compiler build config must include `profiler = true`); \
        implies `-C symbol-mangling-version=v0`",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "jump_tables",
                    setter: cgopts::jump_tables,
                    type_desc: desc::parse_bool,
                    desc: "allow jump table and lookup table generation from switch case lowering (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_arg",
                    setter: cgopts::link_arg,
                    type_desc: desc::parse_string_push,
                    desc: "a single extra argument to append to the linker invocation (can be used several times)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_args",
                    setter: cgopts::link_args,
                    type_desc: desc::parse_list,
                    desc: "extra arguments to append to the linker invocation (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_dead_code",
                    setter: cgopts::link_dead_code,
                    type_desc: desc::parse_opt_bool,
                    desc: "try to generate and link dead code (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_self_contained",
                    setter: cgopts::link_self_contained,
                    type_desc: desc::parse_link_self_contained,
                    desc: "control whether to link Rust provided C objects/libraries or rely \
        on a C toolchain or linker installed in the system",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "linker",
                    setter: cgopts::linker,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "system linker to link outputs with",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "linker_features",
                    setter: cgopts::linker_features,
                    type_desc: desc::parse_linker_features,
                    desc: "a comma-separated list of linker features to enable (+) or disable (-): `lld`",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "linker_flavor",
                    setter: cgopts::linker_flavor,
                    type_desc: desc::parse_linker_flavor,
                    desc: "linker flavor",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "linker_plugin_lto",
                    setter: cgopts::linker_plugin_lto,
                    type_desc: desc::parse_linker_plugin_lto,
                    desc: "generate build artifacts that are compatible with linker-based LTO",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "llvm_args",
                    setter: cgopts::llvm_args,
                    type_desc: desc::parse_list,
                    desc: "a list of arguments to pass to LLVM (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "lto",
                    setter: cgopts::lto,
                    type_desc: desc::parse_lto,
                    desc: "perform LLVM link-time optimizations",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "metadata",
                    setter: cgopts::metadata,
                    type_desc: desc::parse_list,
                    desc: "metadata to mangle symbol names with",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_prepopulate_passes",
                    setter: cgopts::no_prepopulate_passes,
                    type_desc: desc::parse_no_value,
                    desc: "give an empty list of passes to the pass manager",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_redzone",
                    setter: cgopts::no_redzone,
                    type_desc: desc::parse_opt_bool,
                    desc: "disable the use of the redzone",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_stack_check",
                    setter: cgopts::no_stack_check,
                    type_desc: desc::parse_no_value,
                    desc: "this option is deprecated and does nothing",
                    is_deprecated_and_do_nothing: false || true,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_vectorize_loops",
                    setter: cgopts::no_vectorize_loops,
                    type_desc: desc::parse_no_value,
                    desc: "disable loop vectorization optimization passes",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_vectorize_slp",
                    setter: cgopts::no_vectorize_slp,
                    type_desc: desc::parse_no_value,
                    desc: "disable LLVM's SLP vectorization pass",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "opt_level",
                    setter: cgopts::opt_level,
                    type_desc: desc::parse_string,
                    desc: "optimization level (0-3, s, or z; default: 0)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "overflow_checks",
                    setter: cgopts::overflow_checks,
                    type_desc: desc::parse_opt_bool,
                    desc: "use overflow checks for integer arithmetic",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "panic",
                    setter: cgopts::panic,
                    type_desc: desc::parse_opt_panic_strategy,
                    desc: "panic strategy to compile crate with",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "passes",
                    setter: cgopts::passes,
                    type_desc: desc::parse_list,
                    desc: "a list of extra LLVM passes to run (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "prefer_dynamic",
                    setter: cgopts::prefer_dynamic,
                    type_desc: desc::parse_bool,
                    desc: "prefer dynamic linking to static linking (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "profile_generate",
                    setter: cgopts::profile_generate,
                    type_desc: desc::parse_switch_with_opt_path,
                    desc: "compile the program with profiling instrumentation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "profile_use",
                    setter: cgopts::profile_use,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "use the given `.profdata` file for profile-guided optimization",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "relocation_model",
                    setter: cgopts::relocation_model,
                    type_desc: desc::parse_relocation_model,
                    desc: "control generation of position-independent code (PIC) \
        (`rustc --print relocation-models` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "relro_level",
                    setter: cgopts::relro_level,
                    type_desc: desc::parse_relro_level,
                    desc: "choose which RELRO level to use",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "remark",
                    setter: cgopts::remark,
                    type_desc: desc::parse_passes,
                    desc: "output remarks for these optimization passes (space separated, or \"all\")",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "rpath",
                    setter: cgopts::rpath,
                    type_desc: desc::parse_bool,
                    desc: "set rpath values in libs/exes (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "save_temps",
                    setter: cgopts::save_temps,
                    type_desc: desc::parse_bool,
                    desc: "save all temporary output files during compilation (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "soft_float",
                    setter: cgopts::soft_float,
                    type_desc: desc::parse_bool,
                    desc: "deprecated option: use soft float ABI (*eabihf targets only) (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "split_debuginfo",
                    setter: cgopts::split_debuginfo,
                    type_desc: desc::parse_split_debuginfo,
                    desc: "how to handle split-debuginfo, a platform-specific option",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "strip",
                    setter: cgopts::strip,
                    type_desc: desc::parse_strip,
                    desc: "tell the linker which information to strip (`none` (default), `debuginfo` or `symbols`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "symbol_mangling_version",
                    setter: cgopts::symbol_mangling_version,
                    type_desc: desc::parse_symbol_mangling_version,
                    desc: "which mangling version to use for symbol names ('legacy' (default), 'v0', or 'hashed')",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "target_cpu",
                    setter: cgopts::target_cpu,
                    type_desc: desc::parse_opt_string,
                    desc: "select target processor (`rustc --print target-cpus` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "target_feature",
                    setter: cgopts::target_feature,
                    type_desc: desc::parse_target_feature,
                    desc: "target specific attributes. (`rustc --print target-features` for details). \
        This feature is unsafe.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "unsafe_allow_abi_mismatch",
                    setter: cgopts::unsafe_allow_abi_mismatch,
                    type_desc: desc::parse_comma_list,
                    desc: "Allow incompatible target modifiers in dependency crates (comma separated list)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                }];
mod cgopts {
    pub(super) fn ar(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_string(&mut cg.ar, v)
    }
    pub(super) fn code_model(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_code_model(&mut cg.code_model, v)
    }
    pub(super) fn codegen_units(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.codegen_units, v)
    }
    pub(super) fn collapse_macro_debuginfo(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_collapse_macro_debuginfo(&mut cg.collapse_macro_debuginfo,
            v)
    }
    pub(super) fn control_flow_guard(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_cfguard(&mut cg.control_flow_guard, v)
    }
    pub(super) fn debug_assertions(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.debug_assertions, v)
    }
    pub(super) fn debuginfo(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_debuginfo(&mut cg.debuginfo, v)
    }
    pub(super) fn default_linker_libraries(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.default_linker_libraries, v)
    }
    pub(super) fn dlltool(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.dlltool, v)
    }
    pub(super) fn dwarf_version(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.dwarf_version, v)
    }
    pub(super) fn embed_bitcode(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.embed_bitcode, v)
    }
    pub(super) fn extra_filename(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.extra_filename, v)
    }
    pub(super) fn force_frame_pointers(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_frame_pointer(&mut cg.force_frame_pointers, v)
    }
    pub(super) fn force_unwind_tables(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.force_unwind_tables, v)
    }
    pub(super) fn help(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_no_value(&mut cg.help, v)
    }
    pub(super) fn incremental(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_string(&mut cg.incremental, v)
    }
    pub(super) fn inline_threshold(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.inline_threshold, v)
    }
    pub(super) fn instrument_coverage(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_instrument_coverage(&mut cg.instrument_coverage,
            v)
    }
    pub(super) fn jump_tables(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.jump_tables, v)
    }
    pub(super) fn link_arg(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_string_push(&mut cg.link_args, v)
    }
    pub(super) fn link_args(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_list(&mut cg.link_args, v)
    }
    pub(super) fn link_dead_code(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.link_dead_code, v)
    }
    pub(super) fn link_self_contained(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_link_self_contained(&mut cg.link_self_contained,
            v)
    }
    pub(super) fn linker(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.linker, v)
    }
    pub(super) fn linker_features(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_linker_features(&mut cg.linker_features, v)
    }
    pub(super) fn linker_flavor(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_linker_flavor(&mut cg.linker_flavor, v)
    }
    pub(super) fn linker_plugin_lto(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_linker_plugin_lto(&mut cg.linker_plugin_lto, v)
    }
    pub(super) fn llvm_args(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_list(&mut cg.llvm_args, v)
    }
    pub(super) fn lto(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_lto(&mut cg.lto, v)
    }
    pub(super) fn metadata(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_list(&mut cg.metadata, v)
    }
    pub(super) fn no_prepopulate_passes(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_prepopulate_passes, v)
    }
    pub(super) fn no_redzone(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_bool(&mut cg.no_redzone, v)
    }
    pub(super) fn no_stack_check(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_stack_check, v)
    }
    pub(super) fn no_vectorize_loops(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_vectorize_loops, v)
    }
    pub(super) fn no_vectorize_slp(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_vectorize_slp, v)
    }
    pub(super) fn opt_level(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_string(&mut cg.opt_level, v)
    }
    pub(super) fn overflow_checks(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.overflow_checks, v)
    }
    pub(super) fn panic(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_panic_strategy(&mut cg.panic, v)
    }
    pub(super) fn passes(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_list(&mut cg.passes, v)
    }
    pub(super) fn prefer_dynamic(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.prefer_dynamic, v)
    }
    pub(super) fn profile_generate(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_switch_with_opt_path(&mut cg.profile_generate, v)
    }
    pub(super) fn profile_use(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.profile_use, v)
    }
    pub(super) fn relocation_model(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_relocation_model(&mut cg.relocation_model, v)
    }
    pub(super) fn relro_level(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_relro_level(&mut cg.relro_level, v)
    }
    pub(super) fn remark(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_passes(&mut cg.remark, v)
    }
    pub(super) fn rpath(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.rpath, v)
    }
    pub(super) fn save_temps(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.save_temps, v)
    }
    pub(super) fn soft_float(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.soft_float, v)
    }
    pub(super) fn split_debuginfo(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_split_debuginfo(&mut cg.split_debuginfo, v)
    }
    pub(super) fn strip(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_strip(&mut cg.strip, v)
    }
    pub(super) fn symbol_mangling_version(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_symbol_mangling_version(&mut cg.symbol_mangling_version,
            v)
    }
    pub(super) fn target_cpu(cg: &mut super::CodegenOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_string(&mut cg.target_cpu, v)
    }
    pub(super) fn target_feature(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_target_feature(&mut cg.target_feature, v)
    }
    pub(super) fn unsafe_allow_abi_mismatch(cg: &mut super::CodegenOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_comma_list(&mut cg.unsafe_allow_abi_mismatch, v)
    }
}options! {
2064    CodegenOptions, CodegenOptionsTargetModifiers, CG_OPTIONS, cgopts, "C", "codegen",
2065
2066    // If you add a new option, please update:
2067    // - compiler/rustc_interface/src/tests.rs
2068    // - src/doc/rustc/src/codegen-options/index.md
2069
2070    // tidy-alphabetical-start
2071    #[rustc_lint_opt_deny_field_access("documented to do nothing")]
2072    ar: String = (String::new(), parse_string, [UNTRACKED],
2073        "this option is deprecated and does nothing",
2074        deprecated_do_nothing: true),
2075    #[rustc_lint_opt_deny_field_access("use `Session::code_model` instead of this field")]
2076    code_model: Option<CodeModel> = (None, parse_code_model, [TRACKED],
2077        "choose the code model to use (`rustc --print code-models` for details)"),
2078    codegen_units: Option<usize> = (None, parse_opt_number, [UNTRACKED],
2079        "divide crate into N units to optimize in parallel"),
2080    collapse_macro_debuginfo: CollapseMacroDebuginfo = (CollapseMacroDebuginfo::Unspecified,
2081        parse_collapse_macro_debuginfo, [TRACKED],
2082        "set option to collapse debuginfo for macros"),
2083    control_flow_guard: CFGuard = (CFGuard::Disabled, parse_cfguard, [TRACKED],
2084        "use Windows Control Flow Guard (default: no)"),
2085    debug_assertions: Option<bool> = (None, parse_opt_bool, [TRACKED],
2086        "explicitly enable the `cfg(debug_assertions)` directive"),
2087    debuginfo: DebugInfo = (DebugInfo::None, parse_debuginfo, [TRACKED],
2088        "debug info emission level (0-2, none, line-directives-only, \
2089        line-tables-only, limited, or full; default: 0)"),
2090    default_linker_libraries: bool = (false, parse_bool, [UNTRACKED],
2091        "allow the linker to link its default libraries (default: no)"),
2092    dlltool: Option<PathBuf> = (None, parse_opt_pathbuf, [UNTRACKED],
2093        "import library generation tool (ignored except when targeting windows-gnu)"),
2094    #[rustc_lint_opt_deny_field_access("use `Session::dwarf_version` instead of this field")]
2095    dwarf_version: Option<u32> = (None, parse_opt_number, [TRACKED],
2096        "version of DWARF debug information to emit (default: 2 or 4, depending on platform)"),
2097    embed_bitcode: bool = (true, parse_bool, [TRACKED],
2098        "emit bitcode in rlibs (default: yes)"),
2099    extra_filename: String = (String::new(), parse_string, [UNTRACKED],
2100        "extra data to put in each output filename"),
2101    force_frame_pointers: FramePointer = (FramePointer::MayOmit, parse_frame_pointer, [TRACKED],
2102        "force use of the frame pointers"),
2103    #[rustc_lint_opt_deny_field_access("use `Session::must_emit_unwind_tables` instead of this field")]
2104    force_unwind_tables: Option<bool> = (None, parse_opt_bool, [TRACKED],
2105        "force use of unwind tables"),
2106    help: bool = (false, parse_no_value, [UNTRACKED], "Print codegen options"),
2107    incremental: Option<String> = (None, parse_opt_string, [UNTRACKED],
2108        "enable incremental compilation"),
2109    #[rustc_lint_opt_deny_field_access("documented to do nothing")]
2110    inline_threshold: Option<u32> = (None, parse_opt_number, [UNTRACKED],
2111        "this option is deprecated and does nothing \
2112        (consider using `-Cllvm-args=--inline-threshold=...`)",
2113        deprecated_do_nothing: true),
2114    #[rustc_lint_opt_deny_field_access("use `Session::instrument_coverage` instead of this field")]
2115    instrument_coverage: InstrumentCoverage = (InstrumentCoverage::No, parse_instrument_coverage, [TRACKED],
2116        "instrument the generated code to support LLVM source-based code coverage reports \
2117        (note, the compiler build config must include `profiler = true`); \
2118        implies `-C symbol-mangling-version=v0`"),
2119    jump_tables: bool = (true, parse_bool, [TRACKED],
2120        "allow jump table and lookup table generation from switch case lowering (default: yes)"),
2121    link_arg: (/* redirected to link_args */) = ((), parse_string_push, [UNTRACKED],
2122        "a single extra argument to append to the linker invocation (can be used several times)"),
2123    link_args: Vec<String> = (Vec::new(), parse_list, [UNTRACKED],
2124        "extra arguments to append to the linker invocation (space separated)"),
2125    #[rustc_lint_opt_deny_field_access("use `Session::link_dead_code` instead of this field")]
2126    link_dead_code: Option<bool> = (None, parse_opt_bool, [TRACKED],
2127        "try to generate and link dead code (default: no)"),
2128    link_self_contained: LinkSelfContained = (LinkSelfContained::default(), parse_link_self_contained, [UNTRACKED],
2129        "control whether to link Rust provided C objects/libraries or rely \
2130        on a C toolchain or linker installed in the system"),
2131    linker: Option<PathBuf> = (None, parse_opt_pathbuf, [UNTRACKED],
2132        "system linker to link outputs with"),
2133    linker_features: LinkerFeaturesCli = (LinkerFeaturesCli::default(), parse_linker_features, [UNTRACKED],
2134        "a comma-separated list of linker features to enable (+) or disable (-): `lld`"),
2135    linker_flavor: Option<LinkerFlavorCli> = (None, parse_linker_flavor, [UNTRACKED],
2136        "linker flavor"),
2137    linker_plugin_lto: LinkerPluginLto = (LinkerPluginLto::Disabled,
2138        parse_linker_plugin_lto, [TRACKED],
2139        "generate build artifacts that are compatible with linker-based LTO"),
2140    llvm_args: Vec<String> = (Vec::new(), parse_list, [TRACKED],
2141        "a list of arguments to pass to LLVM (space separated)"),
2142    #[rustc_lint_opt_deny_field_access("use `Session::lto` instead of this field")]
2143    lto: LtoCli = (LtoCli::Unspecified, parse_lto, [TRACKED],
2144        "perform LLVM link-time optimizations"),
2145    metadata: Vec<String> = (Vec::new(), parse_list, [TRACKED],
2146        "metadata to mangle symbol names with"),
2147    no_prepopulate_passes: bool = (false, parse_no_value, [TRACKED],
2148        "give an empty list of passes to the pass manager"),
2149    no_redzone: Option<bool> = (None, parse_opt_bool, [TRACKED],
2150        "disable the use of the redzone"),
2151    #[rustc_lint_opt_deny_field_access("documented to do nothing")]
2152    no_stack_check: bool = (false, parse_no_value, [UNTRACKED],
2153        "this option is deprecated and does nothing",
2154        deprecated_do_nothing: true),
2155    no_vectorize_loops: bool = (false, parse_no_value, [TRACKED],
2156        "disable loop vectorization optimization passes"),
2157    no_vectorize_slp: bool = (false, parse_no_value, [TRACKED],
2158        "disable LLVM's SLP vectorization pass"),
2159    opt_level: String = ("0".to_string(), parse_string, [TRACKED],
2160        "optimization level (0-3, s, or z; default: 0)"),
2161    #[rustc_lint_opt_deny_field_access("use `Session::overflow_checks` instead of this field")]
2162    overflow_checks: Option<bool> = (None, parse_opt_bool, [TRACKED],
2163        "use overflow checks for integer arithmetic"),
2164    #[rustc_lint_opt_deny_field_access("use `Session::panic_strategy` instead of this field")]
2165    panic: Option<PanicStrategy> = (None, parse_opt_panic_strategy, [TRACKED],
2166        "panic strategy to compile crate with"),
2167    passes: Vec<String> = (Vec::new(), parse_list, [TRACKED],
2168        "a list of extra LLVM passes to run (space separated)"),
2169    prefer_dynamic: bool = (false, parse_bool, [TRACKED],
2170        "prefer dynamic linking to static linking (default: no)"),
2171    profile_generate: SwitchWithOptPath = (SwitchWithOptPath::Disabled,
2172        parse_switch_with_opt_path, [TRACKED],
2173        "compile the program with profiling instrumentation"),
2174    profile_use: Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2175        "use the given `.profdata` file for profile-guided optimization"),
2176    #[rustc_lint_opt_deny_field_access("use `Session::relocation_model` instead of this field")]
2177    relocation_model: Option<RelocModel> = (None, parse_relocation_model, [TRACKED],
2178        "control generation of position-independent code (PIC) \
2179        (`rustc --print relocation-models` for details)"),
2180    relro_level: Option<RelroLevel> = (None, parse_relro_level, [TRACKED],
2181        "choose which RELRO level to use"),
2182    remark: Passes = (Passes::Some(Vec::new()), parse_passes, [UNTRACKED],
2183        "output remarks for these optimization passes (space separated, or \"all\")"),
2184    rpath: bool = (false, parse_bool, [UNTRACKED],
2185        "set rpath values in libs/exes (default: no)"),
2186    save_temps: bool = (false, parse_bool, [UNTRACKED],
2187        "save all temporary output files during compilation (default: no)"),
2188    soft_float: bool = (false, parse_bool, [TRACKED],
2189        "deprecated option: use soft float ABI (*eabihf targets only) (default: no)"),
2190    #[rustc_lint_opt_deny_field_access("use `Session::split_debuginfo` instead of this field")]
2191    split_debuginfo: Option<SplitDebuginfo> = (None, parse_split_debuginfo, [TRACKED],
2192        "how to handle split-debuginfo, a platform-specific option"),
2193    strip: Strip = (Strip::None, parse_strip, [UNTRACKED],
2194        "tell the linker which information to strip (`none` (default), `debuginfo` or `symbols`)"),
2195    symbol_mangling_version: Option<SymbolManglingVersion> = (None,
2196        parse_symbol_mangling_version, [TRACKED],
2197        "which mangling version to use for symbol names ('legacy' (default), 'v0', or 'hashed')"),
2198    target_cpu: Option<String> = (None, parse_opt_string, [TRACKED],
2199        "select target processor (`rustc --print target-cpus` for details)"),
2200    target_feature: String = (String::new(), parse_target_feature, [TRACKED],
2201        "target specific attributes. (`rustc --print target-features` for details). \
2202        This feature is unsafe."),
2203    unsafe_allow_abi_mismatch: Vec<String> = (Vec::new(), parse_comma_list, [UNTRACKED],
2204        "Allow incompatible target modifiers in dependency crates (comma separated list)"),
2205    // tidy-alphabetical-end
2206
2207    // If you add a new option, please update:
2208    // - compiler/rustc_interface/src/tests.rs
2209    // - src/doc/rustc/src/codegen-options/index.md
2210}
2211
2212#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialEq for UnstableOptionsTargetModifiers {
    #[inline]
    fn eq(&self, other: &UnstableOptionsTargetModifiers) -> bool {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        __self_discr == __arg1_discr
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Eq for UnstableOptionsTargetModifiers {
    #[inline]
    #[doc(hidden)]
    #[coverage(off)]
    fn assert_receiver_is_total_eq(&self) {}
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::PartialOrd for UnstableOptionsTargetModifiers {
    #[inline]
    fn partial_cmp(&self, other: &UnstableOptionsTargetModifiers)
        -> ::core::option::Option<::core::cmp::Ordering> {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        ::core::cmp::PartialOrd::partial_cmp(&__self_discr, &__arg1_discr)
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::cmp::Ord for UnstableOptionsTargetModifiers {
    #[inline]
    fn cmp(&self, other: &UnstableOptionsTargetModifiers)
        -> ::core::cmp::Ordering {
        let __self_discr = ::core::intrinsics::discriminant_value(self);
        let __arg1_discr = ::core::intrinsics::discriminant_value(other);
        ::core::cmp::Ord::cmp(&__self_discr, &__arg1_discr)
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::fmt::Debug for UnstableOptionsTargetModifiers {
    #[inline]
    fn fmt(&self, f: &mut ::core::fmt::Formatter) -> ::core::fmt::Result {
        ::core::fmt::Formatter::write_str(f,
            match self {
                UnstableOptionsTargetModifiers::fixed_x18 => "fixed_x18",
                UnstableOptionsTargetModifiers::indirect_branch_cs_prefix =>
                    "indirect_branch_cs_prefix",
                UnstableOptionsTargetModifiers::reg_struct_return =>
                    "reg_struct_return",
                UnstableOptionsTargetModifiers::regparm => "regparm",
                UnstableOptionsTargetModifiers::retpoline => "retpoline",
                UnstableOptionsTargetModifiers::retpoline_external_thunk =>
                    "retpoline_external_thunk",
                UnstableOptionsTargetModifiers::sanitizer => "sanitizer",
                UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers
                    => "sanitizer_cfi_normalize_integers",
            })
    }
}
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::marker::Copy for UnstableOptionsTargetModifiers { }
#[automatically_derived]
#[doc(hidden)]
#[allow(non_camel_case_types)]
unsafe impl ::core::clone::TrivialClone for UnstableOptionsTargetModifiers { }
#[automatically_derived]
#[allow(non_camel_case_types)]
impl ::core::clone::Clone for UnstableOptionsTargetModifiers {
    #[inline]
    fn clone(&self) -> UnstableOptionsTargetModifiers { *self }
}
const _: () =
    {
        impl<__E: ::rustc_span::SpanEncoder> ::rustc_serialize::Encodable<__E>
            for UnstableOptionsTargetModifiers {
            fn encode(&self, __encoder: &mut __E) {
                let disc =
                    match *self {
                        UnstableOptionsTargetModifiers::fixed_x18 => { 0usize }
                        UnstableOptionsTargetModifiers::indirect_branch_cs_prefix =>
                            {
                            1usize
                        }
                        UnstableOptionsTargetModifiers::reg_struct_return => {
                            2usize
                        }
                        UnstableOptionsTargetModifiers::regparm => { 3usize }
                        UnstableOptionsTargetModifiers::retpoline => { 4usize }
                        UnstableOptionsTargetModifiers::retpoline_external_thunk =>
                            {
                            5usize
                        }
                        UnstableOptionsTargetModifiers::sanitizer => { 6usize }
                        UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers
                            => {
                            7usize
                        }
                    };
                ::rustc_serialize::Encoder::emit_u8(__encoder, disc as u8);
                match *self {
                    UnstableOptionsTargetModifiers::fixed_x18 => {}
                    UnstableOptionsTargetModifiers::indirect_branch_cs_prefix =>
                        {}
                    UnstableOptionsTargetModifiers::reg_struct_return => {}
                    UnstableOptionsTargetModifiers::regparm => {}
                    UnstableOptionsTargetModifiers::retpoline => {}
                    UnstableOptionsTargetModifiers::retpoline_external_thunk =>
                        {}
                    UnstableOptionsTargetModifiers::sanitizer => {}
                    UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers
                        => {}
                }
            }
        }
    };
const _: () =
    {
        impl<__D: ::rustc_span::BlobDecoder> ::rustc_serialize::Decodable<__D>
            for UnstableOptionsTargetModifiers {
            fn decode(__decoder: &mut __D) -> Self {
                match ::rustc_serialize::Decoder::read_u8(__decoder) as usize
                    {
                    0usize => { UnstableOptionsTargetModifiers::fixed_x18 }
                    1usize => {
                        UnstableOptionsTargetModifiers::indirect_branch_cs_prefix
                    }
                    2usize => {
                        UnstableOptionsTargetModifiers::reg_struct_return
                    }
                    3usize => { UnstableOptionsTargetModifiers::regparm }
                    4usize => { UnstableOptionsTargetModifiers::retpoline }
                    5usize => {
                        UnstableOptionsTargetModifiers::retpoline_external_thunk
                    }
                    6usize => { UnstableOptionsTargetModifiers::sanitizer }
                    7usize => {
                        UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers
                    }
                    n => {
                        ::core::panicking::panic_fmt(format_args!("invalid enum variant tag while decoding `UnstableOptionsTargetModifiers`, expected 0..8, actual {0}",
                                n));
                    }
                }
            }
        }
    };
impl UnstableOptionsTargetModifiers {
    #[allow(unused_variables)]
    pub fn reparse(&self, user_value: &str) -> ExtendedTargetModifierInfo {

        #[allow(unreachable_patterns)]
        match self {
            Self::fixed_x18 => {
                let mut parsed: bool = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "fixed_x18".to_string().replace('_', "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::indirect_branch_cs_prefix => {
                let mut parsed: bool = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "indirect_branch_cs_prefix".to_string().replace('_',
                        "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::reg_struct_return => {
                let mut parsed: bool = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "reg_struct_return".to_string().replace('_', "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::regparm => {
                let mut parsed: Option<u32> = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_opt_number(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "regparm".to_string().replace('_', "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::retpoline => {
                let mut parsed: bool = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "retpoline".to_string().replace('_', "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::retpoline_external_thunk => {
                let mut parsed: bool = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "retpoline_external_thunk".to_string().replace('_',
                        "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::sanitizer => {
                let mut parsed: SanitizerSet = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_sanitizers(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "sanitizer".to_string().replace('_', "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            Self::sanitizer_cfi_normalize_integers => {
                let mut parsed: Option<bool> = Default::default();
                let val =
                    if user_value.is_empty() { None } else { Some(user_value) };
                parse::parse_opt_bool(&mut parsed, val);
                ExtendedTargetModifierInfo {
                    prefix: "Z".to_string(),
                    name: "sanitizer_cfi_normalize_integers".to_string().replace('_',
                        "-"),
                    tech_value: ::alloc::__export::must_use({
                            ::alloc::fmt::format(format_args!("{0:?}", parsed))
                        }),
                }
            }
            _ => {
                ::core::panicking::panic_fmt(format_args!("unknown target modifier option: {0:?}",
                        *self));
            }
        }
    }
    pub fn is_target_modifier(flag_name: &str) -> bool {
        match flag_name.replace('-', "_").as_str() {
            "fixed_x18" => true,
            "indirect_branch_cs_prefix" => true,
            "reg_struct_return" => true,
            "regparm" => true,
            "retpoline" => true,
            "retpoline_external_thunk" => true,
            "sanitizer" => true,
            "sanitizer_cfi_normalize_integers" => true,
            _ => false,
        }
    }
}
impl Default for UnstableOptions {
    fn default() -> UnstableOptions {
        UnstableOptions {
            allow_features: None,
            always_encode_mir: false,
            annotate_moves: AnnotateMoves::Disabled,
            assert_incr_state: None,
            assume_incomplete_release: false,
            autodiff: Vec::new(),
            binary_dep_depinfo: false,
            box_noalias: true,
            branch_protection: None,
            build_sdylib_interface: false,
            cache_proc_macros: false,
            cf_protection: CFProtection::None,
            check_cfg_all_expected: false,
            checksum_hash_algorithm: None,
            codegen_backend: None,
            codegen_source_order: false,
            contract_checks: None,
            coverage_options: CoverageOptions::default(),
            crate_attr: Vec::new(),
            cross_crate_inline_threshold: InliningThreshold::Sometimes(100),
            debug_info_for_profiling: false,
            debug_info_type_line_numbers: false,
            debuginfo_compression: DebugInfoCompression::None,
            deduplicate_diagnostics: true,
            default_visibility: None,
            dep_info_omit_d_target: false,
            direct_access_external_data: None,
            dual_proc_macros: false,
            dump_dep_graph: false,
            dump_mir: None,
            dump_mir_dataflow: false,
            dump_mir_dir: "mir_dump".to_string(),
            dump_mir_exclude_alloc_bytes: false,
            dump_mir_exclude_pass_number: false,
            dump_mir_graphviz: false,
            dump_mono_stats: SwitchWithOptPath::Disabled,
            dump_mono_stats_format: DumpMonoStatsFormat::Markdown,
            dwarf_version: None,
            dylib_lto: false,
            eagerly_emit_delayed_bugs: false,
            ehcont_guard: false,
            embed_metadata: true,
            embed_source: false,
            emit_stack_sizes: false,
            emit_thin_lto: true,
            emscripten_wasm_eh: true,
            enforce_type_length_limit: false,
            experimental_default_bounds: false,
            export_executable_symbols: false,
            external_clangrt: false,
            extra_const_ub_checks: false,
            fewer_names: None,
            fixed_x18: false,
            flatten_format_args: true,
            fmt_debug: FmtDebug::Full,
            force_unstable_if_unmarked: false,
            function_return: FunctionReturn::default(),
            function_sections: None,
            future_incompat_test: false,
            graphviz_dark_mode: false,
            graphviz_font: "Courier, monospace".to_string(),
            has_thread_local: None,
            help: false,
            higher_ranked_assumptions: false,
            hint_mostly_unused: false,
            human_readable_cgu_names: false,
            identify_regions: false,
            ignore_directory_in_diagnostics_source_blocks: Vec::new(),
            incremental_ignore_spans: false,
            incremental_info: false,
            incremental_verify_ich: false,
            indirect_branch_cs_prefix: false,
            inline_llvm: true,
            inline_mir: None,
            inline_mir_forwarder_threshold: None,
            inline_mir_hint_threshold: None,
            inline_mir_preserve_debug: None,
            inline_mir_threshold: None,
            input_stats: false,
            instrument_mcount: false,
            instrument_xray: None,
            large_data_threshold: None,
            layout_seed: None,
            link_directives: true,
            link_native_libraries: true,
            link_only: false,
            lint_llvm_ir: false,
            lint_mir: false,
            llvm_module_flag: Vec::new(),
            llvm_plugins: Vec::new(),
            llvm_time_trace: false,
            location_detail: LocationDetail::all(),
            ls: Vec::new(),
            macro_backtrace: false,
            macro_stats: false,
            maximal_hir_to_mir_coverage: false,
            merge_functions: None,
            meta_stats: false,
            metrics_dir: None,
            min_function_alignment: None,
            mir_emit_retag: false,
            mir_enable_passes: Vec::new(),
            mir_include_spans: MirIncludeSpans::default(),
            mir_opt_level: None,
            mir_preserve_ub: false,
            mir_strip_debuginfo: MirStripDebugInfo::None,
            move_size_limit: None,
            mutable_noalias: true,
            namespaced_crates: false,
            next_solver: NextSolverConfig::default(),
            nll_facts: false,
            nll_facts_dir: "nll-facts".to_string(),
            no_analysis: false,
            no_codegen: false,
            no_generate_arange_section: false,
            no_implied_bounds_compat: false,
            no_leak_check: false,
            no_link: false,
            no_parallel_backend: false,
            no_profiler_runtime: false,
            no_steal_thir: false,
            no_trait_vptr: false,
            no_unique_section_names: false,
            normalize_docs: false,
            offload: Vec::new(),
            on_broken_pipe: OnBrokenPipe::Default,
            osx_rpath_install_name: false,
            packed_bundled_libs: false,
            panic_abort_tests: false,
            panic_in_drop: PanicStrategy::Unwind,
            parse_crate_root_only: false,
            patchable_function_entry: PatchableFunctionEntry::default(),
            plt: None,
            polonius: Polonius::default(),
            pre_link_arg: (),
            pre_link_args: Vec::new(),
            precise_enum_drop_elaboration: true,
            print_codegen_stats: false,
            print_llvm_passes: false,
            print_mono_items: false,
            print_type_sizes: false,
            proc_macro_backtrace: false,
            proc_macro_execution_strategy: ProcMacroExecutionStrategy::SameThread,
            profile_closures: false,
            profile_sample_use: None,
            profiler_runtime: String::from("profiler_builtins"),
            query_dep_graph: false,
            randomize_layout: false,
            reg_struct_return: false,
            regparm: None,
            relax_elf_relocations: None,
            remap_cwd_prefix: None,
            remark_dir: None,
            retpoline: false,
            retpoline_external_thunk: false,
            sanitizer: SanitizerSet::empty(),
            sanitizer_cfi_canonical_jump_tables: Some(true),
            sanitizer_cfi_generalize_pointers: None,
            sanitizer_cfi_normalize_integers: None,
            sanitizer_dataflow_abilist: Vec::new(),
            sanitizer_kcfi_arity: None,
            sanitizer_memory_track_origins: 0,
            sanitizer_recover: SanitizerSet::empty(),
            saturating_float_casts: None,
            self_profile: SwitchWithOptPath::Disabled,
            self_profile_counter: "wall-time".to_string(),
            self_profile_events: None,
            share_generics: None,
            shell_argfiles: false,
            simulate_remapped_rust_src_base: None,
            small_data_threshold: None,
            span_debug: false,
            span_free_formats: false,
            split_dwarf_inlining: false,
            split_dwarf_kind: SplitDwarfKind::Split,
            split_dwarf_out_dir: None,
            split_lto_unit: None,
            src_hash_algorithm: None,
            stack_protector: StackProtector::None,
            staticlib_allow_rdylib_deps: false,
            staticlib_prefer_dynamic: false,
            strict_init_checks: false,
            teach: false,
            temps_dir: None,
            terminal_urls: TerminalUrl::No,
            thinlto: None,
            threads: 1,
            time_llvm_passes: false,
            time_passes: false,
            time_passes_format: TimePassesFormat::Text,
            tiny_const_eval_limit: false,
            tls_model: None,
            trace_macros: false,
            track_diagnostics: false,
            translate_additional_ftl: None,
            translate_directionality_markers: false,
            translate_lang: None,
            translate_remapped_path_to_local_path: true,
            trap_unreachable: None,
            treat_err_as_bug: None,
            trim_diagnostic_paths: true,
            tune_cpu: None,
            typing_mode_borrowck: false,
            ub_checks: None,
            ui_testing: false,
            uninit_const_chunk_threshold: 16,
            unleash_the_miri_inside_of_you: false,
            unpretty: None,
            unsound_mir_opts: false,
            unstable_options: false,
            use_ctors_section: None,
            use_sync_unwind: None,
            validate_mir: false,
            verbose_asm: false,
            verbose_internals: false,
            verify_llvm_ir: false,
            virtual_function_elimination: false,
            wasi_exec_model: None,
            wasm_c_abi: (),
            write_long_types_to_disk: true,
        }
    }
}
impl UnstableOptions {
    pub fn build(early_dcx: &EarlyDiagCtxt, matches: &getopts::Matches,
        target_modifiers: &mut BTreeMap<OptionsTargetModifiers, String>)
        -> UnstableOptions {
        build_options(early_dcx, matches, target_modifiers, Z_OPTIONS, "Z",
            "unstable")
    }
    fn dep_tracking_hash(&self, for_crate_hash: bool,
        error_format: ErrorOutputType) -> Hash64 {
        let mut sub_hashes = BTreeMap::new();
        {
            {
                if (&mut sub_hashes).insert("allow_features",
                            &self.allow_features as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "allow_features"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("always_encode_mir",
                            &self.always_encode_mir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "always_encode_mir"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("annotate_moves",
                            &self.annotate_moves as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "annotate_moves"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("assume_incomplete_release",
                            &self.assume_incomplete_release as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "assume_incomplete_release"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("autodiff",
                            &self.autodiff as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "autodiff"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("binary_dep_depinfo",
                            &self.binary_dep_depinfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "binary_dep_depinfo"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("box_noalias",
                            &self.box_noalias as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "box_noalias"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("branch_protection",
                            &self.branch_protection as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "branch_protection"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("cache_proc_macros",
                            &self.cache_proc_macros as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "cache_proc_macros"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("cf_protection",
                            &self.cf_protection as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "cf_protection"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("checksum_hash_algorithm",
                            &self.checksum_hash_algorithm as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "checksum_hash_algorithm"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("codegen_backend",
                            &self.codegen_backend as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "codegen_backend"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("contract_checks",
                            &self.contract_checks as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "contract_checks"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("coverage_options",
                            &self.coverage_options as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "coverage_options"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("crate_attr",
                            &self.crate_attr as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "crate_attr"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("cross_crate_inline_threshold",
                            &self.cross_crate_inline_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "cross_crate_inline_threshold"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debug_info_for_profiling",
                            &self.debug_info_for_profiling as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debug_info_for_profiling"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debug_info_type_line_numbers",
                            &self.debug_info_type_line_numbers as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debug_info_type_line_numbers"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("debuginfo_compression",
                            &self.debuginfo_compression as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "debuginfo_compression"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("default_visibility",
                            &self.default_visibility as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "default_visibility"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("dep_info_omit_d_target",
                            &self.dep_info_omit_d_target as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "dep_info_omit_d_target"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("direct_access_external_data",
                            &self.direct_access_external_data as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "direct_access_external_data"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("dual_proc_macros",
                            &self.dual_proc_macros as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "dual_proc_macros"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("dwarf_version",
                            &self.dwarf_version as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "dwarf_version"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("ehcont_guard",
                            &self.ehcont_guard as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "ehcont_guard"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("embed_metadata",
                            &self.embed_metadata as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "embed_metadata"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("embed_source",
                            &self.embed_source as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "embed_source"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("emit_thin_lto",
                            &self.emit_thin_lto as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "emit_thin_lto"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("emscripten_wasm_eh",
                            &self.emscripten_wasm_eh as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "emscripten_wasm_eh"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("enforce_type_length_limit",
                            &self.enforce_type_length_limit as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "enforce_type_length_limit"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("experimental_default_bounds",
                            &self.experimental_default_bounds as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "experimental_default_bounds"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("export_executable_symbols",
                            &self.export_executable_symbols as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "export_executable_symbols"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("extra_const_ub_checks",
                            &self.extra_const_ub_checks as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "extra_const_ub_checks"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("fewer_names",
                            &self.fewer_names as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "fewer_names"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("fixed_x18",
                            &self.fixed_x18 as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "fixed_x18"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("flatten_format_args",
                            &self.flatten_format_args as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "flatten_format_args"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("fmt_debug",
                            &self.fmt_debug as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "fmt_debug"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("force_unstable_if_unmarked",
                            &self.force_unstable_if_unmarked as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "force_unstable_if_unmarked"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("function_return",
                            &self.function_return as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "function_return"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("function_sections",
                            &self.function_sections as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "function_sections"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("has_thread_local",
                            &self.has_thread_local as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "has_thread_local"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("higher_ranked_assumptions",
                            &self.higher_ranked_assumptions as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "higher_ranked_assumptions"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("hint_mostly_unused",
                            &self.hint_mostly_unused as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "hint_mostly_unused"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("human_readable_cgu_names",
                            &self.human_readable_cgu_names as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "human_readable_cgu_names"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("incremental_ignore_spans",
                            &self.incremental_ignore_spans as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "incremental_ignore_spans"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("indirect_branch_cs_prefix",
                            &self.indirect_branch_cs_prefix as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "indirect_branch_cs_prefix"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_llvm",
                            &self.inline_llvm as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_llvm"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_mir",
                            &self.inline_mir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_mir"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_mir_forwarder_threshold",
                            &self.inline_mir_forwarder_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_mir_forwarder_threshold"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_mir_hint_threshold",
                            &self.inline_mir_hint_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_mir_hint_threshold"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_mir_preserve_debug",
                            &self.inline_mir_preserve_debug as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_mir_preserve_debug"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("inline_mir_threshold",
                            &self.inline_mir_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "inline_mir_threshold"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("instrument_mcount",
                            &self.instrument_mcount as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "instrument_mcount"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("instrument_xray",
                            &self.instrument_xray as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "instrument_xray"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("large_data_threshold",
                            &self.large_data_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "large_data_threshold"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("layout_seed",
                            &self.layout_seed as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "layout_seed"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("link_directives",
                            &self.link_directives as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "link_directives"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("link_only",
                            &self.link_only as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "link_only"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("lint_llvm_ir",
                            &self.lint_llvm_ir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "lint_llvm_ir"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("llvm_module_flag",
                            &self.llvm_module_flag as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "llvm_module_flag"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("llvm_plugins",
                            &self.llvm_plugins as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "llvm_plugins"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("location_detail",
                            &self.location_detail as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "location_detail"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("maximal_hir_to_mir_coverage",
                            &self.maximal_hir_to_mir_coverage as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "maximal_hir_to_mir_coverage"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("merge_functions",
                            &self.merge_functions as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "merge_functions"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("min_function_alignment",
                            &self.min_function_alignment as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "min_function_alignment"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("mir_emit_retag",
                            &self.mir_emit_retag as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mir_emit_retag"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("mir_enable_passes",
                            &self.mir_enable_passes as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mir_enable_passes"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("mir_opt_level",
                            &self.mir_opt_level as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mir_opt_level"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("mir_preserve_ub",
                            &self.mir_preserve_ub as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mir_preserve_ub"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("mir_strip_debuginfo",
                            &self.mir_strip_debuginfo as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mir_strip_debuginfo"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("move_size_limit",
                            &self.move_size_limit as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "move_size_limit"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("mutable_noalias",
                            &self.mutable_noalias as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "mutable_noalias"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("namespaced_crates",
                            &self.namespaced_crates as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "namespaced_crates"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("next_solver",
                            &self.next_solver as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "next_solver"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("no_codegen",
                                &self.no_codegen as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "no_codegen"));
                        }
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_generate_arange_section",
                            &self.no_generate_arange_section as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_generate_arange_section"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_implied_bounds_compat",
                            &self.no_implied_bounds_compat as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_implied_bounds_compat"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("no_link",
                            &self.no_link as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_link"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("no_profiler_runtime",
                            &self.no_profiler_runtime as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_profiler_runtime"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("no_trait_vptr",
                            &self.no_trait_vptr as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_trait_vptr"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("no_unique_section_names",
                            &self.no_unique_section_names as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "no_unique_section_names"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("normalize_docs",
                            &self.normalize_docs as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "normalize_docs"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("offload",
                            &self.offload as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "offload"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("on_broken_pipe",
                            &self.on_broken_pipe as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "on_broken_pipe"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("osx_rpath_install_name",
                            &self.osx_rpath_install_name as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "osx_rpath_install_name"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("packed_bundled_libs",
                            &self.packed_bundled_libs as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "packed_bundled_libs"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("panic_abort_tests",
                            &self.panic_abort_tests as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "panic_abort_tests"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("panic_in_drop",
                            &self.panic_in_drop as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "panic_in_drop"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("patchable_function_entry",
                            &self.patchable_function_entry as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "patchable_function_entry"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("plt",
                            &self.plt as &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "plt"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("polonius",
                            &self.polonius as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "polonius"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("precise_enum_drop_elaboration",
                            &self.precise_enum_drop_elaboration as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "precise_enum_drop_elaboration"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("profile_sample_use",
                            &self.profile_sample_use as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "profile_sample_use"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("profiler_runtime",
                            &self.profiler_runtime as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "profiler_runtime"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("randomize_layout",
                            &self.randomize_layout as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "randomize_layout"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("reg_struct_return",
                            &self.reg_struct_return as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "reg_struct_return"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("regparm",
                            &self.regparm as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "regparm"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("relax_elf_relocations",
                            &self.relax_elf_relocations as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "relax_elf_relocations"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("remap_cwd_prefix",
                            &self.remap_cwd_prefix as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "remap_cwd_prefix"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("retpoline",
                            &self.retpoline as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "retpoline"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("retpoline_external_thunk",
                            &self.retpoline_external_thunk as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "retpoline_external_thunk"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer",
                            &self.sanitizer as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_cfi_canonical_jump_tables",
                            &self.sanitizer_cfi_canonical_jump_tables as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_cfi_canonical_jump_tables"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_cfi_generalize_pointers",
                            &self.sanitizer_cfi_generalize_pointers as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_cfi_generalize_pointers"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_cfi_normalize_integers",
                            &self.sanitizer_cfi_normalize_integers as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_cfi_normalize_integers"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_dataflow_abilist",
                            &self.sanitizer_dataflow_abilist as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_dataflow_abilist"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_kcfi_arity",
                            &self.sanitizer_kcfi_arity as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_kcfi_arity"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_memory_track_origins",
                            &self.sanitizer_memory_track_origins as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_memory_track_origins"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("sanitizer_recover",
                            &self.sanitizer_recover as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "sanitizer_recover"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("saturating_float_casts",
                            &self.saturating_float_casts as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "saturating_float_casts"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("share_generics",
                            &self.share_generics as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "share_generics"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("simulate_remapped_rust_src_base",
                            &self.simulate_remapped_rust_src_base as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "simulate_remapped_rust_src_base"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("small_data_threshold",
                            &self.small_data_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "small_data_threshold"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("split_dwarf_inlining",
                            &self.split_dwarf_inlining as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "split_dwarf_inlining"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("split_dwarf_kind",
                            &self.split_dwarf_kind as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "split_dwarf_kind"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("split_dwarf_out_dir",
                            &self.split_dwarf_out_dir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "split_dwarf_out_dir"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("split_lto_unit",
                            &self.split_lto_unit as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "split_lto_unit"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("src_hash_algorithm",
                            &self.src_hash_algorithm as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "src_hash_algorithm"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("stack_protector",
                            &self.stack_protector as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "stack_protector"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("staticlib_allow_rdylib_deps",
                            &self.staticlib_allow_rdylib_deps as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "staticlib_allow_rdylib_deps"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("staticlib_prefer_dynamic",
                            &self.staticlib_prefer_dynamic as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "staticlib_prefer_dynamic"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("strict_init_checks",
                            &self.strict_init_checks as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "strict_init_checks"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("teach",
                            &self.teach as &dyn dep_tracking::DepTrackingHash).is_some()
                    {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "teach"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("thinlto",
                            &self.thinlto as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "thinlto"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("tiny_const_eval_limit",
                            &self.tiny_const_eval_limit as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "tiny_const_eval_limit"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("tls_model",
                            &self.tls_model as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "tls_model"));
                    }
                }
            };
        }
        { {}; }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("translate_additional_ftl",
                            &self.translate_additional_ftl as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "translate_additional_ftl"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("translate_directionality_markers",
                            &self.translate_directionality_markers as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "translate_directionality_markers"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("translate_lang",
                            &self.translate_lang as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "translate_lang"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("translate_remapped_path_to_local_path",
                            &self.translate_remapped_path_to_local_path as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "translate_remapped_path_to_local_path"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("trap_unreachable",
                            &self.trap_unreachable as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "trap_unreachable"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("treat_err_as_bug",
                            &self.treat_err_as_bug as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "treat_err_as_bug"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("tune_cpu",
                            &self.tune_cpu as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "tune_cpu"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("typing_mode_borrowck",
                            &self.typing_mode_borrowck as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "typing_mode_borrowck"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("ub_checks",
                            &self.ub_checks as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "ub_checks"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("uninit_const_chunk_threshold",
                            &self.uninit_const_chunk_threshold as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "uninit_const_chunk_threshold"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("unleash_the_miri_inside_of_you",
                            &self.unleash_the_miri_inside_of_you as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "unleash_the_miri_inside_of_you"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("unsound_mir_opts",
                            &self.unsound_mir_opts as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "unsound_mir_opts"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("use_ctors_section",
                            &self.use_ctors_section as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "use_ctors_section"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("use_sync_unwind",
                            &self.use_sync_unwind as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "use_sync_unwind"));
                    }
                }
            };
        }
        { {}; }
        {
            {
                if (&mut sub_hashes).insert("verbose_asm",
                            &self.verbose_asm as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "verbose_asm"));
                    }
                }
            };
        }
        {
            {
                if !for_crate_hash {
                    if (&mut sub_hashes).insert("verbose_internals",
                                &self.verbose_internals as
                                    &dyn dep_tracking::DepTrackingHash).is_some() {
                        {
                            ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                    "verbose_internals"));
                        }
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("verify_llvm_ir",
                            &self.verify_llvm_ir as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "verify_llvm_ir"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("virtual_function_elimination",
                            &self.virtual_function_elimination as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "virtual_function_elimination"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("wasi_exec_model",
                            &self.wasi_exec_model as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "wasi_exec_model"));
                    }
                }
            };
        }
        {
            {
                if (&mut sub_hashes).insert("wasm_c_abi",
                            &self.wasm_c_abi as
                                &dyn dep_tracking::DepTrackingHash).is_some() {
                    {
                        ::core::panicking::panic_fmt(format_args!("duplicate key in CLI DepTrackingHash: {0}",
                                "wasm_c_abi"));
                    }
                }
            };
        }
        { {}; }
        let mut hasher = StableHasher::new();
        dep_tracking::stable_hash(sub_hashes, &mut hasher, error_format,
            for_crate_hash);
        hasher.finish()
    }
    pub fn gather_target_modifiers(&self, _mods: &mut Vec<TargetModifier>,
        _tmod_vals: &BTreeMap<OptionsTargetModifiers, String>) {
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            if *&self.fixed_x18 != false {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::fixed_x18),
                    _tmod_vals, _mods);
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            if *&self.indirect_branch_cs_prefix != false {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::indirect_branch_cs_prefix),
                    _tmod_vals, _mods);
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        {
            if *&self.reg_struct_return != false {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::reg_struct_return),
                    _tmod_vals, _mods);
            };
        }
        {
            if *&self.regparm != None {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::regparm),
                    _tmod_vals, _mods);
            };
        }
        { {}; }
        { {}; }
        { {}; }
        {
            if *&self.retpoline != false {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::retpoline),
                    _tmod_vals, _mods);
            };
        }
        {
            if *&self.retpoline_external_thunk != false {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::retpoline_external_thunk),
                    _tmod_vals, _mods);
            };
        }
        {
            if *&self.sanitizer != SanitizerSet::empty() {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::sanitizer),
                    _tmod_vals, _mods);
            };
        }
        { {}; }
        { {}; }
        {
            if *&self.sanitizer_cfi_normalize_integers != None {
                tmod_push_impl(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers),
                    _tmod_vals, _mods);
            };
        }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
        { {}; }
    }
}
pub const Z_OPTIONS: OptionDescrs<UnstableOptions> =
    &[OptionDesc {
                    name: "allow_features",
                    setter: dbopts::allow_features,
                    type_desc: desc::parse_opt_comma_list,
                    desc: "only allow the listed language features to be enabled in code (comma separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "always_encode_mir",
                    setter: dbopts::always_encode_mir,
                    type_desc: desc::parse_bool,
                    desc: "encode MIR of all functions into the crate metadata (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "annotate_moves",
                    setter: dbopts::annotate_moves,
                    type_desc: desc::parse_annotate_moves,
                    desc: "emit debug info for compiler-generated move and copy operations \
        to make them visible in profilers. Can be a boolean or a size limit in bytes (default: disabled)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "assert_incr_state",
                    setter: dbopts::assert_incr_state,
                    type_desc: desc::parse_opt_string,
                    desc: "assert that the incremental cache is in given state: \
         either `loaded` or `not-loaded`.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "assume_incomplete_release",
                    setter: dbopts::assume_incomplete_release,
                    type_desc: desc::parse_bool,
                    desc: "make cfg(version) treat the current version as incomplete (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "autodiff",
                    setter: dbopts::autodiff,
                    type_desc: desc::parse_autodiff,
                    desc: "a list of autodiff flags to enable
        Mandatory setting:
        `=Enable`
        Optional extra settings:
        `=PrintTA`
        `=PrintAA`
        `=PrintPerf`
        `=PrintSteps`
        `=PrintModBefore`
        `=PrintModAfter`
        `=PrintModFinal`
        `=PrintPasses`,
        `=NoPostopt`
        `=LooseTypes`
        `=Inline`
        Multiple options can be combined with commas.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "binary_dep_depinfo",
                    setter: dbopts::binary_dep_depinfo,
                    type_desc: desc::parse_bool,
                    desc: "include artifacts (sysroot, crate dependencies) used during compilation in dep-info \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "box_noalias",
                    setter: dbopts::box_noalias,
                    type_desc: desc::parse_bool,
                    desc: "emit noalias metadata for box (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "branch_protection",
                    setter: dbopts::branch_protection,
                    type_desc: desc::parse_branch_protection,
                    desc: "set options for branch target identification and pointer authentication on AArch64",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "build_sdylib_interface",
                    setter: dbopts::build_sdylib_interface,
                    type_desc: desc::parse_bool,
                    desc: "whether the stable interface is being built",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "cache_proc_macros",
                    setter: dbopts::cache_proc_macros,
                    type_desc: desc::parse_bool,
                    desc: "cache the results of derive proc macro invocations (potentially unsound!) (default: no",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "cf_protection",
                    setter: dbopts::cf_protection,
                    type_desc: desc::parse_cfprotection,
                    desc: "instrument control-flow architecture protection",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "check_cfg_all_expected",
                    setter: dbopts::check_cfg_all_expected,
                    type_desc: desc::parse_bool,
                    desc: "show all expected values in check-cfg diagnostics (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "checksum_hash_algorithm",
                    setter: dbopts::checksum_hash_algorithm,
                    type_desc: desc::parse_cargo_src_file_hash,
                    desc: "hash algorithm of source files used to check freshness in cargo (`blake3` or `sha256`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "codegen_backend",
                    setter: dbopts::codegen_backend,
                    type_desc: desc::parse_opt_string,
                    desc: "the backend to use",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "codegen_source_order",
                    setter: dbopts::codegen_source_order,
                    type_desc: desc::parse_bool,
                    desc: "emit mono items in the order of spans in source files (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "contract_checks",
                    setter: dbopts::contract_checks,
                    type_desc: desc::parse_opt_bool,
                    desc: "emit runtime checks for contract pre- and post-conditions (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "coverage_options",
                    setter: dbopts::coverage_options,
                    type_desc: desc::parse_coverage_options,
                    desc: "control details of coverage instrumentation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "crate_attr",
                    setter: dbopts::crate_attr,
                    type_desc: desc::parse_string_push,
                    desc: "inject the given attribute in the crate",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "cross_crate_inline_threshold",
                    setter: dbopts::cross_crate_inline_threshold,
                    type_desc: desc::parse_inlining_threshold,
                    desc: "threshold to allow cross crate inlining of functions",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "debug_info_for_profiling",
                    setter: dbopts::debug_info_for_profiling,
                    type_desc: desc::parse_bool,
                    desc: "emit discriminators and other data necessary for AutoFDO",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "debug_info_type_line_numbers",
                    setter: dbopts::debug_info_type_line_numbers,
                    type_desc: desc::parse_bool,
                    desc: "emit type and line information for additional data types (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "debuginfo_compression",
                    setter: dbopts::debuginfo_compression,
                    type_desc: desc::parse_debuginfo_compression,
                    desc: "compress debug info sections (none, zlib, zstd, default: none)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "deduplicate_diagnostics",
                    setter: dbopts::deduplicate_diagnostics,
                    type_desc: desc::parse_bool,
                    desc: "deduplicate identical diagnostics (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "default_visibility",
                    setter: dbopts::default_visibility,
                    type_desc: desc::parse_opt_symbol_visibility,
                    desc: "overrides the `default_visibility` setting of the target",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dep_info_omit_d_target",
                    setter: dbopts::dep_info_omit_d_target,
                    type_desc: desc::parse_bool,
                    desc: "in dep-info output, omit targets for tracking dependencies of the dep-info files \
        themselves (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "direct_access_external_data",
                    setter: dbopts::direct_access_external_data,
                    type_desc: desc::parse_opt_bool,
                    desc: "Direct or use GOT indirect to reference external data symbols",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dual_proc_macros",
                    setter: dbopts::dual_proc_macros,
                    type_desc: desc::parse_bool,
                    desc: "load proc macros for both target and host, but only link to the target (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_dep_graph",
                    setter: dbopts::dump_dep_graph,
                    type_desc: desc::parse_bool,
                    desc: "dump the dependency graph to $RUST_DEP_GRAPH (default: /tmp/dep_graph.gv) \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir",
                    setter: dbopts::dump_mir,
                    type_desc: desc::parse_opt_string,
                    desc: "dump MIR state to file.
        `val` is used to select which passes and functions to dump. For example:
        `all` matches all passes and functions,
        `foo` matches all passes for functions whose name contains 'foo',
        `foo & ConstProp` only the 'ConstProp' pass for function names containing 'foo',
        `foo | bar` all passes for function names containing 'foo' or 'bar'.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir_dataflow",
                    setter: dbopts::dump_mir_dataflow,
                    type_desc: desc::parse_bool,
                    desc: "in addition to `.mir` files, create graphviz `.dot` files with dataflow results \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir_dir",
                    setter: dbopts::dump_mir_dir,
                    type_desc: desc::parse_string,
                    desc: "the directory the MIR is dumped into (default: `mir_dump`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir_exclude_alloc_bytes",
                    setter: dbopts::dump_mir_exclude_alloc_bytes,
                    type_desc: desc::parse_bool,
                    desc: "exclude the raw bytes of allocations when dumping MIR (used in tests) (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir_exclude_pass_number",
                    setter: dbopts::dump_mir_exclude_pass_number,
                    type_desc: desc::parse_bool,
                    desc: "exclude the pass number when dumping MIR (used in tests) (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mir_graphviz",
                    setter: dbopts::dump_mir_graphviz,
                    type_desc: desc::parse_bool,
                    desc: "in addition to `.mir` files, create graphviz `.dot` files (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mono_stats",
                    setter: dbopts::dump_mono_stats,
                    type_desc: desc::parse_switch_with_opt_path,
                    desc: "output statistics about monomorphization collection",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dump_mono_stats_format",
                    setter: dbopts::dump_mono_stats_format,
                    type_desc: desc::parse_dump_mono_stats,
                    desc: "the format to use for -Z dump-mono-stats (`markdown` (default) or `json`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dwarf_version",
                    setter: dbopts::dwarf_version,
                    type_desc: desc::parse_opt_number,
                    desc: "version of DWARF debug information to emit (default: 2 or 4, depending on platform)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "dylib_lto",
                    setter: dbopts::dylib_lto,
                    type_desc: desc::parse_bool,
                    desc: "enables LTO for dylib crate type",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "eagerly_emit_delayed_bugs",
                    setter: dbopts::eagerly_emit_delayed_bugs,
                    type_desc: desc::parse_bool,
                    desc: "emit delayed bugs eagerly as errors instead of stashing them and emitting \
        them only if an error has not been emitted",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "ehcont_guard",
                    setter: dbopts::ehcont_guard,
                    type_desc: desc::parse_bool,
                    desc: "generate Windows EHCont Guard tables",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "embed_metadata",
                    setter: dbopts::embed_metadata,
                    type_desc: desc::parse_bool,
                    desc: "embed metadata in rlibs and dylibs (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "embed_source",
                    setter: dbopts::embed_source,
                    type_desc: desc::parse_bool,
                    desc: "embed source text in DWARF debug sections (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "emit_stack_sizes",
                    setter: dbopts::emit_stack_sizes,
                    type_desc: desc::parse_bool,
                    desc: "emit a section containing stack size metadata (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "emit_thin_lto",
                    setter: dbopts::emit_thin_lto,
                    type_desc: desc::parse_bool,
                    desc: "emit the bc module with thin LTO info (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "emscripten_wasm_eh",
                    setter: dbopts::emscripten_wasm_eh,
                    type_desc: desc::parse_bool,
                    desc: "Use WebAssembly error handling for wasm32-unknown-emscripten",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "enforce_type_length_limit",
                    setter: dbopts::enforce_type_length_limit,
                    type_desc: desc::parse_bool,
                    desc: "enforce the type length limit when monomorphizing instances in codegen",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "experimental_default_bounds",
                    setter: dbopts::experimental_default_bounds,
                    type_desc: desc::parse_bool,
                    desc: "enable default bounds for experimental group of auto traits",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "export_executable_symbols",
                    setter: dbopts::export_executable_symbols,
                    type_desc: desc::parse_bool,
                    desc: "export symbols from executables, as if they were dynamic libraries",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "external_clangrt",
                    setter: dbopts::external_clangrt,
                    type_desc: desc::parse_bool,
                    desc: "rely on user specified linker commands to find clangrt",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "extra_const_ub_checks",
                    setter: dbopts::extra_const_ub_checks,
                    type_desc: desc::parse_bool,
                    desc: "turns on more checks to detect const UB, which can be slow (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "fewer_names",
                    setter: dbopts::fewer_names,
                    type_desc: desc::parse_opt_bool,
                    desc: "reduce memory use by retaining fewer names within compilation artifacts (LLVM-IR) \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "fixed_x18",
                    setter: dbopts::fixed_x18,
                    type_desc: desc::parse_bool,
                    desc: "make the x18 register reserved on AArch64 (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::fixed_x18)),
                },
                OptionDesc {
                    name: "flatten_format_args",
                    setter: dbopts::flatten_format_args,
                    type_desc: desc::parse_bool,
                    desc: "flatten nested format_args!() and literals into a simplified format_args!() call \
        (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "fmt_debug",
                    setter: dbopts::fmt_debug,
                    type_desc: desc::parse_fmt_debug,
                    desc: "how detailed `#[derive(Debug)]` should be. `full` prints types recursively, \
        `shallow` prints only type names, `none` prints nothing and disables `{:?}`. (default: `full`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "force_unstable_if_unmarked",
                    setter: dbopts::force_unstable_if_unmarked,
                    type_desc: desc::parse_bool,
                    desc: "force all crates to be `rustc_private` unstable (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "function_return",
                    setter: dbopts::function_return,
                    type_desc: desc::parse_function_return,
                    desc: "replace returns with jumps to `__x86_return_thunk` (default: `keep`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "function_sections",
                    setter: dbopts::function_sections,
                    type_desc: desc::parse_opt_bool,
                    desc: "whether each function should go in its own section",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "future_incompat_test",
                    setter: dbopts::future_incompat_test,
                    type_desc: desc::parse_bool,
                    desc: "forces all lints to be future incompatible, used for internal testing (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "graphviz_dark_mode",
                    setter: dbopts::graphviz_dark_mode,
                    type_desc: desc::parse_bool,
                    desc: "use dark-themed colors in graphviz output (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "graphviz_font",
                    setter: dbopts::graphviz_font,
                    type_desc: desc::parse_string,
                    desc: "use the given `fontname` in graphviz output; can be overridden by setting \
        environment variable `RUSTC_GRAPHVIZ_FONT` (default: `Courier, monospace`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "has_thread_local",
                    setter: dbopts::has_thread_local,
                    type_desc: desc::parse_opt_bool,
                    desc: "explicitly enable the `cfg(target_thread_local)` directive",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "help",
                    setter: dbopts::help,
                    type_desc: desc::parse_no_value,
                    desc: "Print unstable compiler options",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "higher_ranked_assumptions",
                    setter: dbopts::higher_ranked_assumptions,
                    type_desc: desc::parse_bool,
                    desc: "allow deducing higher-ranked outlives assumptions from coroutines when proving auto traits",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "hint_mostly_unused",
                    setter: dbopts::hint_mostly_unused,
                    type_desc: desc::parse_bool,
                    desc: "hint that most of this crate will go unused, to minimize work for uncalled functions",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "human_readable_cgu_names",
                    setter: dbopts::human_readable_cgu_names,
                    type_desc: desc::parse_bool,
                    desc: "generate human-readable, predictable names for codegen units (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "identify_regions",
                    setter: dbopts::identify_regions,
                    type_desc: desc::parse_bool,
                    desc: "display unnamed regions as `'<id>`, using a non-ident unique id (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "ignore_directory_in_diagnostics_source_blocks",
                    setter: dbopts::ignore_directory_in_diagnostics_source_blocks,
                    type_desc: desc::parse_string_push,
                    desc: "do not display the source code block in diagnostics for files in the directory",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "incremental_ignore_spans",
                    setter: dbopts::incremental_ignore_spans,
                    type_desc: desc::parse_bool,
                    desc: "ignore spans during ICH computation -- used for testing (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "incremental_info",
                    setter: dbopts::incremental_info,
                    type_desc: desc::parse_bool,
                    desc: "print high-level information about incremental reuse (or the lack thereof) \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "incremental_verify_ich",
                    setter: dbopts::incremental_verify_ich,
                    type_desc: desc::parse_bool,
                    desc: "verify extended properties for incr. comp. (default: no):
        - hashes of green query instances
        - hash collisions of query keys
        - hash collisions when creating dep-nodes",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "indirect_branch_cs_prefix",
                    setter: dbopts::indirect_branch_cs_prefix,
                    type_desc: desc::parse_bool,
                    desc: "add `cs` prefix to `call` and `jmp` to indirect thunks (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::indirect_branch_cs_prefix)),
                },
                OptionDesc {
                    name: "inline_llvm",
                    setter: dbopts::inline_llvm,
                    type_desc: desc::parse_bool,
                    desc: "enable LLVM inlining (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_mir",
                    setter: dbopts::inline_mir,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable MIR inlining (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_mir_forwarder_threshold",
                    setter: dbopts::inline_mir_forwarder_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "inlining threshold when the caller is a simple forwarding function (default: 30)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_mir_hint_threshold",
                    setter: dbopts::inline_mir_hint_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "inlining threshold for functions with inline hint (default: 100)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_mir_preserve_debug",
                    setter: dbopts::inline_mir_preserve_debug,
                    type_desc: desc::parse_opt_bool,
                    desc: "when MIR inlining, whether to preserve debug info for callee variables \
        (default: preserve for debuginfo != None, otherwise remove)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "inline_mir_threshold",
                    setter: dbopts::inline_mir_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "a default MIR inlining threshold (default: 50)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "input_stats",
                    setter: dbopts::input_stats,
                    type_desc: desc::parse_bool,
                    desc: "print some statistics about AST and HIR (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "instrument_mcount",
                    setter: dbopts::instrument_mcount,
                    type_desc: desc::parse_bool,
                    desc: "insert function instrument code for mcount-based tracing (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "instrument_xray",
                    setter: dbopts::instrument_xray,
                    type_desc: desc::parse_instrument_xray,
                    desc: "insert function instrument code for XRay-based tracing (default: no)
         Optional extra settings:
         `=always`
         `=never`
         `=ignore-loops`
         `=instruction-threshold=N`
         `=skip-entry`
         `=skip-exit`
         Multiple options can be combined with commas.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "large_data_threshold",
                    setter: dbopts::large_data_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "set the threshold for objects to be stored in a \"large data\" section \
         (only effective with -Ccode-model=medium, default: 65536)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "layout_seed",
                    setter: dbopts::layout_seed,
                    type_desc: desc::parse_opt_number,
                    desc: "seed layout randomization",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_directives",
                    setter: dbopts::link_directives,
                    type_desc: desc::parse_bool,
                    desc: "honor #[link] directives in the compiled crate (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_native_libraries",
                    setter: dbopts::link_native_libraries,
                    type_desc: desc::parse_bool,
                    desc: "link native libraries in the linker invocation (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "link_only",
                    setter: dbopts::link_only,
                    type_desc: desc::parse_bool,
                    desc: "link the `.rlink` file generated by `-Z no-link` (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "lint_llvm_ir",
                    setter: dbopts::lint_llvm_ir,
                    type_desc: desc::parse_bool,
                    desc: "lint LLVM IR (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "lint_mir",
                    setter: dbopts::lint_mir,
                    type_desc: desc::parse_bool,
                    desc: "lint MIR before and after each transformation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "llvm_module_flag",
                    setter: dbopts::llvm_module_flag,
                    type_desc: desc::parse_llvm_module_flag,
                    desc: "a list of module flags to pass to LLVM (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "llvm_plugins",
                    setter: dbopts::llvm_plugins,
                    type_desc: desc::parse_list,
                    desc: "a list LLVM plugins to enable (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "llvm_time_trace",
                    setter: dbopts::llvm_time_trace,
                    type_desc: desc::parse_bool,
                    desc: "generate JSON tracing data file from LLVM data (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "location_detail",
                    setter: dbopts::location_detail,
                    type_desc: desc::parse_location_detail,
                    desc: "what location details should be tracked when using caller_location, either \
        `none`, or a comma separated list of location details, for which \
        valid options are `file`, `line`, and `column` (default: `file,line,column`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "ls",
                    setter: dbopts::ls,
                    type_desc: desc::parse_list,
                    desc: "decode and print various parts of the crate metadata for a library crate \
        (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "macro_backtrace",
                    setter: dbopts::macro_backtrace,
                    type_desc: desc::parse_bool,
                    desc: "show macro backtraces (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "macro_stats",
                    setter: dbopts::macro_stats,
                    type_desc: desc::parse_bool,
                    desc: "print some statistics about macro expansions (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "maximal_hir_to_mir_coverage",
                    setter: dbopts::maximal_hir_to_mir_coverage,
                    type_desc: desc::parse_bool,
                    desc: "save as much information as possible about the correspondence between MIR and HIR \
        as source scopes (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "merge_functions",
                    setter: dbopts::merge_functions,
                    type_desc: desc::parse_merge_functions,
                    desc: "control the operation of the MergeFunctions LLVM pass, taking \
        the same values as the target option of the same name",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "meta_stats",
                    setter: dbopts::meta_stats,
                    type_desc: desc::parse_bool,
                    desc: "gather metadata statistics (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "metrics_dir",
                    setter: dbopts::metrics_dir,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "the directory metrics emitted by rustc are dumped into (implicitly enables default set of metrics)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "min_function_alignment",
                    setter: dbopts::min_function_alignment,
                    type_desc: desc::parse_align,
                    desc: "align all functions to at least this many bytes. Must be a power of 2",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_emit_retag",
                    setter: dbopts::mir_emit_retag,
                    type_desc: desc::parse_bool,
                    desc: "emit Retagging MIR statements, interpreted e.g., by miri; implies -Zmir-opt-level=0 \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_enable_passes",
                    setter: dbopts::mir_enable_passes,
                    type_desc: desc::parse_list_with_polarity,
                    desc: "use like `-Zmir-enable-passes=+DestinationPropagation,-InstSimplify`. Forces the \
        specified passes to be enabled, overriding all other checks. In particular, this will \
        enable unsound (known-buggy and hence usually disabled) passes without further warning! \
        Passes that are not specified are enabled or disabled by other flags as usual.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_include_spans",
                    setter: dbopts::mir_include_spans,
                    type_desc: desc::parse_mir_include_spans,
                    desc: "include extra comments in mir pretty printing, like line numbers and statement indices, \
         details about types, etc. (boolean for all passes, 'nll' to enable in NLL MIR only, default: 'nll')",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_opt_level",
                    setter: dbopts::mir_opt_level,
                    type_desc: desc::parse_opt_number,
                    desc: "MIR optimization level (0-4; default: 1 in non optimized builds and 2 in optimized builds)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_preserve_ub",
                    setter: dbopts::mir_preserve_ub,
                    type_desc: desc::parse_bool,
                    desc: "keep place mention statements and reads in trivial SwitchInt terminators, which are interpreted \
        e.g., by miri; implies -Zmir-opt-level=0 (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mir_strip_debuginfo",
                    setter: dbopts::mir_strip_debuginfo,
                    type_desc: desc::parse_mir_strip_debuginfo,
                    desc: "Whether to remove some of the MIR debug info from methods.  Default: None",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "move_size_limit",
                    setter: dbopts::move_size_limit,
                    type_desc: desc::parse_opt_number,
                    desc: "the size at which the `large_assignments` lint starts to be emitted",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "mutable_noalias",
                    setter: dbopts::mutable_noalias,
                    type_desc: desc::parse_bool,
                    desc: "emit noalias metadata for mutable references (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "namespaced_crates",
                    setter: dbopts::namespaced_crates,
                    type_desc: desc::parse_bool,
                    desc: "allow crates to be namespaced by other crates (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "next_solver",
                    setter: dbopts::next_solver,
                    type_desc: desc::parse_next_solver_config,
                    desc: "enable and configure the next generation trait solver used by rustc",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "nll_facts",
                    setter: dbopts::nll_facts,
                    type_desc: desc::parse_bool,
                    desc: "dump facts from NLL analysis into side files (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "nll_facts_dir",
                    setter: dbopts::nll_facts_dir,
                    type_desc: desc::parse_string,
                    desc: "the directory the NLL facts are dumped into (default: `nll-facts`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_analysis",
                    setter: dbopts::no_analysis,
                    type_desc: desc::parse_no_value,
                    desc: "parse and expand the source, but run no analysis",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_codegen",
                    setter: dbopts::no_codegen,
                    type_desc: desc::parse_no_value,
                    desc: "run all passes except codegen; no output",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_generate_arange_section",
                    setter: dbopts::no_generate_arange_section,
                    type_desc: desc::parse_no_value,
                    desc: "omit DWARF address ranges that give faster lookups",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_implied_bounds_compat",
                    setter: dbopts::no_implied_bounds_compat,
                    type_desc: desc::parse_bool,
                    desc: "disable the compatibility version of the `implied_bounds_ty` query",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_leak_check",
                    setter: dbopts::no_leak_check,
                    type_desc: desc::parse_no_value,
                    desc: "disable the 'leak check' for subtyping; unsound, but useful for tests",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_link",
                    setter: dbopts::no_link,
                    type_desc: desc::parse_no_value,
                    desc: "compile without linking",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_parallel_backend",
                    setter: dbopts::no_parallel_backend,
                    type_desc: desc::parse_no_value,
                    desc: "run LLVM in non-parallel mode (while keeping codegen-units and ThinLTO)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_profiler_runtime",
                    setter: dbopts::no_profiler_runtime,
                    type_desc: desc::parse_no_value,
                    desc: "prevent automatic injection of the profiler_builtins crate",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_steal_thir",
                    setter: dbopts::no_steal_thir,
                    type_desc: desc::parse_bool,
                    desc: "don't steal the THIR when we're done with it; useful for rustc drivers (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_trait_vptr",
                    setter: dbopts::no_trait_vptr,
                    type_desc: desc::parse_no_value,
                    desc: "disable generation of trait vptr in vtable for upcasting",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "no_unique_section_names",
                    setter: dbopts::no_unique_section_names,
                    type_desc: desc::parse_bool,
                    desc: "do not use unique names for text and data sections when -Z function-sections is used",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "normalize_docs",
                    setter: dbopts::normalize_docs,
                    type_desc: desc::parse_bool,
                    desc: "normalize associated items in rustdoc when generating documentation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "offload",
                    setter: dbopts::offload,
                    type_desc: desc::parse_offload,
                    desc: "a list of offload flags to enable
        Mandatory setting:
        `=Enable`
        Currently the only option available",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "on_broken_pipe",
                    setter: dbopts::on_broken_pipe,
                    type_desc: desc::parse_on_broken_pipe,
                    desc: "behavior of std::io::ErrorKind::BrokenPipe (SIGPIPE)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "osx_rpath_install_name",
                    setter: dbopts::osx_rpath_install_name,
                    type_desc: desc::parse_bool,
                    desc: "pass `-install_name @rpath/...` to the macOS linker (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "packed_bundled_libs",
                    setter: dbopts::packed_bundled_libs,
                    type_desc: desc::parse_bool,
                    desc: "change rlib format to store native libraries as archives",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "panic_abort_tests",
                    setter: dbopts::panic_abort_tests,
                    type_desc: desc::parse_bool,
                    desc: "support compiling tests with panic=abort (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "panic_in_drop",
                    setter: dbopts::panic_in_drop,
                    type_desc: desc::parse_panic_strategy,
                    desc: "panic strategy for panics in drops",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "parse_crate_root_only",
                    setter: dbopts::parse_crate_root_only,
                    type_desc: desc::parse_bool,
                    desc: "parse the crate root file only; do not parse other files, compile, assemble, or link \
        (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "patchable_function_entry",
                    setter: dbopts::patchable_function_entry,
                    type_desc: desc::parse_patchable_function_entry,
                    desc: "nop padding at function entry",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "plt",
                    setter: dbopts::plt,
                    type_desc: desc::parse_opt_bool,
                    desc: "whether to use the PLT when calling into shared libraries;
        only has effect for PIC code on systems with ELF binaries
        (default: PLT is disabled if full relro is enabled on x86_64)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "polonius",
                    setter: dbopts::polonius,
                    type_desc: desc::parse_polonius,
                    desc: "enable polonius-based borrow-checker (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "pre_link_arg",
                    setter: dbopts::pre_link_arg,
                    type_desc: desc::parse_string_push,
                    desc: "a single extra argument to prepend the linker invocation (can be used several times)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "pre_link_args",
                    setter: dbopts::pre_link_args,
                    type_desc: desc::parse_list,
                    desc: "extra arguments to prepend to the linker invocation (space separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "precise_enum_drop_elaboration",
                    setter: dbopts::precise_enum_drop_elaboration,
                    type_desc: desc::parse_bool,
                    desc: "use a more precise version of drop elaboration for matches on enums (default: yes). \
        This results in better codegen, but has caused miscompilations on some tier 2 platforms. \
        See #77382 and #74551.",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "print_codegen_stats",
                    setter: dbopts::print_codegen_stats,
                    type_desc: desc::parse_bool,
                    desc: "print codegen statistics (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "print_llvm_passes",
                    setter: dbopts::print_llvm_passes,
                    type_desc: desc::parse_bool,
                    desc: "print the LLVM optimization passes being run (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "print_mono_items",
                    setter: dbopts::print_mono_items,
                    type_desc: desc::parse_bool,
                    desc: "print the result of the monomorphization collection pass (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "print_type_sizes",
                    setter: dbopts::print_type_sizes,
                    type_desc: desc::parse_bool,
                    desc: "print layout information for each type encountered (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "proc_macro_backtrace",
                    setter: dbopts::proc_macro_backtrace,
                    type_desc: desc::parse_bool,
                    desc: "show backtraces for panics during proc-macro execution (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "proc_macro_execution_strategy",
                    setter: dbopts::proc_macro_execution_strategy,
                    type_desc: desc::parse_proc_macro_execution_strategy,
                    desc: "how to run proc-macro code (default: same-thread)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "profile_closures",
                    setter: dbopts::profile_closures,
                    type_desc: desc::parse_no_value,
                    desc: "profile size of closures",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "profile_sample_use",
                    setter: dbopts::profile_sample_use,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "use the given `.prof` file for sampled profile-guided optimization (also known as AutoFDO)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "profiler_runtime",
                    setter: dbopts::profiler_runtime,
                    type_desc: desc::parse_string,
                    desc: "name of the profiler runtime crate to automatically inject (default: `profiler_builtins`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "query_dep_graph",
                    setter: dbopts::query_dep_graph,
                    type_desc: desc::parse_bool,
                    desc: "enable queries of the dependency graph for regression testing (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "randomize_layout",
                    setter: dbopts::randomize_layout,
                    type_desc: desc::parse_bool,
                    desc: "randomize the layout of types (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "reg_struct_return",
                    setter: dbopts::reg_struct_return,
                    type_desc: desc::parse_bool,
                    desc: "On x86-32 targets, it overrides the default ABI to return small structs in registers.
        It is UNSOUND to link together crates that use different values for this flag!",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::reg_struct_return)),
                },
                OptionDesc {
                    name: "regparm",
                    setter: dbopts::regparm,
                    type_desc: desc::parse_opt_number,
                    desc: "On x86-32 targets, setting this to N causes the compiler to pass N arguments \
        in registers EAX, EDX, and ECX instead of on the stack for\
        \"C\", \"cdecl\", and \"stdcall\" fn.\
        It is UNSOUND to link together crates that use different values for this flag!",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::regparm)),
                },
                OptionDesc {
                    name: "relax_elf_relocations",
                    setter: dbopts::relax_elf_relocations,
                    type_desc: desc::parse_opt_bool,
                    desc: "whether ELF relocations can be relaxed",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "remap_cwd_prefix",
                    setter: dbopts::remap_cwd_prefix,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "remap paths under the current working directory to this path prefix",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "remark_dir",
                    setter: dbopts::remark_dir,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "directory into which to write optimization remarks (if not specified, they will be \
written to standard error output)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "retpoline",
                    setter: dbopts::retpoline,
                    type_desc: desc::parse_bool,
                    desc: "enables retpoline-indirect-branches and retpoline-indirect-calls target features (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::retpoline)),
                },
                OptionDesc {
                    name: "retpoline_external_thunk",
                    setter: dbopts::retpoline_external_thunk,
                    type_desc: desc::parse_bool,
                    desc: "enables retpoline-external-thunk, retpoline-indirect-branches and retpoline-indirect-calls \
        target features (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::retpoline_external_thunk)),
                },
                OptionDesc {
                    name: "sanitizer",
                    setter: dbopts::sanitizer,
                    type_desc: desc::parse_sanitizers,
                    desc: "use a sanitizer",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::sanitizer)),
                },
                OptionDesc {
                    name: "sanitizer_cfi_canonical_jump_tables",
                    setter: dbopts::sanitizer_cfi_canonical_jump_tables,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable canonical jump tables (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "sanitizer_cfi_generalize_pointers",
                    setter: dbopts::sanitizer_cfi_generalize_pointers,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable generalizing pointer types (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "sanitizer_cfi_normalize_integers",
                    setter: dbopts::sanitizer_cfi_normalize_integers,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable normalizing integer types (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: Some(OptionsTargetModifiers::UnstableOptions(UnstableOptionsTargetModifiers::sanitizer_cfi_normalize_integers)),
                },
                OptionDesc {
                    name: "sanitizer_dataflow_abilist",
                    setter: dbopts::sanitizer_dataflow_abilist,
                    type_desc: desc::parse_comma_list,
                    desc: "additional ABI list files that control how shadow parameters are passed (comma separated)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "sanitizer_kcfi_arity",
                    setter: dbopts::sanitizer_kcfi_arity,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable KCFI arity indicator (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "sanitizer_memory_track_origins",
                    setter: dbopts::sanitizer_memory_track_origins,
                    type_desc: desc::parse_sanitizer_memory_track_origins,
                    desc: "enable origins tracking in MemorySanitizer",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "sanitizer_recover",
                    setter: dbopts::sanitizer_recover,
                    type_desc: desc::parse_sanitizers,
                    desc: "enable recovery for selected sanitizers",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "saturating_float_casts",
                    setter: dbopts::saturating_float_casts,
                    type_desc: desc::parse_opt_bool,
                    desc: "make float->int casts UB-free: numbers outside the integer type's range are clipped to \
        the max/min integer respectively, and NaN is mapped to 0 (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "self_profile",
                    setter: dbopts::self_profile,
                    type_desc: desc::parse_switch_with_opt_path,
                    desc: "run the self profiler and output the raw event data",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "self_profile_counter",
                    setter: dbopts::self_profile_counter,
                    type_desc: desc::parse_string,
                    desc: "counter used by the self profiler (default: `wall-time`), one of:
        `wall-time` (monotonic clock, i.e. `std::time::Instant`)
        `instructions:u` (retired instructions, userspace-only)
        `instructions-minus-irqs:u` (subtracting hardware interrupt counts for extra accuracy)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "self_profile_events",
                    setter: dbopts::self_profile_events,
                    type_desc: desc::parse_opt_comma_list,
                    desc: "specify the events recorded by the self profiler;
        for example: `-Z self-profile-events=default,query-keys`
        all options: none, all, default, generic-activity, query-provider, query-cache-hit
                     query-blocked, incr-cache-load, incr-result-hashing, query-keys, function-args, args, llvm, artifact-sizes",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "share_generics",
                    setter: dbopts::share_generics,
                    type_desc: desc::parse_opt_bool,
                    desc: "make the current crate share its generic instantiations",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "shell_argfiles",
                    setter: dbopts::shell_argfiles,
                    type_desc: desc::parse_bool,
                    desc: "allow argument files to be specified with POSIX \"shell-style\" argument quoting",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "simulate_remapped_rust_src_base",
                    setter: dbopts::simulate_remapped_rust_src_base,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "simulate the effect of remap-debuginfo = true at bootstrapping by remapping path \
        to rust's source base directory. only meant for testing purposes",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "small_data_threshold",
                    setter: dbopts::small_data_threshold,
                    type_desc: desc::parse_opt_number,
                    desc: "Set the threshold for objects to be stored in a \"small data\" section",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "span_debug",
                    setter: dbopts::span_debug,
                    type_desc: desc::parse_bool,
                    desc: "forward proc_macro::Span's `Debug` impl to `Span`",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "span_free_formats",
                    setter: dbopts::span_free_formats,
                    type_desc: desc::parse_bool,
                    desc: "exclude spans when debug-printing compiler state (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "split_dwarf_inlining",
                    setter: dbopts::split_dwarf_inlining,
                    type_desc: desc::parse_bool,
                    desc: "provide minimal debug info in the object/executable to facilitate online \
         symbolication/stack traces in the absence of .dwo/.dwp files when using Split DWARF",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "split_dwarf_kind",
                    setter: dbopts::split_dwarf_kind,
                    type_desc: desc::parse_split_dwarf_kind,
                    desc: "split dwarf variant (only if -Csplit-debuginfo is enabled and on relevant platform)
        (default: `split`)

        `split`: sections which do not require relocation are written into a DWARF object (`.dwo`)
                 file which is ignored by the linker
        `single`: sections which do not require relocation are written into object file but ignored
                  by the linker",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "split_dwarf_out_dir",
                    setter: dbopts::split_dwarf_out_dir,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "location for writing split DWARF objects (`.dwo`) if enabled",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "split_lto_unit",
                    setter: dbopts::split_lto_unit,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable LTO unit splitting (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "src_hash_algorithm",
                    setter: dbopts::src_hash_algorithm,
                    type_desc: desc::parse_src_file_hash,
                    desc: "hash algorithm of source files in debug info (`md5`, `sha1`, or `sha256`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "stack_protector",
                    setter: dbopts::stack_protector,
                    type_desc: desc::parse_stack_protector,
                    desc: "control stack smash protection strategy (`rustc --print stack-protector-strategies` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "staticlib_allow_rdylib_deps",
                    setter: dbopts::staticlib_allow_rdylib_deps,
                    type_desc: desc::parse_bool,
                    desc: "allow staticlibs to have rust dylib dependencies",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "staticlib_prefer_dynamic",
                    setter: dbopts::staticlib_prefer_dynamic,
                    type_desc: desc::parse_bool,
                    desc: "prefer dynamic linking to static linking for staticlibs (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "strict_init_checks",
                    setter: dbopts::strict_init_checks,
                    type_desc: desc::parse_bool,
                    desc: "control if mem::uninitialized and mem::zeroed panic on more UB",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "teach",
                    setter: dbopts::teach,
                    type_desc: desc::parse_bool,
                    desc: "show extended diagnostic help (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "temps_dir",
                    setter: dbopts::temps_dir,
                    type_desc: desc::parse_opt_string,
                    desc: "the directory the intermediate files are written to",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "terminal_urls",
                    setter: dbopts::terminal_urls,
                    type_desc: desc::parse_terminal_url,
                    desc: "use the OSC 8 hyperlink terminal specification to print hyperlinks in the compiler output",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "thinlto",
                    setter: dbopts::thinlto,
                    type_desc: desc::parse_opt_bool,
                    desc: "enable ThinLTO when possible",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "threads",
                    setter: dbopts::threads,
                    type_desc: desc::parse_threads,
                    desc: "use a thread pool with N threads",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "time_llvm_passes",
                    setter: dbopts::time_llvm_passes,
                    type_desc: desc::parse_bool,
                    desc: "measure time of each LLVM pass (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "time_passes",
                    setter: dbopts::time_passes,
                    type_desc: desc::parse_bool,
                    desc: "measure time of each rustc pass (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "time_passes_format",
                    setter: dbopts::time_passes_format,
                    type_desc: desc::parse_time_passes_format,
                    desc: "the format to use for -Z time-passes (`text` (default) or `json`)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "tiny_const_eval_limit",
                    setter: dbopts::tiny_const_eval_limit,
                    type_desc: desc::parse_bool,
                    desc: "sets a tiny, non-configurable limit for const eval; useful for compiler tests",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "tls_model",
                    setter: dbopts::tls_model,
                    type_desc: desc::parse_tls_model,
                    desc: "choose the TLS model to use (`rustc --print tls-models` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "trace_macros",
                    setter: dbopts::trace_macros,
                    type_desc: desc::parse_bool,
                    desc: "for every macro invocation, print its name and arguments (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "track_diagnostics",
                    setter: dbopts::track_diagnostics,
                    type_desc: desc::parse_bool,
                    desc: "tracks where in rustc a diagnostic was emitted",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "translate_additional_ftl",
                    setter: dbopts::translate_additional_ftl,
                    type_desc: desc::parse_opt_pathbuf,
                    desc: "additional fluent translation to preferentially use (for testing translation)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "translate_directionality_markers",
                    setter: dbopts::translate_directionality_markers,
                    type_desc: desc::parse_bool,
                    desc: "emit directionality isolation markers in translated diagnostics",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "translate_lang",
                    setter: dbopts::translate_lang,
                    type_desc: desc::parse_opt_langid,
                    desc: "language identifier for diagnostic output",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "translate_remapped_path_to_local_path",
                    setter: dbopts::translate_remapped_path_to_local_path,
                    type_desc: desc::parse_bool,
                    desc: "translate remapped paths into local paths when possible (default: yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "trap_unreachable",
                    setter: dbopts::trap_unreachable,
                    type_desc: desc::parse_opt_bool,
                    desc: "generate trap instructions for unreachable intrinsics (default: use target setting, usually yes)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "treat_err_as_bug",
                    setter: dbopts::treat_err_as_bug,
                    type_desc: desc::parse_treat_err_as_bug,
                    desc: "treat the `val`th error that occurs as bug (default if not specified: 0 - don't treat errors as bugs. \
        default if specified without a value: 1 - treat the first error as bug)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "trim_diagnostic_paths",
                    setter: dbopts::trim_diagnostic_paths,
                    type_desc: desc::parse_bool,
                    desc: "in diagnostics, use heuristics to shorten paths referring to items",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "tune_cpu",
                    setter: dbopts::tune_cpu,
                    type_desc: desc::parse_opt_string,
                    desc: "select processor to schedule for (`rustc --print target-cpus` for details)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "typing_mode_borrowck",
                    setter: dbopts::typing_mode_borrowck,
                    type_desc: desc::parse_bool,
                    desc: "enable `TypingMode::Borrowck`, changing the way opaque types are handled during MIR borrowck",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "ub_checks",
                    setter: dbopts::ub_checks,
                    type_desc: desc::parse_opt_bool,
                    desc: "emit runtime checks for Undefined Behavior (default: -Cdebug-assertions)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "ui_testing",
                    setter: dbopts::ui_testing,
                    type_desc: desc::parse_bool,
                    desc: "emit compiler diagnostics in a form suitable for UI testing (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "uninit_const_chunk_threshold",
                    setter: dbopts::uninit_const_chunk_threshold,
                    type_desc: desc::parse_number,
                    desc: "allow generating const initializers with mixed init/uninit chunks, \
        and set the maximum number of chunks for which this is allowed (default: 16)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "unleash_the_miri_inside_of_you",
                    setter: dbopts::unleash_the_miri_inside_of_you,
                    type_desc: desc::parse_bool,
                    desc: "take the brakes off const evaluation. NOTE: this is unsound (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "unpretty",
                    setter: dbopts::unpretty,
                    type_desc: desc::parse_unpretty,
                    desc: "present the input source, unstable (and less-pretty) variants;
        `normal`, `identified`,
        `expanded`, `expanded,identified`,
        `expanded,hygiene` (with internal representations),
        `ast-tree` (raw AST before expansion),
        `ast-tree,expanded` (raw AST after expansion),
        `hir` (the HIR), `hir,identified`,
        `hir,typed` (HIR with types for each node),
        `hir-tree` (dump the raw HIR),
        `thir-tree`, `thir-flat`,
        `mir` (the MIR), or `mir-cfg` (graphviz formatted MIR)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "unsound_mir_opts",
                    setter: dbopts::unsound_mir_opts,
                    type_desc: desc::parse_bool,
                    desc: "enable unsound and buggy MIR optimizations (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "unstable_options",
                    setter: dbopts::unstable_options,
                    type_desc: desc::parse_no_value,
                    desc: "adds unstable command line options to rustc interface (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "use_ctors_section",
                    setter: dbopts::use_ctors_section,
                    type_desc: desc::parse_opt_bool,
                    desc: "use legacy .ctors section for initializers rather than .init_array",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "use_sync_unwind",
                    setter: dbopts::use_sync_unwind,
                    type_desc: desc::parse_opt_bool,
                    desc: "Generate sync unwind tables instead of async unwind tables (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "validate_mir",
                    setter: dbopts::validate_mir,
                    type_desc: desc::parse_bool,
                    desc: "validate MIR after each transformation",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "verbose_asm",
                    setter: dbopts::verbose_asm,
                    type_desc: desc::parse_bool,
                    desc: "add descriptive comments from LLVM to the assembly (may change behavior) (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "verbose_internals",
                    setter: dbopts::verbose_internals,
                    type_desc: desc::parse_bool,
                    desc: "in general, enable more debug printouts (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "verify_llvm_ir",
                    setter: dbopts::verify_llvm_ir,
                    type_desc: desc::parse_bool,
                    desc: "verify LLVM IR (default: no)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "virtual_function_elimination",
                    setter: dbopts::virtual_function_elimination,
                    type_desc: desc::parse_bool,
                    desc: "enables dead virtual function elimination optimization. \
        Requires `-Clto[=[fat,yes]]`",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "wasi_exec_model",
                    setter: dbopts::wasi_exec_model,
                    type_desc: desc::parse_wasi_exec_model,
                    desc: "whether to build a wasi command or reactor",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "wasm_c_abi",
                    setter: dbopts::wasm_c_abi,
                    type_desc: desc::parse_wasm_c_abi,
                    desc: "use spec-compliant C ABI for `wasm32-unknown-unknown` (deprecated, always enabled)",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                },
                OptionDesc {
                    name: "write_long_types_to_disk",
                    setter: dbopts::write_long_types_to_disk,
                    type_desc: desc::parse_bool,
                    desc: "whether long type names should be written to files instead of being printed in errors",
                    is_deprecated_and_do_nothing: false,
                    tmod: None,
                }];
mod dbopts {
    pub(super) fn allow_features(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_comma_list(&mut cg.allow_features, v)
    }
    pub(super) fn always_encode_mir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.always_encode_mir, v)
    }
    pub(super) fn annotate_moves(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_annotate_moves(&mut cg.annotate_moves, v)
    }
    pub(super) fn assert_incr_state(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_string(&mut cg.assert_incr_state, v)
    }
    pub(super) fn assume_incomplete_release(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.assume_incomplete_release, v)
    }
    pub(super) fn autodiff(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_autodiff(&mut cg.autodiff, v)
    }
    pub(super) fn binary_dep_depinfo(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.binary_dep_depinfo, v)
    }
    pub(super) fn box_noalias(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.box_noalias, v)
    }
    pub(super) fn branch_protection(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_branch_protection(&mut cg.branch_protection, v)
    }
    pub(super) fn build_sdylib_interface(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.build_sdylib_interface, v)
    }
    pub(super) fn cache_proc_macros(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.cache_proc_macros, v)
    }
    pub(super) fn cf_protection(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_cfprotection(&mut cg.cf_protection, v)
    }
    pub(super) fn check_cfg_all_expected(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.check_cfg_all_expected, v)
    }
    pub(super) fn checksum_hash_algorithm(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_cargo_src_file_hash(&mut cg.checksum_hash_algorithm,
            v)
    }
    pub(super) fn codegen_backend(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_string(&mut cg.codegen_backend, v)
    }
    pub(super) fn codegen_source_order(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.codegen_source_order, v)
    }
    pub(super) fn contract_checks(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.contract_checks, v)
    }
    pub(super) fn coverage_options(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_coverage_options(&mut cg.coverage_options, v)
    }
    pub(super) fn crate_attr(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_string_push(&mut cg.crate_attr, v)
    }
    pub(super) fn cross_crate_inline_threshold(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_inlining_threshold(&mut cg.cross_crate_inline_threshold,
            v)
    }
    pub(super) fn debug_info_for_profiling(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.debug_info_for_profiling, v)
    }
    pub(super) fn debug_info_type_line_numbers(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.debug_info_type_line_numbers, v)
    }
    pub(super) fn debuginfo_compression(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_debuginfo_compression(&mut cg.debuginfo_compression,
            v)
    }
    pub(super) fn deduplicate_diagnostics(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.deduplicate_diagnostics, v)
    }
    pub(super) fn default_visibility(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_symbol_visibility(&mut cg.default_visibility,
            v)
    }
    pub(super) fn dep_info_omit_d_target(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dep_info_omit_d_target, v)
    }
    pub(super) fn direct_access_external_data(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.direct_access_external_data, v)
    }
    pub(super) fn dual_proc_macros(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dual_proc_macros, v)
    }
    pub(super) fn dump_dep_graph(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dump_dep_graph, v)
    }
    pub(super) fn dump_mir(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_string(&mut cg.dump_mir, v)
    }
    pub(super) fn dump_mir_dataflow(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dump_mir_dataflow, v)
    }
    pub(super) fn dump_mir_dir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.dump_mir_dir, v)
    }
    pub(super) fn dump_mir_exclude_alloc_bytes(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dump_mir_exclude_alloc_bytes, v)
    }
    pub(super) fn dump_mir_exclude_pass_number(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dump_mir_exclude_pass_number, v)
    }
    pub(super) fn dump_mir_graphviz(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.dump_mir_graphviz, v)
    }
    pub(super) fn dump_mono_stats(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_switch_with_opt_path(&mut cg.dump_mono_stats, v)
    }
    pub(super) fn dump_mono_stats_format(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_dump_mono_stats(&mut cg.dump_mono_stats_format, v)
    }
    pub(super) fn dwarf_version(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.dwarf_version, v)
    }
    pub(super) fn dylib_lto(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.dylib_lto, v)
    }
    pub(super) fn eagerly_emit_delayed_bugs(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.eagerly_emit_delayed_bugs, v)
    }
    pub(super) fn ehcont_guard(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.ehcont_guard, v)
    }
    pub(super) fn embed_metadata(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.embed_metadata, v)
    }
    pub(super) fn embed_source(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.embed_source, v)
    }
    pub(super) fn emit_stack_sizes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.emit_stack_sizes, v)
    }
    pub(super) fn emit_thin_lto(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.emit_thin_lto, v)
    }
    pub(super) fn emscripten_wasm_eh(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.emscripten_wasm_eh, v)
    }
    pub(super) fn enforce_type_length_limit(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.enforce_type_length_limit, v)
    }
    pub(super) fn experimental_default_bounds(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.experimental_default_bounds, v)
    }
    pub(super) fn export_executable_symbols(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.export_executable_symbols, v)
    }
    pub(super) fn external_clangrt(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.external_clangrt, v)
    }
    pub(super) fn extra_const_ub_checks(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.extra_const_ub_checks, v)
    }
    pub(super) fn fewer_names(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.fewer_names, v)
    }
    pub(super) fn fixed_x18(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.fixed_x18, v)
    }
    pub(super) fn flatten_format_args(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.flatten_format_args, v)
    }
    pub(super) fn fmt_debug(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_fmt_debug(&mut cg.fmt_debug, v)
    }
    pub(super) fn force_unstable_if_unmarked(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.force_unstable_if_unmarked, v)
    }
    pub(super) fn function_return(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_function_return(&mut cg.function_return, v)
    }
    pub(super) fn function_sections(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.function_sections, v)
    }
    pub(super) fn future_incompat_test(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.future_incompat_test, v)
    }
    pub(super) fn graphviz_dark_mode(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.graphviz_dark_mode, v)
    }
    pub(super) fn graphviz_font(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.graphviz_font, v)
    }
    pub(super) fn has_thread_local(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.has_thread_local, v)
    }
    pub(super) fn help(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_no_value(&mut cg.help, v)
    }
    pub(super) fn higher_ranked_assumptions(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.higher_ranked_assumptions, v)
    }
    pub(super) fn hint_mostly_unused(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.hint_mostly_unused, v)
    }
    pub(super) fn human_readable_cgu_names(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.human_readable_cgu_names, v)
    }
    pub(super) fn identify_regions(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.identify_regions, v)
    }
    pub(super) fn ignore_directory_in_diagnostics_source_blocks(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_string_push(&mut cg.ignore_directory_in_diagnostics_source_blocks,
            v)
    }
    pub(super) fn incremental_ignore_spans(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.incremental_ignore_spans, v)
    }
    pub(super) fn incremental_info(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.incremental_info, v)
    }
    pub(super) fn incremental_verify_ich(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.incremental_verify_ich, v)
    }
    pub(super) fn indirect_branch_cs_prefix(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.indirect_branch_cs_prefix, v)
    }
    pub(super) fn inline_llvm(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.inline_llvm, v)
    }
    pub(super) fn inline_mir(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_bool(&mut cg.inline_mir, v)
    }
    pub(super) fn inline_mir_forwarder_threshold(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.inline_mir_forwarder_threshold,
            v)
    }
    pub(super) fn inline_mir_hint_threshold(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.inline_mir_hint_threshold, v)
    }
    pub(super) fn inline_mir_preserve_debug(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.inline_mir_preserve_debug, v)
    }
    pub(super) fn inline_mir_threshold(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.inline_mir_threshold, v)
    }
    pub(super) fn input_stats(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.input_stats, v)
    }
    pub(super) fn instrument_mcount(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.instrument_mcount, v)
    }
    pub(super) fn instrument_xray(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_instrument_xray(&mut cg.instrument_xray, v)
    }
    pub(super) fn large_data_threshold(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.large_data_threshold, v)
    }
    pub(super) fn layout_seed(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.layout_seed, v)
    }
    pub(super) fn link_directives(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.link_directives, v)
    }
    pub(super) fn link_native_libraries(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.link_native_libraries, v)
    }
    pub(super) fn link_only(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.link_only, v)
    }
    pub(super) fn lint_llvm_ir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.lint_llvm_ir, v)
    }
    pub(super) fn lint_mir(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.lint_mir, v)
    }
    pub(super) fn llvm_module_flag(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_llvm_module_flag(&mut cg.llvm_module_flag, v)
    }
    pub(super) fn llvm_plugins(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_list(&mut cg.llvm_plugins, v)
    }
    pub(super) fn llvm_time_trace(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.llvm_time_trace, v)
    }
    pub(super) fn location_detail(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_location_detail(&mut cg.location_detail, v)
    }
    pub(super) fn ls(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_list(&mut cg.ls, v)
    }
    pub(super) fn macro_backtrace(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.macro_backtrace, v)
    }
    pub(super) fn macro_stats(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.macro_stats, v)
    }
    pub(super) fn maximal_hir_to_mir_coverage(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.maximal_hir_to_mir_coverage, v)
    }
    pub(super) fn merge_functions(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_merge_functions(&mut cg.merge_functions, v)
    }
    pub(super) fn meta_stats(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.meta_stats, v)
    }
    pub(super) fn metrics_dir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.metrics_dir, v)
    }
    pub(super) fn min_function_alignment(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_align(&mut cg.min_function_alignment, v)
    }
    pub(super) fn mir_emit_retag(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.mir_emit_retag, v)
    }
    pub(super) fn mir_enable_passes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_list_with_polarity(&mut cg.mir_enable_passes, v)
    }
    pub(super) fn mir_include_spans(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_mir_include_spans(&mut cg.mir_include_spans, v)
    }
    pub(super) fn mir_opt_level(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.mir_opt_level, v)
    }
    pub(super) fn mir_preserve_ub(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.mir_preserve_ub, v)
    }
    pub(super) fn mir_strip_debuginfo(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_mir_strip_debuginfo(&mut cg.mir_strip_debuginfo,
            v)
    }
    pub(super) fn move_size_limit(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.move_size_limit, v)
    }
    pub(super) fn mutable_noalias(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.mutable_noalias, v)
    }
    pub(super) fn namespaced_crates(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.namespaced_crates, v)
    }
    pub(super) fn next_solver(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_next_solver_config(&mut cg.next_solver, v)
    }
    pub(super) fn nll_facts(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.nll_facts, v)
    }
    pub(super) fn nll_facts_dir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.nll_facts_dir, v)
    }
    pub(super) fn no_analysis(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_analysis, v)
    }
    pub(super) fn no_codegen(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_no_value(&mut cg.no_codegen, v)
    }
    pub(super) fn no_generate_arange_section(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_generate_arange_section, v)
    }
    pub(super) fn no_implied_bounds_compat(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.no_implied_bounds_compat, v)
    }
    pub(super) fn no_leak_check(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_leak_check, v)
    }
    pub(super) fn no_link(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_no_value(&mut cg.no_link, v)
    }
    pub(super) fn no_parallel_backend(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_parallel_backend, v)
    }
    pub(super) fn no_profiler_runtime(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_profiler_runtime, v)
    }
    pub(super) fn no_steal_thir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.no_steal_thir, v)
    }
    pub(super) fn no_trait_vptr(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.no_trait_vptr, v)
    }
    pub(super) fn no_unique_section_names(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.no_unique_section_names, v)
    }
    pub(super) fn normalize_docs(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.normalize_docs, v)
    }
    pub(super) fn offload(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_offload(&mut cg.offload, v)
    }
    pub(super) fn on_broken_pipe(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_on_broken_pipe(&mut cg.on_broken_pipe, v)
    }
    pub(super) fn osx_rpath_install_name(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.osx_rpath_install_name, v)
    }
    pub(super) fn packed_bundled_libs(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.packed_bundled_libs, v)
    }
    pub(super) fn panic_abort_tests(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.panic_abort_tests, v)
    }
    pub(super) fn panic_in_drop(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_panic_strategy(&mut cg.panic_in_drop, v)
    }
    pub(super) fn parse_crate_root_only(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.parse_crate_root_only, v)
    }
    pub(super) fn patchable_function_entry(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_patchable_function_entry(&mut cg.patchable_function_entry,
            v)
    }
    pub(super) fn plt(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_bool(&mut cg.plt, v)
    }
    pub(super) fn polonius(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_polonius(&mut cg.polonius, v)
    }
    pub(super) fn pre_link_arg(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string_push(&mut cg.pre_link_args, v)
    }
    pub(super) fn pre_link_args(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_list(&mut cg.pre_link_args, v)
    }
    pub(super) fn precise_enum_drop_elaboration(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.precise_enum_drop_elaboration, v)
    }
    pub(super) fn print_codegen_stats(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.print_codegen_stats, v)
    }
    pub(super) fn print_llvm_passes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.print_llvm_passes, v)
    }
    pub(super) fn print_mono_items(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.print_mono_items, v)
    }
    pub(super) fn print_type_sizes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.print_type_sizes, v)
    }
    pub(super) fn proc_macro_backtrace(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.proc_macro_backtrace, v)
    }
    pub(super) fn proc_macro_execution_strategy(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_proc_macro_execution_strategy(&mut cg.proc_macro_execution_strategy,
            v)
    }
    pub(super) fn profile_closures(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.profile_closures, v)
    }
    pub(super) fn profile_sample_use(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.profile_sample_use, v)
    }
    pub(super) fn profiler_runtime(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.profiler_runtime, v)
    }
    pub(super) fn query_dep_graph(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.query_dep_graph, v)
    }
    pub(super) fn randomize_layout(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.randomize_layout, v)
    }
    pub(super) fn reg_struct_return(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.reg_struct_return, v)
    }
    pub(super) fn regparm(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_number(&mut cg.regparm, v)
    }
    pub(super) fn relax_elf_relocations(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.relax_elf_relocations, v)
    }
    pub(super) fn remap_cwd_prefix(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.remap_cwd_prefix, v)
    }
    pub(super) fn remark_dir(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.remark_dir, v)
    }
    pub(super) fn retpoline(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.retpoline, v)
    }
    pub(super) fn retpoline_external_thunk(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.retpoline_external_thunk, v)
    }
    pub(super) fn sanitizer(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_sanitizers(&mut cg.sanitizer, v)
    }
    pub(super) fn sanitizer_cfi_canonical_jump_tables(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.sanitizer_cfi_canonical_jump_tables,
            v)
    }
    pub(super) fn sanitizer_cfi_generalize_pointers(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.sanitizer_cfi_generalize_pointers,
            v)
    }
    pub(super) fn sanitizer_cfi_normalize_integers(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.sanitizer_cfi_normalize_integers,
            v)
    }
    pub(super) fn sanitizer_dataflow_abilist(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_comma_list(&mut cg.sanitizer_dataflow_abilist, v)
    }
    pub(super) fn sanitizer_kcfi_arity(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.sanitizer_kcfi_arity, v)
    }
    pub(super) fn sanitizer_memory_track_origins(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_sanitizer_memory_track_origins(&mut cg.sanitizer_memory_track_origins,
            v)
    }
    pub(super) fn sanitizer_recover(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_sanitizers(&mut cg.sanitizer_recover, v)
    }
    pub(super) fn saturating_float_casts(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.saturating_float_casts, v)
    }
    pub(super) fn self_profile(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_switch_with_opt_path(&mut cg.self_profile, v)
    }
    pub(super) fn self_profile_counter(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_string(&mut cg.self_profile_counter, v)
    }
    pub(super) fn self_profile_events(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_comma_list(&mut cg.self_profile_events, v)
    }
    pub(super) fn share_generics(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.share_generics, v)
    }
    pub(super) fn shell_argfiles(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.shell_argfiles, v)
    }
    pub(super) fn simulate_remapped_rust_src_base(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.simulate_remapped_rust_src_base,
            v)
    }
    pub(super) fn small_data_threshold(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_number(&mut cg.small_data_threshold, v)
    }
    pub(super) fn span_debug(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.span_debug, v)
    }
    pub(super) fn span_free_formats(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.span_free_formats, v)
    }
    pub(super) fn split_dwarf_inlining(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.split_dwarf_inlining, v)
    }
    pub(super) fn split_dwarf_kind(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_split_dwarf_kind(&mut cg.split_dwarf_kind, v)
    }
    pub(super) fn split_dwarf_out_dir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.split_dwarf_out_dir, v)
    }
    pub(super) fn split_lto_unit(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.split_lto_unit, v)
    }
    pub(super) fn src_hash_algorithm(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_src_file_hash(&mut cg.src_hash_algorithm, v)
    }
    pub(super) fn stack_protector(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_stack_protector(&mut cg.stack_protector, v)
    }
    pub(super) fn staticlib_allow_rdylib_deps(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.staticlib_allow_rdylib_deps, v)
    }
    pub(super) fn staticlib_prefer_dynamic(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.staticlib_prefer_dynamic, v)
    }
    pub(super) fn strict_init_checks(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.strict_init_checks, v)
    }
    pub(super) fn teach(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.teach, v)
    }
    pub(super) fn temps_dir(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_string(&mut cg.temps_dir, v)
    }
    pub(super) fn terminal_urls(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_terminal_url(&mut cg.terminal_urls, v)
    }
    pub(super) fn thinlto(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_bool(&mut cg.thinlto, v)
    }
    pub(super) fn threads(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_threads(&mut cg.threads, v)
    }
    pub(super) fn time_llvm_passes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.time_llvm_passes, v)
    }
    pub(super) fn time_passes(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.time_passes, v)
    }
    pub(super) fn time_passes_format(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_time_passes_format(&mut cg.time_passes_format, v)
    }
    pub(super) fn tiny_const_eval_limit(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.tiny_const_eval_limit, v)
    }
    pub(super) fn tls_model(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_tls_model(&mut cg.tls_model, v)
    }
    pub(super) fn trace_macros(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.trace_macros, v)
    }
    pub(super) fn track_diagnostics(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.track_diagnostics, v)
    }
    pub(super) fn translate_additional_ftl(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_pathbuf(&mut cg.translate_additional_ftl, v)
    }
    pub(super) fn translate_directionality_markers(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.translate_directionality_markers, v)
    }
    pub(super) fn translate_lang(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_langid(&mut cg.translate_lang, v)
    }
    pub(super) fn translate_remapped_path_to_local_path(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.translate_remapped_path_to_local_path,
            v)
    }
    pub(super) fn trap_unreachable(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.trap_unreachable, v)
    }
    pub(super) fn treat_err_as_bug(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_treat_err_as_bug(&mut cg.treat_err_as_bug, v)
    }
    pub(super) fn trim_diagnostic_paths(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.trim_diagnostic_paths, v)
    }
    pub(super) fn tune_cpu(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_string(&mut cg.tune_cpu, v)
    }
    pub(super) fn typing_mode_borrowck(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.typing_mode_borrowck, v)
    }
    pub(super) fn ub_checks(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_opt_bool(&mut cg.ub_checks, v)
    }
    pub(super) fn ui_testing(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_bool(&mut cg.ui_testing, v)
    }
    pub(super) fn uninit_const_chunk_threshold(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_number(&mut cg.uninit_const_chunk_threshold, v)
    }
    pub(super) fn unleash_the_miri_inside_of_you(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.unleash_the_miri_inside_of_you, v)
    }
    pub(super) fn unpretty(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_unpretty(&mut cg.unpretty, v)
    }
    pub(super) fn unsound_mir_opts(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.unsound_mir_opts, v)
    }
    pub(super) fn unstable_options(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_no_value(&mut cg.unstable_options, v)
    }
    pub(super) fn use_ctors_section(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.use_ctors_section, v)
    }
    pub(super) fn use_sync_unwind(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_opt_bool(&mut cg.use_sync_unwind, v)
    }
    pub(super) fn validate_mir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.validate_mir, v)
    }
    pub(super) fn verbose_asm(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.verbose_asm, v)
    }
    pub(super) fn verbose_internals(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.verbose_internals, v)
    }
    pub(super) fn verify_llvm_ir(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.verify_llvm_ir, v)
    }
    pub(super) fn virtual_function_elimination(cg:
            &mut super::UnstableOptions, v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.virtual_function_elimination, v)
    }
    pub(super) fn wasi_exec_model(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_wasi_exec_model(&mut cg.wasi_exec_model, v)
    }
    pub(super) fn wasm_c_abi(cg: &mut super::UnstableOptions, v: Option<&str>)
        -> bool {
        super::parse::parse_wasm_c_abi(&mut cg.wasm_c_abi, v)
    }
    pub(super) fn write_long_types_to_disk(cg: &mut super::UnstableOptions,
        v: Option<&str>) -> bool {
        super::parse::parse_bool(&mut cg.write_long_types_to_disk, v)
    }
}options! {
2213    UnstableOptions, UnstableOptionsTargetModifiers, Z_OPTIONS, dbopts, "Z", "unstable",
2214
2215    // If you add a new option, please update:
2216    // - compiler/rustc_interface/src/tests.rs
2217    // - src/doc/unstable-book/src/compiler-flags
2218
2219    // tidy-alphabetical-start
2220    allow_features: Option<Vec<String>> = (None, parse_opt_comma_list, [TRACKED],
2221        "only allow the listed language features to be enabled in code (comma separated)"),
2222    always_encode_mir: bool = (false, parse_bool, [TRACKED],
2223        "encode MIR of all functions into the crate metadata (default: no)"),
2224    annotate_moves: AnnotateMoves = (AnnotateMoves::Disabled, parse_annotate_moves, [TRACKED],
2225        "emit debug info for compiler-generated move and copy operations \
2226        to make them visible in profilers. Can be a boolean or a size limit in bytes (default: disabled)"),
2227    assert_incr_state: Option<String> = (None, parse_opt_string, [UNTRACKED],
2228        "assert that the incremental cache is in given state: \
2229         either `loaded` or `not-loaded`."),
2230    assume_incomplete_release: bool = (false, parse_bool, [TRACKED],
2231        "make cfg(version) treat the current version as incomplete (default: no)"),
2232    autodiff: Vec<crate::config::AutoDiff> = (Vec::new(), parse_autodiff, [TRACKED],
2233        "a list of autodiff flags to enable
2234        Mandatory setting:
2235        `=Enable`
2236        Optional extra settings:
2237        `=PrintTA`
2238        `=PrintAA`
2239        `=PrintPerf`
2240        `=PrintSteps`
2241        `=PrintModBefore`
2242        `=PrintModAfter`
2243        `=PrintModFinal`
2244        `=PrintPasses`,
2245        `=NoPostopt`
2246        `=LooseTypes`
2247        `=Inline`
2248        Multiple options can be combined with commas."),
2249    #[rustc_lint_opt_deny_field_access("use `Session::binary_dep_depinfo` instead of this field")]
2250    binary_dep_depinfo: bool = (false, parse_bool, [TRACKED],
2251        "include artifacts (sysroot, crate dependencies) used during compilation in dep-info \
2252        (default: no)"),
2253    box_noalias: bool = (true, parse_bool, [TRACKED],
2254        "emit noalias metadata for box (default: yes)"),
2255    branch_protection: Option<BranchProtection> = (None, parse_branch_protection, [TRACKED],
2256        "set options for branch target identification and pointer authentication on AArch64"),
2257    build_sdylib_interface: bool = (false, parse_bool, [UNTRACKED],
2258        "whether the stable interface is being built"),
2259    cache_proc_macros: bool = (false, parse_bool, [TRACKED],
2260        "cache the results of derive proc macro invocations (potentially unsound!) (default: no"),
2261    cf_protection: CFProtection = (CFProtection::None, parse_cfprotection, [TRACKED],
2262        "instrument control-flow architecture protection"),
2263    check_cfg_all_expected: bool = (false, parse_bool, [UNTRACKED],
2264        "show all expected values in check-cfg diagnostics (default: no)"),
2265    checksum_hash_algorithm: Option<SourceFileHashAlgorithm> = (None, parse_cargo_src_file_hash, [TRACKED],
2266        "hash algorithm of source files used to check freshness in cargo (`blake3` or `sha256`)"),
2267    codegen_backend: Option<String> = (None, parse_opt_string, [TRACKED],
2268        "the backend to use"),
2269    codegen_source_order: bool = (false, parse_bool, [UNTRACKED],
2270        "emit mono items in the order of spans in source files (default: no)"),
2271    contract_checks: Option<bool> = (None, parse_opt_bool, [TRACKED],
2272        "emit runtime checks for contract pre- and post-conditions (default: no)"),
2273    coverage_options: CoverageOptions = (CoverageOptions::default(), parse_coverage_options, [TRACKED],
2274        "control details of coverage instrumentation"),
2275    crate_attr: Vec<String> = (Vec::new(), parse_string_push, [TRACKED],
2276        "inject the given attribute in the crate"),
2277    cross_crate_inline_threshold: InliningThreshold = (InliningThreshold::Sometimes(100), parse_inlining_threshold, [TRACKED],
2278        "threshold to allow cross crate inlining of functions"),
2279    debug_info_for_profiling: bool = (false, parse_bool, [TRACKED],
2280        "emit discriminators and other data necessary for AutoFDO"),
2281    debug_info_type_line_numbers: bool = (false, parse_bool, [TRACKED],
2282        "emit type and line information for additional data types (default: no)"),
2283    debuginfo_compression: DebugInfoCompression = (DebugInfoCompression::None, parse_debuginfo_compression, [TRACKED],
2284        "compress debug info sections (none, zlib, zstd, default: none)"),
2285    deduplicate_diagnostics: bool = (true, parse_bool, [UNTRACKED],
2286        "deduplicate identical diagnostics (default: yes)"),
2287    default_visibility: Option<SymbolVisibility> = (None, parse_opt_symbol_visibility, [TRACKED],
2288        "overrides the `default_visibility` setting of the target"),
2289    dep_info_omit_d_target: bool = (false, parse_bool, [TRACKED],
2290        "in dep-info output, omit targets for tracking dependencies of the dep-info files \
2291        themselves (default: no)"),
2292    direct_access_external_data: Option<bool> = (None, parse_opt_bool, [TRACKED],
2293        "Direct or use GOT indirect to reference external data symbols"),
2294    dual_proc_macros: bool = (false, parse_bool, [TRACKED],
2295        "load proc macros for both target and host, but only link to the target (default: no)"),
2296    dump_dep_graph: bool = (false, parse_bool, [UNTRACKED],
2297        "dump the dependency graph to $RUST_DEP_GRAPH (default: /tmp/dep_graph.gv) \
2298        (default: no)"),
2299    dump_mir: Option<String> = (None, parse_opt_string, [UNTRACKED],
2300        "dump MIR state to file.
2301        `val` is used to select which passes and functions to dump. For example:
2302        `all` matches all passes and functions,
2303        `foo` matches all passes for functions whose name contains 'foo',
2304        `foo & ConstProp` only the 'ConstProp' pass for function names containing 'foo',
2305        `foo | bar` all passes for function names containing 'foo' or 'bar'."),
2306    dump_mir_dataflow: bool = (false, parse_bool, [UNTRACKED],
2307        "in addition to `.mir` files, create graphviz `.dot` files with dataflow results \
2308        (default: no)"),
2309    dump_mir_dir: String = ("mir_dump".to_string(), parse_string, [UNTRACKED],
2310        "the directory the MIR is dumped into (default: `mir_dump`)"),
2311    dump_mir_exclude_alloc_bytes: bool = (false, parse_bool, [UNTRACKED],
2312        "exclude the raw bytes of allocations when dumping MIR (used in tests) (default: no)"),
2313    dump_mir_exclude_pass_number: bool = (false, parse_bool, [UNTRACKED],
2314        "exclude the pass number when dumping MIR (used in tests) (default: no)"),
2315    dump_mir_graphviz: bool = (false, parse_bool, [UNTRACKED],
2316        "in addition to `.mir` files, create graphviz `.dot` files (default: no)"),
2317    dump_mono_stats: SwitchWithOptPath = (SwitchWithOptPath::Disabled,
2318        parse_switch_with_opt_path, [UNTRACKED],
2319        "output statistics about monomorphization collection"),
2320    dump_mono_stats_format: DumpMonoStatsFormat = (DumpMonoStatsFormat::Markdown, parse_dump_mono_stats, [UNTRACKED],
2321        "the format to use for -Z dump-mono-stats (`markdown` (default) or `json`)"),
2322    #[rustc_lint_opt_deny_field_access("use `Session::dwarf_version` instead of this field")]
2323    dwarf_version: Option<u32> = (None, parse_opt_number, [TRACKED],
2324        "version of DWARF debug information to emit (default: 2 or 4, depending on platform)"),
2325    dylib_lto: bool = (false, parse_bool, [UNTRACKED],
2326        "enables LTO for dylib crate type"),
2327    eagerly_emit_delayed_bugs: bool = (false, parse_bool, [UNTRACKED],
2328        "emit delayed bugs eagerly as errors instead of stashing them and emitting \
2329        them only if an error has not been emitted"),
2330    ehcont_guard: bool = (false, parse_bool, [TRACKED],
2331        "generate Windows EHCont Guard tables"),
2332    embed_metadata: bool = (true, parse_bool, [TRACKED],
2333        "embed metadata in rlibs and dylibs (default: yes)"),
2334    embed_source: bool = (false, parse_bool, [TRACKED],
2335        "embed source text in DWARF debug sections (default: no)"),
2336    emit_stack_sizes: bool = (false, parse_bool, [UNTRACKED],
2337        "emit a section containing stack size metadata (default: no)"),
2338    emit_thin_lto: bool = (true, parse_bool, [TRACKED],
2339        "emit the bc module with thin LTO info (default: yes)"),
2340    emscripten_wasm_eh: bool = (true, parse_bool, [TRACKED],
2341        "Use WebAssembly error handling for wasm32-unknown-emscripten"),
2342    enforce_type_length_limit: bool = (false, parse_bool, [TRACKED],
2343        "enforce the type length limit when monomorphizing instances in codegen"),
2344    experimental_default_bounds: bool = (false, parse_bool, [TRACKED],
2345        "enable default bounds for experimental group of auto traits"),
2346    export_executable_symbols: bool = (false, parse_bool, [TRACKED],
2347        "export symbols from executables, as if they were dynamic libraries"),
2348    external_clangrt: bool = (false, parse_bool, [UNTRACKED],
2349        "rely on user specified linker commands to find clangrt"),
2350    extra_const_ub_checks: bool = (false, parse_bool, [TRACKED],
2351        "turns on more checks to detect const UB, which can be slow (default: no)"),
2352    #[rustc_lint_opt_deny_field_access("use `Session::fewer_names` instead of this field")]
2353    fewer_names: Option<bool> = (None, parse_opt_bool, [TRACKED],
2354        "reduce memory use by retaining fewer names within compilation artifacts (LLVM-IR) \
2355        (default: no)"),
2356    fixed_x18: bool = (false, parse_bool, [TRACKED TARGET_MODIFIER],
2357        "make the x18 register reserved on AArch64 (default: no)"),
2358    flatten_format_args: bool = (true, parse_bool, [TRACKED],
2359        "flatten nested format_args!() and literals into a simplified format_args!() call \
2360        (default: yes)"),
2361    fmt_debug: FmtDebug = (FmtDebug::Full, parse_fmt_debug, [TRACKED],
2362        "how detailed `#[derive(Debug)]` should be. `full` prints types recursively, \
2363        `shallow` prints only type names, `none` prints nothing and disables `{:?}`. (default: `full`)"),
2364    force_unstable_if_unmarked: bool = (false, parse_bool, [TRACKED],
2365        "force all crates to be `rustc_private` unstable (default: no)"),
2366    function_return: FunctionReturn = (FunctionReturn::default(), parse_function_return, [TRACKED],
2367        "replace returns with jumps to `__x86_return_thunk` (default: `keep`)"),
2368    function_sections: Option<bool> = (None, parse_opt_bool, [TRACKED],
2369        "whether each function should go in its own section"),
2370    future_incompat_test: bool = (false, parse_bool, [UNTRACKED],
2371        "forces all lints to be future incompatible, used for internal testing (default: no)"),
2372    graphviz_dark_mode: bool = (false, parse_bool, [UNTRACKED],
2373        "use dark-themed colors in graphviz output (default: no)"),
2374    graphviz_font: String = ("Courier, monospace".to_string(), parse_string, [UNTRACKED],
2375        "use the given `fontname` in graphviz output; can be overridden by setting \
2376        environment variable `RUSTC_GRAPHVIZ_FONT` (default: `Courier, monospace`)"),
2377    has_thread_local: Option<bool> = (None, parse_opt_bool, [TRACKED],
2378        "explicitly enable the `cfg(target_thread_local)` directive"),
2379    help: bool = (false, parse_no_value, [UNTRACKED], "Print unstable compiler options"),
2380    higher_ranked_assumptions: bool = (false, parse_bool, [TRACKED],
2381        "allow deducing higher-ranked outlives assumptions from coroutines when proving auto traits"),
2382    hint_mostly_unused: bool = (false, parse_bool, [TRACKED],
2383        "hint that most of this crate will go unused, to minimize work for uncalled functions"),
2384    human_readable_cgu_names: bool = (false, parse_bool, [TRACKED],
2385        "generate human-readable, predictable names for codegen units (default: no)"),
2386    identify_regions: bool = (false, parse_bool, [UNTRACKED],
2387        "display unnamed regions as `'<id>`, using a non-ident unique id (default: no)"),
2388    ignore_directory_in_diagnostics_source_blocks: Vec<String> = (Vec::new(), parse_string_push, [UNTRACKED],
2389        "do not display the source code block in diagnostics for files in the directory"),
2390    incremental_ignore_spans: bool = (false, parse_bool, [TRACKED],
2391        "ignore spans during ICH computation -- used for testing (default: no)"),
2392    incremental_info: bool = (false, parse_bool, [UNTRACKED],
2393        "print high-level information about incremental reuse (or the lack thereof) \
2394        (default: no)"),
2395    incremental_verify_ich: bool = (false, parse_bool, [UNTRACKED],
2396        "verify extended properties for incr. comp. (default: no):
2397        - hashes of green query instances
2398        - hash collisions of query keys
2399        - hash collisions when creating dep-nodes"),
2400    indirect_branch_cs_prefix: bool = (false, parse_bool, [TRACKED TARGET_MODIFIER],
2401        "add `cs` prefix to `call` and `jmp` to indirect thunks (default: no)"),
2402    inline_llvm: bool = (true, parse_bool, [TRACKED],
2403        "enable LLVM inlining (default: yes)"),
2404    inline_mir: Option<bool> = (None, parse_opt_bool, [TRACKED],
2405        "enable MIR inlining (default: no)"),
2406    inline_mir_forwarder_threshold: Option<usize> = (None, parse_opt_number, [TRACKED],
2407        "inlining threshold when the caller is a simple forwarding function (default: 30)"),
2408    inline_mir_hint_threshold: Option<usize> = (None, parse_opt_number, [TRACKED],
2409        "inlining threshold for functions with inline hint (default: 100)"),
2410    inline_mir_preserve_debug: Option<bool> = (None, parse_opt_bool, [TRACKED],
2411        "when MIR inlining, whether to preserve debug info for callee variables \
2412        (default: preserve for debuginfo != None, otherwise remove)"),
2413    inline_mir_threshold: Option<usize> = (None, parse_opt_number, [TRACKED],
2414        "a default MIR inlining threshold (default: 50)"),
2415    input_stats: bool = (false, parse_bool, [UNTRACKED],
2416        "print some statistics about AST and HIR (default: no)"),
2417    instrument_mcount: bool = (false, parse_bool, [TRACKED],
2418        "insert function instrument code for mcount-based tracing (default: no)"),
2419    instrument_xray: Option<InstrumentXRay> = (None, parse_instrument_xray, [TRACKED],
2420        "insert function instrument code for XRay-based tracing (default: no)
2421         Optional extra settings:
2422         `=always`
2423         `=never`
2424         `=ignore-loops`
2425         `=instruction-threshold=N`
2426         `=skip-entry`
2427         `=skip-exit`
2428         Multiple options can be combined with commas."),
2429    large_data_threshold: Option<u64> = (None, parse_opt_number, [TRACKED],
2430        "set the threshold for objects to be stored in a \"large data\" section \
2431         (only effective with -Ccode-model=medium, default: 65536)"),
2432    layout_seed: Option<u64> = (None, parse_opt_number, [TRACKED],
2433        "seed layout randomization"),
2434    link_directives: bool = (true, parse_bool, [TRACKED],
2435        "honor #[link] directives in the compiled crate (default: yes)"),
2436    link_native_libraries: bool = (true, parse_bool, [UNTRACKED],
2437        "link native libraries in the linker invocation (default: yes)"),
2438    link_only: bool = (false, parse_bool, [TRACKED],
2439        "link the `.rlink` file generated by `-Z no-link` (default: no)"),
2440    lint_llvm_ir: bool = (false, parse_bool, [TRACKED],
2441        "lint LLVM IR (default: no)"),
2442    lint_mir: bool = (false, parse_bool, [UNTRACKED],
2443        "lint MIR before and after each transformation"),
2444    llvm_module_flag: Vec<(String, u32, String)> = (Vec::new(), parse_llvm_module_flag, [TRACKED],
2445        "a list of module flags to pass to LLVM (space separated)"),
2446    llvm_plugins: Vec<String> = (Vec::new(), parse_list, [TRACKED],
2447        "a list LLVM plugins to enable (space separated)"),
2448    llvm_time_trace: bool = (false, parse_bool, [UNTRACKED],
2449        "generate JSON tracing data file from LLVM data (default: no)"),
2450    location_detail: LocationDetail = (LocationDetail::all(), parse_location_detail, [TRACKED],
2451        "what location details should be tracked when using caller_location, either \
2452        `none`, or a comma separated list of location details, for which \
2453        valid options are `file`, `line`, and `column` (default: `file,line,column`)"),
2454    ls: Vec<String> = (Vec::new(), parse_list, [UNTRACKED],
2455        "decode and print various parts of the crate metadata for a library crate \
2456        (space separated)"),
2457    macro_backtrace: bool = (false, parse_bool, [UNTRACKED],
2458        "show macro backtraces (default: no)"),
2459    macro_stats: bool = (false, parse_bool, [UNTRACKED],
2460        "print some statistics about macro expansions (default: no)"),
2461    maximal_hir_to_mir_coverage: bool = (false, parse_bool, [TRACKED],
2462        "save as much information as possible about the correspondence between MIR and HIR \
2463        as source scopes (default: no)"),
2464    merge_functions: Option<MergeFunctions> = (None, parse_merge_functions, [TRACKED],
2465        "control the operation of the MergeFunctions LLVM pass, taking \
2466        the same values as the target option of the same name"),
2467    meta_stats: bool = (false, parse_bool, [UNTRACKED],
2468        "gather metadata statistics (default: no)"),
2469    metrics_dir: Option<PathBuf> = (None, parse_opt_pathbuf, [UNTRACKED],
2470        "the directory metrics emitted by rustc are dumped into (implicitly enables default set of metrics)"),
2471    min_function_alignment: Option<Align> = (None, parse_align, [TRACKED],
2472        "align all functions to at least this many bytes. Must be a power of 2"),
2473    mir_emit_retag: bool = (false, parse_bool, [TRACKED],
2474        "emit Retagging MIR statements, interpreted e.g., by miri; implies -Zmir-opt-level=0 \
2475        (default: no)"),
2476    mir_enable_passes: Vec<(String, bool)> = (Vec::new(), parse_list_with_polarity, [TRACKED],
2477        "use like `-Zmir-enable-passes=+DestinationPropagation,-InstSimplify`. Forces the \
2478        specified passes to be enabled, overriding all other checks. In particular, this will \
2479        enable unsound (known-buggy and hence usually disabled) passes without further warning! \
2480        Passes that are not specified are enabled or disabled by other flags as usual."),
2481    mir_include_spans: MirIncludeSpans = (MirIncludeSpans::default(), parse_mir_include_spans, [UNTRACKED],
2482        "include extra comments in mir pretty printing, like line numbers and statement indices, \
2483         details about types, etc. (boolean for all passes, 'nll' to enable in NLL MIR only, default: 'nll')"),
2484    #[rustc_lint_opt_deny_field_access("use `Session::mir_opt_level` instead of this field")]
2485    mir_opt_level: Option<usize> = (None, parse_opt_number, [TRACKED],
2486        "MIR optimization level (0-4; default: 1 in non optimized builds and 2 in optimized builds)"),
2487    mir_preserve_ub: bool = (false, parse_bool, [TRACKED],
2488        "keep place mention statements and reads in trivial SwitchInt terminators, which are interpreted \
2489        e.g., by miri; implies -Zmir-opt-level=0 (default: no)"),
2490    mir_strip_debuginfo: MirStripDebugInfo = (MirStripDebugInfo::None, parse_mir_strip_debuginfo, [TRACKED],
2491        "Whether to remove some of the MIR debug info from methods.  Default: None"),
2492    move_size_limit: Option<usize> = (None, parse_opt_number, [TRACKED],
2493        "the size at which the `large_assignments` lint starts to be emitted"),
2494    mutable_noalias: bool = (true, parse_bool, [TRACKED],
2495        "emit noalias metadata for mutable references (default: yes)"),
2496    namespaced_crates: bool = (false, parse_bool, [TRACKED],
2497        "allow crates to be namespaced by other crates (default: no)"),
2498    next_solver: NextSolverConfig = (NextSolverConfig::default(), parse_next_solver_config, [TRACKED],
2499        "enable and configure the next generation trait solver used by rustc"),
2500    nll_facts: bool = (false, parse_bool, [UNTRACKED],
2501        "dump facts from NLL analysis into side files (default: no)"),
2502    nll_facts_dir: String = ("nll-facts".to_string(), parse_string, [UNTRACKED],
2503        "the directory the NLL facts are dumped into (default: `nll-facts`)"),
2504    no_analysis: bool = (false, parse_no_value, [UNTRACKED],
2505        "parse and expand the source, but run no analysis"),
2506    no_codegen: bool = (false, parse_no_value, [TRACKED_NO_CRATE_HASH],
2507        "run all passes except codegen; no output"),
2508    no_generate_arange_section: bool = (false, parse_no_value, [TRACKED],
2509        "omit DWARF address ranges that give faster lookups"),
2510    no_implied_bounds_compat: bool = (false, parse_bool, [TRACKED],
2511        "disable the compatibility version of the `implied_bounds_ty` query"),
2512    no_leak_check: bool = (false, parse_no_value, [UNTRACKED],
2513        "disable the 'leak check' for subtyping; unsound, but useful for tests"),
2514    no_link: bool = (false, parse_no_value, [TRACKED],
2515        "compile without linking"),
2516    no_parallel_backend: bool = (false, parse_no_value, [UNTRACKED],
2517        "run LLVM in non-parallel mode (while keeping codegen-units and ThinLTO)"),
2518    no_profiler_runtime: bool = (false, parse_no_value, [TRACKED],
2519        "prevent automatic injection of the profiler_builtins crate"),
2520    no_steal_thir: bool = (false, parse_bool, [UNTRACKED],
2521        "don't steal the THIR when we're done with it; useful for rustc drivers (default: no)"),
2522    no_trait_vptr: bool = (false, parse_no_value, [TRACKED],
2523        "disable generation of trait vptr in vtable for upcasting"),
2524    no_unique_section_names: bool = (false, parse_bool, [TRACKED],
2525        "do not use unique names for text and data sections when -Z function-sections is used"),
2526    normalize_docs: bool = (false, parse_bool, [TRACKED],
2527        "normalize associated items in rustdoc when generating documentation"),
2528    offload: Vec<crate::config::Offload> = (Vec::new(), parse_offload, [TRACKED],
2529        "a list of offload flags to enable
2530        Mandatory setting:
2531        `=Enable`
2532        Currently the only option available"),
2533    on_broken_pipe: OnBrokenPipe = (OnBrokenPipe::Default, parse_on_broken_pipe, [TRACKED],
2534        "behavior of std::io::ErrorKind::BrokenPipe (SIGPIPE)"),
2535    osx_rpath_install_name: bool = (false, parse_bool, [TRACKED],
2536        "pass `-install_name @rpath/...` to the macOS linker (default: no)"),
2537    packed_bundled_libs: bool = (false, parse_bool, [TRACKED],
2538        "change rlib format to store native libraries as archives"),
2539    panic_abort_tests: bool = (false, parse_bool, [TRACKED],
2540        "support compiling tests with panic=abort (default: no)"),
2541    panic_in_drop: PanicStrategy = (PanicStrategy::Unwind, parse_panic_strategy, [TRACKED],
2542        "panic strategy for panics in drops"),
2543    parse_crate_root_only: bool = (false, parse_bool, [UNTRACKED],
2544        "parse the crate root file only; do not parse other files, compile, assemble, or link \
2545        (default: no)"),
2546    patchable_function_entry: PatchableFunctionEntry = (PatchableFunctionEntry::default(), parse_patchable_function_entry, [TRACKED],
2547        "nop padding at function entry"),
2548    plt: Option<bool> = (None, parse_opt_bool, [TRACKED],
2549        "whether to use the PLT when calling into shared libraries;
2550        only has effect for PIC code on systems with ELF binaries
2551        (default: PLT is disabled if full relro is enabled on x86_64)"),
2552    polonius: Polonius = (Polonius::default(), parse_polonius, [TRACKED],
2553        "enable polonius-based borrow-checker (default: no)"),
2554    pre_link_arg: (/* redirected to pre_link_args */) = ((), parse_string_push, [UNTRACKED],
2555        "a single extra argument to prepend the linker invocation (can be used several times)"),
2556    pre_link_args: Vec<String> = (Vec::new(), parse_list, [UNTRACKED],
2557        "extra arguments to prepend to the linker invocation (space separated)"),
2558    precise_enum_drop_elaboration: bool = (true, parse_bool, [TRACKED],
2559        "use a more precise version of drop elaboration for matches on enums (default: yes). \
2560        This results in better codegen, but has caused miscompilations on some tier 2 platforms. \
2561        See #77382 and #74551."),
2562    #[rustc_lint_opt_deny_field_access("use `Session::print_codegen_stats` instead of this field")]
2563    print_codegen_stats: bool = (false, parse_bool, [UNTRACKED],
2564        "print codegen statistics (default: no)"),
2565    print_llvm_passes: bool = (false, parse_bool, [UNTRACKED],
2566        "print the LLVM optimization passes being run (default: no)"),
2567    print_mono_items: bool = (false, parse_bool, [UNTRACKED],
2568        "print the result of the monomorphization collection pass (default: no)"),
2569    print_type_sizes: bool = (false, parse_bool, [UNTRACKED],
2570        "print layout information for each type encountered (default: no)"),
2571    proc_macro_backtrace: bool = (false, parse_bool, [UNTRACKED],
2572         "show backtraces for panics during proc-macro execution (default: no)"),
2573    proc_macro_execution_strategy: ProcMacroExecutionStrategy = (ProcMacroExecutionStrategy::SameThread,
2574        parse_proc_macro_execution_strategy, [UNTRACKED],
2575        "how to run proc-macro code (default: same-thread)"),
2576    profile_closures: bool = (false, parse_no_value, [UNTRACKED],
2577        "profile size of closures"),
2578    profile_sample_use: Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2579        "use the given `.prof` file for sampled profile-guided optimization (also known as AutoFDO)"),
2580    profiler_runtime: String = (String::from("profiler_builtins"), parse_string, [TRACKED],
2581        "name of the profiler runtime crate to automatically inject (default: `profiler_builtins`)"),
2582    query_dep_graph: bool = (false, parse_bool, [UNTRACKED],
2583        "enable queries of the dependency graph for regression testing (default: no)"),
2584    randomize_layout: bool = (false, parse_bool, [TRACKED],
2585        "randomize the layout of types (default: no)"),
2586    reg_struct_return: bool = (false, parse_bool, [TRACKED TARGET_MODIFIER],
2587        "On x86-32 targets, it overrides the default ABI to return small structs in registers.
2588        It is UNSOUND to link together crates that use different values for this flag!"),
2589    regparm: Option<u32> = (None, parse_opt_number, [TRACKED TARGET_MODIFIER],
2590        "On x86-32 targets, setting this to N causes the compiler to pass N arguments \
2591        in registers EAX, EDX, and ECX instead of on the stack for\
2592        \"C\", \"cdecl\", and \"stdcall\" fn.\
2593        It is UNSOUND to link together crates that use different values for this flag!"),
2594    relax_elf_relocations: Option<bool> = (None, parse_opt_bool, [TRACKED],
2595        "whether ELF relocations can be relaxed"),
2596    remap_cwd_prefix: Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2597        "remap paths under the current working directory to this path prefix"),
2598    remark_dir: Option<PathBuf> = (None, parse_opt_pathbuf, [UNTRACKED],
2599        "directory into which to write optimization remarks (if not specified, they will be \
2600written to standard error output)"),
2601    retpoline: bool = (false, parse_bool, [TRACKED TARGET_MODIFIER],
2602        "enables retpoline-indirect-branches and retpoline-indirect-calls target features (default: no)"),
2603    retpoline_external_thunk: bool = (false, parse_bool, [TRACKED TARGET_MODIFIER],
2604        "enables retpoline-external-thunk, retpoline-indirect-branches and retpoline-indirect-calls \
2605        target features (default: no)"),
2606    #[rustc_lint_opt_deny_field_access("use `Session::sanitizers()` instead of this field")]
2607    sanitizer: SanitizerSet = (SanitizerSet::empty(), parse_sanitizers, [TRACKED TARGET_MODIFIER],
2608        "use a sanitizer"),
2609    sanitizer_cfi_canonical_jump_tables: Option<bool> = (Some(true), parse_opt_bool, [TRACKED],
2610        "enable canonical jump tables (default: yes)"),
2611    sanitizer_cfi_generalize_pointers: Option<bool> = (None, parse_opt_bool, [TRACKED],
2612        "enable generalizing pointer types (default: no)"),
2613    sanitizer_cfi_normalize_integers: Option<bool> = (None, parse_opt_bool, [TRACKED TARGET_MODIFIER],
2614        "enable normalizing integer types (default: no)"),
2615    sanitizer_dataflow_abilist: Vec<String> = (Vec::new(), parse_comma_list, [TRACKED],
2616        "additional ABI list files that control how shadow parameters are passed (comma separated)"),
2617    sanitizer_kcfi_arity: Option<bool> = (None, parse_opt_bool, [TRACKED],
2618        "enable KCFI arity indicator (default: no)"),
2619    sanitizer_memory_track_origins: usize = (0, parse_sanitizer_memory_track_origins, [TRACKED],
2620        "enable origins tracking in MemorySanitizer"),
2621    sanitizer_recover: SanitizerSet = (SanitizerSet::empty(), parse_sanitizers, [TRACKED],
2622        "enable recovery for selected sanitizers"),
2623    saturating_float_casts: Option<bool> = (None, parse_opt_bool, [TRACKED],
2624        "make float->int casts UB-free: numbers outside the integer type's range are clipped to \
2625        the max/min integer respectively, and NaN is mapped to 0 (default: yes)"),
2626    self_profile: SwitchWithOptPath = (SwitchWithOptPath::Disabled,
2627        parse_switch_with_opt_path, [UNTRACKED],
2628        "run the self profiler and output the raw event data"),
2629    self_profile_counter: String = ("wall-time".to_string(), parse_string, [UNTRACKED],
2630        "counter used by the self profiler (default: `wall-time`), one of:
2631        `wall-time` (monotonic clock, i.e. `std::time::Instant`)
2632        `instructions:u` (retired instructions, userspace-only)
2633        `instructions-minus-irqs:u` (subtracting hardware interrupt counts for extra accuracy)"
2634    ),
2635    /// keep this in sync with the event filter names in librustc_data_structures/profiling.rs
2636    self_profile_events: Option<Vec<String>> = (None, parse_opt_comma_list, [UNTRACKED],
2637        "specify the events recorded by the self profiler;
2638        for example: `-Z self-profile-events=default,query-keys`
2639        all options: none, all, default, generic-activity, query-provider, query-cache-hit
2640                     query-blocked, incr-cache-load, incr-result-hashing, query-keys, function-args, args, llvm, artifact-sizes"),
2641    share_generics: Option<bool> = (None, parse_opt_bool, [TRACKED],
2642        "make the current crate share its generic instantiations"),
2643    shell_argfiles: bool = (false, parse_bool, [UNTRACKED],
2644        "allow argument files to be specified with POSIX \"shell-style\" argument quoting"),
2645    simulate_remapped_rust_src_base: Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2646        "simulate the effect of remap-debuginfo = true at bootstrapping by remapping path \
2647        to rust's source base directory. only meant for testing purposes"),
2648    small_data_threshold: Option<usize> = (None, parse_opt_number, [TRACKED],
2649        "Set the threshold for objects to be stored in a \"small data\" section"),
2650    span_debug: bool = (false, parse_bool, [UNTRACKED],
2651        "forward proc_macro::Span's `Debug` impl to `Span`"),
2652    /// o/w tests have closure@path
2653    span_free_formats: bool = (false, parse_bool, [UNTRACKED],
2654        "exclude spans when debug-printing compiler state (default: no)"),
2655    split_dwarf_inlining: bool = (false, parse_bool, [TRACKED],
2656        "provide minimal debug info in the object/executable to facilitate online \
2657         symbolication/stack traces in the absence of .dwo/.dwp files when using Split DWARF"),
2658    split_dwarf_kind: SplitDwarfKind = (SplitDwarfKind::Split, parse_split_dwarf_kind, [TRACKED],
2659        "split dwarf variant (only if -Csplit-debuginfo is enabled and on relevant platform)
2660        (default: `split`)
2661
2662        `split`: sections which do not require relocation are written into a DWARF object (`.dwo`)
2663                 file which is ignored by the linker
2664        `single`: sections which do not require relocation are written into object file but ignored
2665                  by the linker"),
2666    split_dwarf_out_dir : Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2667        "location for writing split DWARF objects (`.dwo`) if enabled"),
2668    split_lto_unit: Option<bool> = (None, parse_opt_bool, [TRACKED],
2669        "enable LTO unit splitting (default: no)"),
2670    src_hash_algorithm: Option<SourceFileHashAlgorithm> = (None, parse_src_file_hash, [TRACKED],
2671        "hash algorithm of source files in debug info (`md5`, `sha1`, or `sha256`)"),
2672    #[rustc_lint_opt_deny_field_access("use `Session::stack_protector` instead of this field")]
2673    stack_protector: StackProtector = (StackProtector::None, parse_stack_protector, [TRACKED],
2674        "control stack smash protection strategy (`rustc --print stack-protector-strategies` for details)"),
2675    staticlib_allow_rdylib_deps: bool = (false, parse_bool, [TRACKED],
2676        "allow staticlibs to have rust dylib dependencies"),
2677    staticlib_prefer_dynamic: bool = (false, parse_bool, [TRACKED],
2678        "prefer dynamic linking to static linking for staticlibs (default: no)"),
2679    strict_init_checks: bool = (false, parse_bool, [TRACKED],
2680        "control if mem::uninitialized and mem::zeroed panic on more UB"),
2681    #[rustc_lint_opt_deny_field_access("use `Session::teach` instead of this field")]
2682    teach: bool = (false, parse_bool, [TRACKED],
2683        "show extended diagnostic help (default: no)"),
2684    temps_dir: Option<String> = (None, parse_opt_string, [UNTRACKED],
2685        "the directory the intermediate files are written to"),
2686    terminal_urls: TerminalUrl = (TerminalUrl::No, parse_terminal_url, [UNTRACKED],
2687        "use the OSC 8 hyperlink terminal specification to print hyperlinks in the compiler output"),
2688    #[rustc_lint_opt_deny_field_access("use `Session::lto` instead of this field")]
2689    thinlto: Option<bool> = (None, parse_opt_bool, [TRACKED],
2690        "enable ThinLTO when possible"),
2691    /// We default to 1 here since we want to behave like
2692    /// a sequential compiler for now. This'll likely be adjusted
2693    /// in the future. Note that -Zthreads=0 is the way to get
2694    /// the num_cpus behavior.
2695    #[rustc_lint_opt_deny_field_access("use `Session::threads` instead of this field")]
2696    threads: usize = (1, parse_threads, [UNTRACKED],
2697        "use a thread pool with N threads"),
2698    time_llvm_passes: bool = (false, parse_bool, [UNTRACKED],
2699        "measure time of each LLVM pass (default: no)"),
2700    time_passes: bool = (false, parse_bool, [UNTRACKED],
2701        "measure time of each rustc pass (default: no)"),
2702    time_passes_format: TimePassesFormat = (TimePassesFormat::Text, parse_time_passes_format, [UNTRACKED],
2703        "the format to use for -Z time-passes (`text` (default) or `json`)"),
2704    tiny_const_eval_limit: bool = (false, parse_bool, [TRACKED],
2705        "sets a tiny, non-configurable limit for const eval; useful for compiler tests"),
2706    #[rustc_lint_opt_deny_field_access("use `Session::tls_model` instead of this field")]
2707    tls_model: Option<TlsModel> = (None, parse_tls_model, [TRACKED],
2708        "choose the TLS model to use (`rustc --print tls-models` for details)"),
2709    trace_macros: bool = (false, parse_bool, [UNTRACKED],
2710        "for every macro invocation, print its name and arguments (default: no)"),
2711    track_diagnostics: bool = (false, parse_bool, [UNTRACKED],
2712        "tracks where in rustc a diagnostic was emitted"),
2713    // Diagnostics are considered side-effects of a query (see `QuerySideEffect`) and are saved
2714    // alongside query results and changes to translation options can affect diagnostics - so
2715    // translation options should be tracked.
2716    translate_additional_ftl: Option<PathBuf> = (None, parse_opt_pathbuf, [TRACKED],
2717        "additional fluent translation to preferentially use (for testing translation)"),
2718    translate_directionality_markers: bool = (false, parse_bool, [TRACKED],
2719        "emit directionality isolation markers in translated diagnostics"),
2720    translate_lang: Option<LanguageIdentifier> = (None, parse_opt_langid, [TRACKED],
2721        "language identifier for diagnostic output"),
2722    translate_remapped_path_to_local_path: bool = (true, parse_bool, [TRACKED],
2723        "translate remapped paths into local paths when possible (default: yes)"),
2724    trap_unreachable: Option<bool> = (None, parse_opt_bool, [TRACKED],
2725        "generate trap instructions for unreachable intrinsics (default: use target setting, usually yes)"),
2726    treat_err_as_bug: Option<NonZero<usize>> = (None, parse_treat_err_as_bug, [TRACKED],
2727        "treat the `val`th error that occurs as bug (default if not specified: 0 - don't treat errors as bugs. \
2728        default if specified without a value: 1 - treat the first error as bug)"),
2729    trim_diagnostic_paths: bool = (true, parse_bool, [UNTRACKED],
2730        "in diagnostics, use heuristics to shorten paths referring to items"),
2731    tune_cpu: Option<String> = (None, parse_opt_string, [TRACKED],
2732        "select processor to schedule for (`rustc --print target-cpus` for details)"),
2733    #[rustc_lint_opt_deny_field_access("use `TyCtxt::use_typing_mode_borrowck` instead of this field")]
2734    typing_mode_borrowck: bool = (false, parse_bool, [TRACKED],
2735        "enable `TypingMode::Borrowck`, changing the way opaque types are handled during MIR borrowck"),
2736    #[rustc_lint_opt_deny_field_access("use `Session::ub_checks` instead of this field")]
2737    ub_checks: Option<bool> = (None, parse_opt_bool, [TRACKED],
2738        "emit runtime checks for Undefined Behavior (default: -Cdebug-assertions)"),
2739    ui_testing: bool = (false, parse_bool, [UNTRACKED],
2740        "emit compiler diagnostics in a form suitable for UI testing (default: no)"),
2741    uninit_const_chunk_threshold: usize = (16, parse_number, [TRACKED],
2742        "allow generating const initializers with mixed init/uninit chunks, \
2743        and set the maximum number of chunks for which this is allowed (default: 16)"),
2744    unleash_the_miri_inside_of_you: bool = (false, parse_bool, [TRACKED],
2745        "take the brakes off const evaluation. NOTE: this is unsound (default: no)"),
2746    unpretty: Option<String> = (None, parse_unpretty, [UNTRACKED],
2747        "present the input source, unstable (and less-pretty) variants;
2748        `normal`, `identified`,
2749        `expanded`, `expanded,identified`,
2750        `expanded,hygiene` (with internal representations),
2751        `ast-tree` (raw AST before expansion),
2752        `ast-tree,expanded` (raw AST after expansion),
2753        `hir` (the HIR), `hir,identified`,
2754        `hir,typed` (HIR with types for each node),
2755        `hir-tree` (dump the raw HIR),
2756        `thir-tree`, `thir-flat`,
2757        `mir` (the MIR), or `mir-cfg` (graphviz formatted MIR)"),
2758    unsound_mir_opts: bool = (false, parse_bool, [TRACKED],
2759        "enable unsound and buggy MIR optimizations (default: no)"),
2760    /// This name is kind of confusing: Most unstable options enable something themselves, while
2761    /// this just allows "normal" options to be feature-gated.
2762    ///
2763    /// The main check for `-Zunstable-options` takes place separately from the
2764    /// usual parsing of `-Z` options (see [`crate::config::nightly_options`]),
2765    /// so this boolean value is mostly used for enabling unstable _values_ of
2766    /// stable options. That separate check doesn't handle boolean values, so
2767    /// to avoid an inconsistent state we also forbid them here.
2768    #[rustc_lint_opt_deny_field_access("use `Session::unstable_options` instead of this field")]
2769    unstable_options: bool = (false, parse_no_value, [UNTRACKED],
2770        "adds unstable command line options to rustc interface (default: no)"),
2771    use_ctors_section: Option<bool> = (None, parse_opt_bool, [TRACKED],
2772        "use legacy .ctors section for initializers rather than .init_array"),
2773    use_sync_unwind: Option<bool> = (None, parse_opt_bool, [TRACKED],
2774        "Generate sync unwind tables instead of async unwind tables (default: no)"),
2775    validate_mir: bool = (false, parse_bool, [UNTRACKED],
2776        "validate MIR after each transformation"),
2777    verbose_asm: bool = (false, parse_bool, [TRACKED],
2778        "add descriptive comments from LLVM to the assembly (may change behavior) (default: no)"),
2779    #[rustc_lint_opt_deny_field_access("use `Session::verbose_internals` instead of this field")]
2780    verbose_internals: bool = (false, parse_bool, [TRACKED_NO_CRATE_HASH],
2781        "in general, enable more debug printouts (default: no)"),
2782    #[rustc_lint_opt_deny_field_access("use `Session::verify_llvm_ir` instead of this field")]
2783    verify_llvm_ir: bool = (false, parse_bool, [TRACKED],
2784        "verify LLVM IR (default: no)"),
2785    virtual_function_elimination: bool = (false, parse_bool, [TRACKED],
2786        "enables dead virtual function elimination optimization. \
2787        Requires `-Clto[=[fat,yes]]`"),
2788    wasi_exec_model: Option<WasiExecModel> = (None, parse_wasi_exec_model, [TRACKED],
2789        "whether to build a wasi command or reactor"),
2790    // This option only still exists to provide a more gradual transition path for people who need
2791    // the spec-complaint C ABI to be used.
2792    // FIXME remove this after a couple releases
2793    wasm_c_abi: () = ((), parse_wasm_c_abi, [TRACKED],
2794        "use spec-compliant C ABI for `wasm32-unknown-unknown` (deprecated, always enabled)"),
2795    write_long_types_to_disk: bool = (true, parse_bool, [UNTRACKED],
2796        "whether long type names should be written to files instead of being printed in errors"),
2797    // tidy-alphabetical-end
2798
2799    // If you add a new option, please update:
2800    // - compiler/rustc_interface/src/tests.rs
2801    // - src/doc/unstable-book/src/compiler-flags
2802}