Expand description
Shared settings module.
This module defines data structures to access the settings defined in the meta language.
Each settings group is translated to a Flags
struct either in this module or in its
ISA-specific settings
module. The struct provides individual getter methods for all of the
settings as well as computed predicate flags.
The Flags
struct is immutable once it has been created. A Builder
instance is used to
create it.
§Example
use cranelift_codegen::settings::{self, Configurable};
let mut b = settings::builder();
b.set("opt_level", "speed_and_size");
let f = settings::Flags::new(b);
assert_eq!(f.opt_level(), settings::OptLevel::SpeedAndSize);
Modules§
- Implementation details for generated code.
Structs§
- Collect settings values based on a template.
- Flags group
shared
. - Wrapper containing flags and optionally a
TargetIsa
trait object. - A reference to just the boolean predicates of a settings object.
- Represents an available builder setting.
- Represents a setting value.
Enums§
- Values for
shared.libcall_call_conv
. - Values for
shared.opt_level
. - Values for
shared.probestack_strategy
. - Values for
shared.regalloc_algorithm
. - An error produced when changing a setting.
- Represents the kind of setting.
- Values for
shared.stack_switch_model
. - Values for
shared.tls_model
.
Traits§
- A string-based configurator for settings groups.
Functions§
- Create a
settings::Builder
for the shared settings group.
Type Aliases§
- A result returned when changing a setting.