/src/wasmtime/target/debug/build/cranelift-codegen-f6aafab48a0f8ae2/out/settings.rs
Line | Count | Source |
1 | | #[derive(Clone, PartialEq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:397 |
2 | | /// Flags group `shared`. |
3 | | pub struct Flags { |
4 | | bytes: [u8; 12], // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:400 |
5 | | } |
6 | | impl Flags { |
7 | | /// Create flags shared settings group. |
8 | | #[allow(unused_variables, reason = "generated code")] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:24 |
9 | 139k | pub fn new(builder: Builder) -> Self { |
10 | 139k | let bvec = builder.state_for("shared"); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:29 |
11 | 139k | let mut shared = Self { bytes: [0; 12] }; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:30 |
12 | 139k | debug_assert_eq!(bvec.len(), 12); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:36 |
13 | 139k | shared.bytes[0..12].copy_from_slice(&bvec); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:41 |
14 | 139k | shared // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:48 |
15 | 139k | } |
16 | | } |
17 | | impl Flags { |
18 | | /// Iterates the setting values. |
19 | 155k | pub fn iter(&self) -> impl Iterator<Item = Value> + use<> { |
20 | 155k | let mut bytes = [0; 12]; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:58 |
21 | 155k | bytes.copy_from_slice(&self.bytes[0..12]); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:59 |
22 | 4.19M | DESCRIPTORS.iter().filter_map(move |d| { |
23 | 4.19M | let values = match &d.detail { |
24 | 0 | detail::Detail::Preset => return None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:62 |
25 | 933k | detail::Detail::Enum { last, enumerators } => Some(TEMPLATE.enums(*last, *enumerators)), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:63 |
26 | 3.26M | _ => None // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:64 |
27 | | } |
28 | | ; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:66 |
29 | 4.19M | Some(Value { name: d.name, detail: d.detail, values, value: bytes[d.offset as usize] }) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:67 |
30 | 4.19M | } <cranelift_codegen::settings::Flags>::iter::{closure#0}Line | Count | Source | 22 | 4.19M | DESCRIPTORS.iter().filter_map(move |d| { | 23 | 4.19M | let values = match &d.detail { | 24 | 0 | detail::Detail::Preset => return None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:62 | 25 | 933k | detail::Detail::Enum { last, enumerators } => Some(TEMPLATE.enums(*last, *enumerators)), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:63 | 26 | 3.26M | _ => None // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:64 | 27 | | } | 28 | | ; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:66 | 29 | 4.19M | Some(Value { name: d.name, detail: d.detail, values, value: bytes[d.offset as usize] }) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:67 | 30 | 4.19M | } |
Unexecuted instantiation: <cranelift_codegen::settings::Flags>::iter::{closure#0}Unexecuted instantiation: <cranelift_codegen::settings::Flags>::iter::{closure#0} |
31 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:69 |
32 | 155k | } |
33 | | } |
34 | | /// Values for `shared.regalloc_algorithm`. |
35 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
36 | | pub enum RegallocAlgorithm { |
37 | | /// `backtracking`. |
38 | | Backtracking, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
39 | | /// `single_pass`. |
40 | | SinglePass, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
41 | | } |
42 | | impl RegallocAlgorithm { |
43 | | /// Returns a slice with all possible [RegallocAlgorithm] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
44 | 0 | pub fn all() -> &'static [RegallocAlgorithm] { |
45 | 0 | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
46 | 0 | Self::Backtracking, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
47 | 0 | Self::SinglePass, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
48 | 0 | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
49 | 0 | } |
50 | | } |
51 | | impl fmt::Display for RegallocAlgorithm { |
52 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
53 | 0 | f.write_str(match *self { |
54 | 0 | Self::Backtracking => "backtracking", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
55 | 0 | Self::SinglePass => "single_pass", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
56 | | } |
57 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
58 | 0 | } |
59 | | } |
60 | | impl core::str::FromStr for RegallocAlgorithm { |
61 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
62 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
63 | 0 | match s { |
64 | 0 | "backtracking" => Ok(Self::Backtracking), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
65 | 0 | "single_pass" => Ok(Self::SinglePass), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
66 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
67 | | } |
68 | 0 | } |
69 | | } |
70 | | /// Values for `shared.opt_level`. |
71 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
72 | | pub enum OptLevel { |
73 | | /// `none`. |
74 | | None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
75 | | /// `speed`. |
76 | | Speed, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
77 | | /// `speed_and_size`. |
78 | | SpeedAndSize, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
79 | | } |
80 | | impl OptLevel { |
81 | | /// Returns a slice with all possible [OptLevel] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
82 | 19.0k | pub fn all() -> &'static [OptLevel] { |
83 | 19.0k | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
84 | 19.0k | Self::None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
85 | 19.0k | Self::Speed, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
86 | 19.0k | Self::SpeedAndSize, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
87 | 19.0k | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
88 | 19.0k | } |
89 | | } |
90 | | impl fmt::Display for OptLevel { |
91 | 19.0k | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
92 | 19.0k | f.write_str(match *self { |
93 | 5.51k | Self::None => "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
94 | 9.09k | Self::Speed => "speed", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
95 | 4.47k | Self::SpeedAndSize => "speed_and_size", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
96 | | } |
97 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
98 | 19.0k | } |
99 | | } |
100 | | impl core::str::FromStr for OptLevel { |
101 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
102 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
103 | 0 | match s { |
104 | 0 | "none" => Ok(Self::None), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
105 | 0 | "speed" => Ok(Self::Speed), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
106 | 0 | "speed_and_size" => Ok(Self::SpeedAndSize), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
107 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
108 | | } |
109 | 0 | } |
110 | | } |
111 | | /// Values for `shared.tls_model`. |
112 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
113 | | pub enum TlsModel { |
114 | | /// `none`. |
115 | | None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
116 | | /// `elf_gd`. |
117 | | ElfGd, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
118 | | /// `macho`. |
119 | | Macho, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
120 | | /// `coff`. |
121 | | Coff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
122 | | } |
123 | | impl TlsModel { |
124 | | /// Returns a slice with all possible [TlsModel] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
125 | 0 | pub fn all() -> &'static [TlsModel] { |
126 | 0 | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
127 | 0 | Self::None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
128 | 0 | Self::ElfGd, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
129 | 0 | Self::Macho, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
130 | 0 | Self::Coff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
131 | 0 | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
132 | 0 | } |
133 | | } |
134 | | impl fmt::Display for TlsModel { |
135 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
136 | 0 | f.write_str(match *self { |
137 | 0 | Self::None => "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
138 | 0 | Self::ElfGd => "elf_gd", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
139 | 0 | Self::Macho => "macho", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
140 | 0 | Self::Coff => "coff", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
141 | | } |
142 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
143 | 0 | } |
144 | | } |
145 | | impl core::str::FromStr for TlsModel { |
146 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
147 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
148 | 0 | match s { |
149 | 0 | "none" => Ok(Self::None), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
150 | 0 | "elf_gd" => Ok(Self::ElfGd), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
151 | 0 | "macho" => Ok(Self::Macho), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
152 | 0 | "coff" => Ok(Self::Coff), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
153 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
154 | | } |
155 | 0 | } |
156 | | } |
157 | | /// Values for `shared.stack_switch_model`. |
158 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
159 | | pub enum StackSwitchModel { |
160 | | /// `none`. |
161 | | None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
162 | | /// `basic`. |
163 | | Basic, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
164 | | /// `update_windows_tib`. |
165 | | UpdateWindowsTib, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
166 | | } |
167 | | impl StackSwitchModel { |
168 | | /// Returns a slice with all possible [StackSwitchModel] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
169 | 0 | pub fn all() -> &'static [StackSwitchModel] { |
170 | 0 | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
171 | 0 | Self::None, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
172 | 0 | Self::Basic, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
173 | 0 | Self::UpdateWindowsTib, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
174 | 0 | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
175 | 0 | } |
176 | | } |
177 | | impl fmt::Display for StackSwitchModel { |
178 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
179 | 0 | f.write_str(match *self { |
180 | 0 | Self::None => "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
181 | 0 | Self::Basic => "basic", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
182 | 0 | Self::UpdateWindowsTib => "update_windows_tib", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
183 | | } |
184 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
185 | 0 | } |
186 | | } |
187 | | impl core::str::FromStr for StackSwitchModel { |
188 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
189 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
190 | 0 | match s { |
191 | 0 | "none" => Ok(Self::None), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
192 | 0 | "basic" => Ok(Self::Basic), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
193 | 0 | "update_windows_tib" => Ok(Self::UpdateWindowsTib), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
194 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
195 | | } |
196 | 0 | } |
197 | | } |
198 | | /// Values for `shared.libcall_call_conv`. |
199 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
200 | | pub enum LibcallCallConv { |
201 | | /// `isa_default`. |
202 | | IsaDefault, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
203 | | /// `fast`. |
204 | | Fast, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
205 | | /// `system_v`. |
206 | | SystemV, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
207 | | /// `windows_fastcall`. |
208 | | WindowsFastcall, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
209 | | /// `apple_aarch64`. |
210 | | AppleAarch64, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
211 | | /// `probestack`. |
212 | | Probestack, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
213 | | /// `preserve_all`. |
214 | | PreserveAll, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
215 | | } |
216 | | impl LibcallCallConv { |
217 | | /// Returns a slice with all possible [LibcallCallConv] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
218 | 0 | pub fn all() -> &'static [LibcallCallConv] { |
219 | 0 | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
220 | 0 | Self::IsaDefault, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
221 | 0 | Self::Fast, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
222 | 0 | Self::SystemV, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
223 | 0 | Self::WindowsFastcall, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
224 | 0 | Self::AppleAarch64, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
225 | 0 | Self::Probestack, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
226 | 0 | Self::PreserveAll, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
227 | 0 | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
228 | 0 | } |
229 | | } |
230 | | impl fmt::Display for LibcallCallConv { |
231 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
232 | 0 | f.write_str(match *self { |
233 | 0 | Self::IsaDefault => "isa_default", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
234 | 0 | Self::Fast => "fast", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
235 | 0 | Self::SystemV => "system_v", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
236 | 0 | Self::WindowsFastcall => "windows_fastcall", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
237 | 0 | Self::AppleAarch64 => "apple_aarch64", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
238 | 0 | Self::Probestack => "probestack", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
239 | 0 | Self::PreserveAll => "preserve_all", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
240 | | } |
241 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
242 | 0 | } |
243 | | } |
244 | | impl core::str::FromStr for LibcallCallConv { |
245 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
246 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
247 | 0 | match s { |
248 | 0 | "isa_default" => Ok(Self::IsaDefault), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
249 | 0 | "fast" => Ok(Self::Fast), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
250 | 0 | "system_v" => Ok(Self::SystemV), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
251 | 0 | "windows_fastcall" => Ok(Self::WindowsFastcall), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
252 | 0 | "apple_aarch64" => Ok(Self::AppleAarch64), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
253 | 0 | "probestack" => Ok(Self::Probestack), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
254 | 0 | "preserve_all" => Ok(Self::PreserveAll), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
255 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
256 | | } |
257 | 0 | } |
258 | | } |
259 | | /// Values for `shared.probestack_strategy`. |
260 | | #[derive(Debug, Copy, Clone, PartialEq, Eq, Hash)] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:131 |
261 | | pub enum ProbestackStrategy { |
262 | | /// `outline`. |
263 | | Outline, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
264 | | /// `inline`. |
265 | | Inline, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:135 |
266 | | } |
267 | | impl ProbestackStrategy { |
268 | | /// Returns a slice with all possible [ProbestackStrategy] values. // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:76 |
269 | 0 | pub fn all() -> &'static [ProbestackStrategy] { |
270 | 0 | &[ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:82 |
271 | 0 | Self::Outline, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
272 | 0 | Self::Inline, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:85 |
273 | 0 | ] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:88 |
274 | 0 | } |
275 | | } |
276 | | impl fmt::Display for ProbestackStrategy { |
277 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
278 | 0 | f.write_str(match *self { |
279 | 0 | Self::Outline => "outline", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
280 | 0 | Self::Inline => "inline", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:100 |
281 | | } |
282 | | ) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:103 |
283 | 0 | } |
284 | | } |
285 | | impl core::str::FromStr for ProbestackStrategy { |
286 | | type Err = (); // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:109 |
287 | 0 | fn from_str(s: &str) -> Result<Self, Self::Err> { |
288 | 0 | match s { |
289 | 0 | "outline" => Ok(Self::Outline), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
290 | 0 | "inline" => Ok(Self::Inline), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:113 |
291 | 0 | _ => Err(()), // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:115 |
292 | | } |
293 | 0 | } |
294 | | } |
295 | | /// User-defined settings. |
296 | | #[allow(dead_code, reason = "generated code")] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:183 |
297 | | impl Flags { |
298 | | /// Dynamic numbered predicate getter. |
299 | 106M | fn numbered_predicate(&self, p: usize) -> bool { |
300 | 106M | self.bytes[9 + p / 8] & (1 << (p % 8)) != 0 // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:188 |
301 | 106M | } |
302 | | /// Algorithm to use in register allocator. |
303 | | /// |
304 | | /// Supported options: |
305 | | /// |
306 | | /// - `backtracking`: A backtracking allocator with range splitting; more expensive |
307 | | /// but generates better code. |
308 | | /// - `single_pass`: A single-pass algorithm that yields quick compilation but |
309 | | /// results in code with more register spills and moves. |
310 | 1.76M | pub fn regalloc_algorithm(&self) -> RegallocAlgorithm { |
311 | 1.76M | match self.bytes[0] { |
312 | | 0 => { |
313 | 1.32M | RegallocAlgorithm::Backtracking |
314 | | } |
315 | | 1 => { |
316 | 439k | RegallocAlgorithm::SinglePass |
317 | | } |
318 | | _ => { |
319 | 0 | panic!("Invalid enum value") |
320 | | } |
321 | | } |
322 | 1.76M | } |
323 | | /// Optimization level for generated code. |
324 | | /// |
325 | | /// Supported levels: |
326 | | /// |
327 | | /// - `none`: Minimise compile time by disabling most optimizations. |
328 | | /// - `speed`: Generate the fastest possible code |
329 | | /// - `speed_and_size`: like "speed", but also perform transformations aimed at reducing code size. |
330 | 1.77M | pub fn opt_level(&self) -> OptLevel { |
331 | 1.77M | match self.bytes[1] { |
332 | | 0 => { |
333 | 609k | OptLevel::None |
334 | | } |
335 | | 1 => { |
336 | 804k | OptLevel::Speed |
337 | | } |
338 | | 2 => { |
339 | 356k | OptLevel::SpeedAndSize |
340 | | } |
341 | | _ => { |
342 | 0 | panic!("Invalid enum value") |
343 | | } |
344 | | } |
345 | 1.77M | } |
346 | | /// Defines the model used to perform TLS accesses. |
347 | 0 | pub fn tls_model(&self) -> TlsModel { |
348 | 0 | match self.bytes[2] { |
349 | | 3 => { |
350 | 0 | TlsModel::Coff |
351 | | } |
352 | | 1 => { |
353 | 0 | TlsModel::ElfGd |
354 | | } |
355 | | 2 => { |
356 | 0 | TlsModel::Macho |
357 | | } |
358 | | 0 => { |
359 | 0 | TlsModel::None |
360 | | } |
361 | | _ => { |
362 | 0 | panic!("Invalid enum value") |
363 | | } |
364 | | } |
365 | 0 | } |
366 | | /// Defines the model used to performing stack switching. |
367 | | /// |
368 | | /// This determines the compilation of `stack_switch` instructions. If |
369 | | /// set to `basic`, we simply save all registers, update stack pointer |
370 | | /// and frame pointer (if needed), and jump to the target IP. |
371 | | /// If set to `update_windows_tib`, we *additionally* update information |
372 | | /// about the active stack in Windows' Thread Information Block. |
373 | 0 | pub fn stack_switch_model(&self) -> StackSwitchModel { |
374 | 0 | match self.bytes[3] { |
375 | | 1 => { |
376 | 0 | StackSwitchModel::Basic |
377 | | } |
378 | | 0 => { |
379 | 0 | StackSwitchModel::None |
380 | | } |
381 | | 2 => { |
382 | 0 | StackSwitchModel::UpdateWindowsTib |
383 | | } |
384 | | _ => { |
385 | 0 | panic!("Invalid enum value") |
386 | | } |
387 | | } |
388 | 0 | } |
389 | | /// Defines the calling convention to use for LibCalls call expansion. |
390 | | /// |
391 | | /// This may be different from the ISA default calling convention. |
392 | | /// |
393 | | /// The default value is to use the same calling convention as the ISA |
394 | | /// default calling convention. |
395 | | /// |
396 | | /// This list should be kept in sync with the list of calling |
397 | | /// conventions available in isa/call_conv.rs. |
398 | 5.14k | pub fn libcall_call_conv(&self) -> LibcallCallConv { |
399 | 5.14k | match self.bytes[4] { |
400 | | 4 => { |
401 | 0 | LibcallCallConv::AppleAarch64 |
402 | | } |
403 | | 1 => { |
404 | 0 | LibcallCallConv::Fast |
405 | | } |
406 | | 0 => { |
407 | 5.14k | LibcallCallConv::IsaDefault |
408 | | } |
409 | | 6 => { |
410 | 0 | LibcallCallConv::PreserveAll |
411 | | } |
412 | | 5 => { |
413 | 0 | LibcallCallConv::Probestack |
414 | | } |
415 | | 2 => { |
416 | 0 | LibcallCallConv::SystemV |
417 | | } |
418 | | 3 => { |
419 | 0 | LibcallCallConv::WindowsFastcall |
420 | | } |
421 | | _ => { |
422 | 0 | panic!("Invalid enum value") |
423 | | } |
424 | | } |
425 | 5.14k | } |
426 | | /// The log2 of the size of the stack guard region. |
427 | | /// |
428 | | /// Stack frames larger than this size will have stack overflow checked |
429 | | /// by calling the probestack function. |
430 | | /// |
431 | | /// The default is 12, which translates to a size of 4096. |
432 | 1.52M | pub fn probestack_size_log2(&self) -> u8 { |
433 | 1.52M | self.bytes[5] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:174 |
434 | 1.52M | } |
435 | | /// Controls what kinds of stack probes are emitted. |
436 | | /// |
437 | | /// Supported strategies: |
438 | | /// |
439 | | /// - `outline`: Always emits stack probes as calls to a probe stack function. |
440 | | /// - `inline`: Always emits inline stack probes. |
441 | 1.52M | pub fn probestack_strategy(&self) -> ProbestackStrategy { |
442 | 1.52M | match self.bytes[6] { |
443 | | 1 => { |
444 | 1.52M | ProbestackStrategy::Inline |
445 | | } |
446 | | 0 => { |
447 | 0 | ProbestackStrategy::Outline |
448 | | } |
449 | | _ => { |
450 | 0 | panic!("Invalid enum value") |
451 | | } |
452 | | } |
453 | 1.52M | } |
454 | | /// The log2 of the size to insert dummy padding between basic blocks |
455 | | /// |
456 | | /// This is a debugging option for stressing various cases during code |
457 | | /// generation without requiring large functions. This will insert |
458 | | /// 0-byte padding between basic blocks of the specified size. |
459 | | /// |
460 | | /// The amount of padding inserted two raised to the power of this value |
461 | | /// minus one. If this value is 0 then no padding is inserted. |
462 | | /// |
463 | | /// The default for this option is 0 to insert no padding as it's only |
464 | | /// intended for testing and development. |
465 | 1.76M | pub fn bb_padding_log2_minus_one(&self) -> u8 { |
466 | 1.76M | self.bytes[7] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:174 |
467 | 1.76M | } |
468 | | /// The log2 of the minimum alignment of functions |
469 | | /// The bigger of this value and the default alignment will be used as actual alignment. |
470 | 1.76M | pub fn log2_min_function_alignment(&self) -> u8 { |
471 | 1.76M | self.bytes[8] // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:174 |
472 | 1.76M | } |
473 | | /// Enable the symbolic checker for register allocation. |
474 | | /// |
475 | | /// This performs a verification that the register allocator preserves |
476 | | /// equivalent dataflow with respect to the original (pre-regalloc) |
477 | | /// program. This analysis is somewhat expensive. However, if it succeeds, |
478 | | /// it provides independent evidence (by a carefully-reviewed, from-first-principles |
479 | | /// analysis) that no regalloc bugs were triggered for the particular compilations |
480 | | /// performed. This is a valuable assurance to have as regalloc bugs can be |
481 | | /// very dangerous and difficult to debug. |
482 | 1.76M | pub fn regalloc_checker(&self) -> bool { |
483 | 1.76M | self.numbered_predicate(0) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
484 | 1.76M | } |
485 | | /// Enable verbose debug logs for regalloc2. |
486 | | /// |
487 | | /// This adds extra logging for regalloc2 output, that is quite valuable to understand |
488 | | /// decisions taken by the register allocator as well as debugging it. It is disabled by |
489 | | /// default, as it can cause many log calls which can slow down compilation by a large |
490 | | /// amount. |
491 | 1.76M | pub fn regalloc_verbose_logs(&self) -> bool { |
492 | 1.76M | self.numbered_predicate(1) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
493 | 1.76M | } |
494 | | /// Do redundant-load optimizations with alias analysis. |
495 | | /// |
496 | | /// This enables the use of a simple alias analysis to optimize away redundant loads. |
497 | | /// Only effective when `opt_level` is `speed` or `speed_and_size`. |
498 | 0 | pub fn enable_alias_analysis(&self) -> bool { |
499 | 0 | self.numbered_predicate(2) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
500 | 0 | } |
501 | | /// Run the Cranelift IR verifier at strategic times during compilation. |
502 | | /// |
503 | | /// This makes compilation slower but catches many bugs. The verifier is always enabled by |
504 | | /// default, which is useful during development. |
505 | 9.64M | pub fn enable_verifier(&self) -> bool { |
506 | 9.64M | self.numbered_predicate(3) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
507 | 9.64M | } |
508 | | /// Enable Position-Independent Code generation. |
509 | 276k | pub fn is_pic(&self) -> bool { |
510 | 276k | self.numbered_predicate(4) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
511 | 276k | } |
512 | | /// Use colocated libcalls. |
513 | | /// |
514 | | /// Generate code that assumes that libcalls can be declared "colocated", |
515 | | /// meaning they will be defined along with the current function, such that |
516 | | /// they can use more efficient addressing. |
517 | 5.14k | pub fn use_colocated_libcalls(&self) -> bool { |
518 | 5.14k | self.numbered_predicate(5) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
519 | 5.14k | } |
520 | | /// Enable NaN canonicalization. |
521 | | /// |
522 | | /// This replaces NaNs with a single canonical value, for users requiring |
523 | | /// entirely deterministic WebAssembly computation. This is not required |
524 | | /// by the WebAssembly spec, so it is not enabled by default. |
525 | 1.80M | pub fn enable_nan_canonicalization(&self) -> bool { |
526 | 1.80M | self.numbered_predicate(6) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
527 | 1.80M | } |
528 | | /// Enable the use of the pinned register. |
529 | | /// |
530 | | /// This register is excluded from register allocation, and is completely under the control of |
531 | | /// the end-user. It is possible to read it via the get_pinned_reg instruction, and to set it |
532 | | /// with the set_pinned_reg instruction. |
533 | 40.4M | pub fn enable_pinned_reg(&self) -> bool { |
534 | 40.4M | self.numbered_predicate(7) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
535 | 40.4M | } |
536 | | /// Enable various ABI extensions defined by LLVM's behavior. |
537 | | /// |
538 | | /// In some cases, LLVM's implementation of an ABI (calling convention) |
539 | | /// goes beyond a standard and supports additional argument types or |
540 | | /// behavior. This option instructs Cranelift codegen to follow LLVM's |
541 | | /// behavior where applicable. |
542 | | /// |
543 | | /// Currently, this applies only to Windows Fastcall on x86-64, and |
544 | | /// allows an `i128` argument to be spread across two 64-bit integer |
545 | | /// registers. The Fastcall implementation otherwise does not support |
546 | | /// `i128` arguments, and will panic if they are present and this |
547 | | /// option is not set. |
548 | 56.8k | pub fn enable_llvm_abi_extensions(&self) -> bool { |
549 | 56.8k | self.numbered_predicate(8) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
550 | 56.8k | } |
551 | | /// Enable support for sret arg introduction when there are too many ret vals. |
552 | | /// |
553 | | /// When there are more returns than available return registers, the |
554 | | /// return value has to be returned through the introduction of a |
555 | | /// return area pointer. Normally this return area pointer has to be |
556 | | /// introduced as `ArgumentPurpose::StructReturn` parameter, but for |
557 | | /// backward compatibility reasons Cranelift also supports implicitly |
558 | | /// introducing this parameter and writing the return values through it. |
559 | | /// |
560 | | /// **This option currently does not conform to platform ABIs and the |
561 | | /// used ABI should not be assumed to remain the same between Cranelift |
562 | | /// versions.** |
563 | | /// |
564 | | /// This option is **deprecated** and will be removed in the future. |
565 | | /// |
566 | | /// Because of the above issues, and complexities of native ABI support |
567 | | /// for the concept in general, Cranelift's support for multiple return |
568 | | /// values may also be removed in the future (#9510). For the most |
569 | | /// robust solution, it is recommended to build a convention on top of |
570 | | /// Cranelift's primitives for passing multiple return values, for |
571 | | /// example by allocating a stackslot in the caller, passing it as an |
572 | | /// explicit StructReturn argument, storing return values in the callee, |
573 | | /// and loading results in the caller. |
574 | 8.43M | pub fn enable_multi_ret_implicit_sret(&self) -> bool { |
575 | 8.43M | self.numbered_predicate(9) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
576 | 8.43M | } |
577 | | /// Generate unwind information. |
578 | | /// |
579 | | /// This increases metadata size and compile time, but allows for the |
580 | | /// debugger to trace frames, is needed for GC tracing that relies on |
581 | | /// libunwind (such as in Wasmtime), and is unconditionally needed on |
582 | | /// certain platforms (such as Windows) that must always be able to unwind. |
583 | 9.39M | pub fn unwind_info(&self) -> bool { |
584 | 9.39M | self.numbered_predicate(10) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
585 | 9.39M | } |
586 | | /// Preserve frame pointers |
587 | | /// |
588 | | /// Preserving frame pointers -- even inside leaf functions -- makes it |
589 | | /// easy to capture the stack of a running program, without requiring any |
590 | | /// side tables or metadata (like `.eh_frame` sections). Many sampling |
591 | | /// profilers and similar tools walk frame pointers to capture stacks. |
592 | | /// Enabling this option will play nice with those tools. |
593 | 426k | pub fn preserve_frame_pointers(&self) -> bool { |
594 | 426k | self.numbered_predicate(11) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
595 | 426k | } |
596 | | /// Generate CFG metadata for machine code. |
597 | | /// |
598 | | /// This increases metadata size and compile time, but allows for the |
599 | | /// embedder to more easily post-process or analyze the generated |
600 | | /// machine code. It provides code offsets for the start of each |
601 | | /// basic block in the generated machine code, and a list of CFG |
602 | | /// edges (with blocks identified by start offsets) between them. |
603 | | /// This is useful for, e.g., machine-code analyses that verify certain |
604 | | /// properties of the generated code. |
605 | 27.4M | pub fn machine_code_cfg_info(&self) -> bool { |
606 | 27.4M | self.numbered_predicate(12) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
607 | 27.4M | } |
608 | | /// Enable the use of stack probes for supported calling conventions. |
609 | 1.55M | pub fn enable_probestack(&self) -> bool { |
610 | 1.55M | self.numbered_predicate(13) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
611 | 1.55M | } |
612 | | /// Enable Spectre mitigation on heap bounds checks. |
613 | | /// |
614 | | /// This is a no-op for any heap that needs no bounds checks; e.g., |
615 | | /// if the limit is static and the guard region is large enough that |
616 | | /// the index cannot reach past it. |
617 | | /// |
618 | | /// This option is enabled by default because it is highly |
619 | | /// recommended for secure sandboxing. The embedder should consider |
620 | | /// the security implications carefully before disabling this option. |
621 | 2.51M | pub fn enable_heap_access_spectre_mitigation(&self) -> bool { |
622 | 2.51M | self.numbered_predicate(14) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
623 | 2.51M | } |
624 | | /// Enable Spectre mitigation on table bounds checks. |
625 | | /// |
626 | | /// This option uses a conditional move to ensure that when a table |
627 | | /// access index is bounds-checked and a conditional branch is used |
628 | | /// for the out-of-bounds case, a misspeculation of that conditional |
629 | | /// branch (falsely predicted in-bounds) will select an in-bounds |
630 | | /// index to load on the speculative path. |
631 | | /// |
632 | | /// This option is enabled by default because it is highly |
633 | | /// recommended for secure sandboxing. The embedder should consider |
634 | | /// the security implications carefully before disabling this option. |
635 | 833k | pub fn enable_table_access_spectre_mitigation(&self) -> bool { |
636 | 833k | self.numbered_predicate(15) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
637 | 833k | } |
638 | | /// Enable additional checks for debugging the incremental compilation cache. |
639 | | /// |
640 | | /// Enables additional checks that are useful during development of the incremental |
641 | | /// compilation cache. This should be mostly useful for Cranelift hackers, as well as for |
642 | | /// helping to debug false incremental cache positives for embedders. |
643 | | /// |
644 | | /// This option is disabled by default and requires enabling the "incremental-cache" Cargo |
645 | | /// feature in cranelift-codegen. |
646 | 0 | pub fn enable_incremental_compilation_cache_checks(&self) -> bool { |
647 | 0 | self.numbered_predicate(16) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
648 | 0 | } |
649 | | /// Enable Mach-O compact unwind compatible code emission. |
650 | | /// |
651 | | /// This constrains function prologues and epilogues to the ABI shape |
652 | | /// that Mach-O compact unwind can encode. Unwind instructions describe |
653 | | /// which pairs of callee-save registers are saved and restored, but the |
654 | | /// canonical stack frame layout is still expected: nonvolatile registers |
655 | | /// must be placed near the top of the frame, immediately below the |
656 | | /// return address. |
657 | | /// |
658 | | /// The unwind encoding only supports register pairs emitted with `stp`; |
659 | | /// it cannot encode individual registers. This may result in slightly |
660 | | /// larger stack frames. |
661 | 202 | pub fn enable_compact_unwind_abi(&self) -> bool { |
662 | 202 | self.numbered_predicate(17) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:155 |
663 | 202 | } |
664 | | } |
665 | | static DESCRIPTORS: [detail::Descriptor; 27] = [ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:224 |
666 | | detail::Descriptor { |
667 | | name: "regalloc_algorithm", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
668 | | description: "Algorithm to use in register allocator.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
669 | | offset: 0, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
670 | | detail: detail::Detail::Enum { last: 1, enumerators: 0 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
671 | | } |
672 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
673 | | detail::Descriptor { |
674 | | name: "opt_level", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
675 | | description: "Optimization level for generated code.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
676 | | offset: 1, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
677 | | detail: detail::Detail::Enum { last: 2, enumerators: 2 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
678 | | } |
679 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
680 | | detail::Descriptor { |
681 | | name: "tls_model", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
682 | | description: "Defines the model used to perform TLS accesses.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
683 | | offset: 2, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
684 | | detail: detail::Detail::Enum { last: 3, enumerators: 5 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
685 | | } |
686 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
687 | | detail::Descriptor { |
688 | | name: "stack_switch_model", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
689 | | description: "Defines the model used to performing stack switching.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
690 | | offset: 3, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
691 | | detail: detail::Detail::Enum { last: 2, enumerators: 9 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
692 | | } |
693 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
694 | | detail::Descriptor { |
695 | | name: "libcall_call_conv", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
696 | | description: "Defines the calling convention to use for LibCalls call expansion.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
697 | | offset: 4, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
698 | | detail: detail::Detail::Enum { last: 6, enumerators: 12 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
699 | | } |
700 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
701 | | detail::Descriptor { |
702 | | name: "probestack_size_log2", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
703 | | description: "The log2 of the size of the stack guard region.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
704 | | offset: 5, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
705 | | detail: detail::Detail::Num, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:253 |
706 | | } |
707 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
708 | | detail::Descriptor { |
709 | | name: "probestack_strategy", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
710 | | description: "Controls what kinds of stack probes are emitted.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
711 | | offset: 6, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
712 | | detail: detail::Detail::Enum { last: 1, enumerators: 19 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:245 |
713 | | } |
714 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
715 | | detail::Descriptor { |
716 | | name: "bb_padding_log2_minus_one", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
717 | | description: "The log2 of the size to insert dummy padding between basic blocks", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
718 | | offset: 7, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
719 | | detail: detail::Detail::Num, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:253 |
720 | | } |
721 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
722 | | detail::Descriptor { |
723 | | name: "log2_min_function_alignment", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
724 | | description: "The log2 of the minimum alignment of functions", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
725 | | offset: 8, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
726 | | detail: detail::Detail::Num, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:253 |
727 | | } |
728 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
729 | | detail::Descriptor { |
730 | | name: "regalloc_checker", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
731 | | description: "Enable the symbolic checker for register allocation.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
732 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
733 | | detail: detail::Detail::Bool { bit: 0 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
734 | | } |
735 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
736 | | detail::Descriptor { |
737 | | name: "regalloc_verbose_logs", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
738 | | description: "Enable verbose debug logs for regalloc2.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
739 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
740 | | detail: detail::Detail::Bool { bit: 1 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
741 | | } |
742 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
743 | | detail::Descriptor { |
744 | | name: "enable_alias_analysis", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
745 | | description: "Do redundant-load optimizations with alias analysis.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
746 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
747 | | detail: detail::Detail::Bool { bit: 2 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
748 | | } |
749 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
750 | | detail::Descriptor { |
751 | | name: "enable_verifier", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
752 | | description: "Run the Cranelift IR verifier at strategic times during compilation.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
753 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
754 | | detail: detail::Detail::Bool { bit: 3 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
755 | | } |
756 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
757 | | detail::Descriptor { |
758 | | name: "is_pic", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
759 | | description: "Enable Position-Independent Code generation.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
760 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
761 | | detail: detail::Detail::Bool { bit: 4 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
762 | | } |
763 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
764 | | detail::Descriptor { |
765 | | name: "use_colocated_libcalls", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
766 | | description: "Use colocated libcalls.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
767 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
768 | | detail: detail::Detail::Bool { bit: 5 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
769 | | } |
770 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
771 | | detail::Descriptor { |
772 | | name: "enable_nan_canonicalization", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
773 | | description: "Enable NaN canonicalization.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
774 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
775 | | detail: detail::Detail::Bool { bit: 6 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
776 | | } |
777 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
778 | | detail::Descriptor { |
779 | | name: "enable_pinned_reg", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
780 | | description: "Enable the use of the pinned register.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
781 | | offset: 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
782 | | detail: detail::Detail::Bool { bit: 7 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
783 | | } |
784 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
785 | | detail::Descriptor { |
786 | | name: "enable_llvm_abi_extensions", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
787 | | description: "Enable various ABI extensions defined by LLVM's behavior.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
788 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
789 | | detail: detail::Detail::Bool { bit: 0 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
790 | | } |
791 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
792 | | detail::Descriptor { |
793 | | name: "enable_multi_ret_implicit_sret", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
794 | | description: "Enable support for sret arg introduction when there are too many ret vals.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
795 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
796 | | detail: detail::Detail::Bool { bit: 1 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
797 | | } |
798 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
799 | | detail::Descriptor { |
800 | | name: "unwind_info", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
801 | | description: "Generate unwind information.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
802 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
803 | | detail: detail::Detail::Bool { bit: 2 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
804 | | } |
805 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
806 | | detail::Descriptor { |
807 | | name: "preserve_frame_pointers", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
808 | | description: "Preserve frame pointers", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
809 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
810 | | detail: detail::Detail::Bool { bit: 3 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
811 | | } |
812 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
813 | | detail::Descriptor { |
814 | | name: "machine_code_cfg_info", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
815 | | description: "Generate CFG metadata for machine code.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
816 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
817 | | detail: detail::Detail::Bool { bit: 4 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
818 | | } |
819 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
820 | | detail::Descriptor { |
821 | | name: "enable_probestack", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
822 | | description: "Enable the use of stack probes for supported calling conventions.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
823 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
824 | | detail: detail::Detail::Bool { bit: 5 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
825 | | } |
826 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
827 | | detail::Descriptor { |
828 | | name: "enable_heap_access_spectre_mitigation", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
829 | | description: "Enable Spectre mitigation on heap bounds checks.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
830 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
831 | | detail: detail::Detail::Bool { bit: 6 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
832 | | } |
833 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
834 | | detail::Descriptor { |
835 | | name: "enable_table_access_spectre_mitigation", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
836 | | description: "Enable Spectre mitigation on table bounds checks.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
837 | | offset: 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
838 | | detail: detail::Detail::Bool { bit: 7 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
839 | | } |
840 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
841 | | detail::Descriptor { |
842 | | name: "enable_incremental_compilation_cache_checks", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
843 | | description: "Enable additional checks for debugging the incremental compilation cache.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
844 | | offset: 11, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
845 | | detail: detail::Detail::Bool { bit: 0 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
846 | | } |
847 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
848 | | detail::Descriptor { |
849 | | name: "enable_compact_unwind_abi", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:232 |
850 | | description: "Enable Mach-O compact unwind compatible code emission.", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:233 |
851 | | offset: 11, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:234 |
852 | | detail: detail::Detail::Bool { bit: 1 }, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:237 |
853 | | } |
854 | | , // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:259 |
855 | | ]; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:275 |
856 | | static ENUMERATORS: [&str; 21] = [ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:278 |
857 | | "backtracking", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
858 | | "single_pass", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
859 | | "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
860 | | "speed", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
861 | | "speed_and_size", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
862 | | "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
863 | | "elf_gd", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
864 | | "macho", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
865 | | "coff", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
866 | | "none", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
867 | | "basic", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
868 | | "update_windows_tib", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
869 | | "isa_default", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
870 | | "fast", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
871 | | "system_v", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
872 | | "windows_fastcall", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
873 | | "apple_aarch64", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
874 | | "probestack", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
875 | | "preserve_all", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
876 | | "outline", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
877 | | "inline", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:281 |
878 | | ]; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:284 |
879 | | static HASH_TABLE: [u16; 64] = [ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:294 |
880 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
881 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
882 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
883 | | 2, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
884 | | 11, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
885 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
886 | | 24, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
887 | | 26, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
888 | | 20, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
889 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
890 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
891 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
892 | | 25, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
893 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
894 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
895 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
896 | | 16, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
897 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
898 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
899 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
900 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
901 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
902 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
903 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
904 | | 7, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
905 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
906 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
907 | | 6, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
908 | | 1, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
909 | | 0, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
910 | | 3, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
911 | | 13, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
912 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
913 | | 18, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
914 | | 22, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
915 | | 8, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
916 | | 15, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
917 | | 12, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
918 | | 17, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
919 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
920 | | 9, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
921 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
922 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
923 | | 19, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
924 | | 5, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
925 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
926 | | 23, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
927 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
928 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
929 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
930 | | 21, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
931 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
932 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
933 | | 10, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
934 | | 14, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
935 | | 4, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:298 |
936 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
937 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
938 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
939 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
940 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
941 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
942 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
943 | | 0xffff, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:306 |
944 | | ]; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:310 |
945 | | static PRESETS: [(u8, u8); 0] = [ // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:313 |
946 | | ]; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:330 |
947 | | static TEMPLATE: detail::Template = detail::Template { |
948 | | name: "shared", // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:345 |
949 | | descriptors: &DESCRIPTORS, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:346 |
950 | | enumerators: &ENUMERATORS, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:347 |
951 | | hash_table: &HASH_TABLE, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:348 |
952 | | defaults: &[0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x0c, 0xc4, 0x00], // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:349 |
953 | | presets: &PRESETS, // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:350 |
954 | | } |
955 | | ; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:353 |
956 | | /// Create a `settings::Builder` for the shared settings group. |
957 | 139k | pub fn builder() -> Builder { |
958 | 139k | Builder::new(&TEMPLATE) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:360 |
959 | 139k | } |
960 | | impl fmt::Display for Flags { |
961 | 0 | fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { |
962 | 0 | writeln!(f, "[shared]")?; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:369 |
963 | 0 | for d in &DESCRIPTORS { |
964 | 0 | if !d.detail.is_preset() { |
965 | 0 | write!(f, "{} = ", d.name)?; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:372 |
966 | 0 | TEMPLATE.format_toml_value(d.detail, self.bytes[d.offset as usize], f)?; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:373 |
967 | 0 | writeln!(f)?; // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:377 |
968 | 0 | } |
969 | | } |
970 | 0 | Ok(()) // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:380 |
971 | 0 | } |
972 | | } |
973 | | impl Flags { |
974 | | /// Get the flag values as raw bytes for hashing. |
975 | 0 | pub fn hash_key(&self) -> &[u8] { |
976 | 0 | &self.bytes // /src/wasmtime/cranelift/codegen/meta/src/gen_settings.rs:390 |
977 | 0 | } |
978 | | } |