Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 459d5b5

Browse files
Rollup merge of #138371 - cuviper:stable-asm-test, r=jieyouxu
Update compiletest's `has_asm_support` to match rustc The list of `ASM_SUPPORTED_ARCHS` was missing a few from the compiler's actual stable list.
2 parents 10be973 + 576bcfc commit 459d5b5

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

‎compiler/rustc_ast_lowering/src/asm.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ impl<'a, 'hir> LoweringContext<'a, 'hir> {
3838
}
3939
if let Some(asm_arch) = asm_arch {
4040
// Inline assembly is currently only stable for these architectures.
41+
// (See also compiletest's `has_asm_support`.)
4142
let is_stable = matches!(
4243
asm_arch,
4344
asm::InlineAsmArch::X86

‎src/tools/compiletest/src/common.rs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,9 +481,17 @@ impl Config {
481481
}
482482

483483
pub fn has_asm_support(&self) -> bool {
484+
// This should match the stable list in `LoweringContext::lower_inline_asm`.
484485
static ASM_SUPPORTED_ARCHS: &[&str] = &[
485-
"x86", "x86_64", "arm", "aarch64", "riscv32",
486+
"x86",
487+
"x86_64",
488+
"arm",
489+
"aarch64",
490+
"arm64ec",
491+
"riscv32",
486492
"riscv64",
493+
"loongarch64",
494+
"s390x",
487495
// These targets require an additional asm_experimental_arch feature.
488496
// "nvptx64", "hexagon", "mips", "mips64", "spirv", "wasm32",
489497
];

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /