Skip to content

Commit 97e2213

Browse files
committed
Enable inline stack probes on AArch64
Fixes rust-lang#661
1 parent debd45c commit 97e2213

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/lib.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -278,12 +278,14 @@ fn build_isa(sess: &Session, backend_config: &BackendConfig) -> Box<dyn isa::Tar
278278
}
279279
}
280280

281-
if target_triple.architecture == target_lexicon::Architecture::X86_64 {
281+
if let target_lexicon::Architecture::Aarch64(_) | target_lexicon::Architecture::X86_64 =
282+
target_triple.architecture
283+
{
282284
// Windows depends on stack probes to grow the committed part of the stack
283285
flags_builder.enable("enable_probestack").unwrap();
284286
flags_builder.set("probestack_strategy", "inline").unwrap();
285287
} else {
286-
// __cranelift_probestack is not provided and inline stack probes are only supported on x86_64
288+
// __cranelift_probestack is not provided and inline stack probes are only supported on AArch64 and x86_64
287289
flags_builder.set("enable_probestack", "false").unwrap();
288290
}
289291

0 commit comments

Comments
 (0)