rust/tests
Guillaume Gomez 23bab15d73
Rollup merge of #133463 - taiki-e:aarch64-asm-x18, r=Amanieu
Fix handling of x18 in AArch64 inline assembly on ohos/trusty or with -Zfixed-x18

Currently AArch64 inline assembly allows using x18 on ohos/trusty or with -Zfixed-x18.

7db7489f9b/compiler/rustc_target/src/asm/aarch64.rs (L74-L76)

However, x18 is reserved in these environments and should not be allowed in the input/output operands of inline assemblies as it is in Android, Windows, etc..

7db7489f9b/compiler/rustc_target/src/spec/targets/aarch64_unknown_linux_ohos.rs (L19)
7db7489f9b/compiler/rustc_target/src/spec/targets/aarch64_unknown_trusty.rs (L18)
7db7489f9b/compiler/rustc_codegen_llvm/src/llvm_util.rs (L764-L771)

(As for ohos, +reserve-x18 is [redundant](c417b7a695 (diff-0ddf23e0bf2b28b2d05f842f087d1e6f694e8e06d1765e8d0f10d47fddcdff9c)) since 7a966b9188 that starting using llvm's ohos targets. So removed it from target-spec.)

This fix may potentially break the code for tier 2 target (aarch64-unknown-linux-ohos). (As for others, aarch64-unknown-trusty is tier 3 and -Zfixed-x18 is unstable so breaking them should be fine.)
However, in any case, it seems suspicious that the code that is broken by this was sound.

r? `@Amanieu`

`@rustbot` label O-AArch64 +A-inline-assembly
2024-11-28 12:06:02 +01:00
..
assembly Make s390x non-clobber-only vector register support unstable 2024-11-24 21:42:22 +09:00
auxiliary Support input/output in vector registers of s390x inline assembly 2024-11-22 04:18:14 +09:00
codegen Rollup merge of #133463 - taiki-e:aarch64-asm-x18, r=Amanieu 2024-11-28 12:06:02 +01:00
codegen-units
coverage Auto merge of #133474 - RalfJung:gvn-miscompile, r=compiler-errors 2024-11-27 15:43:56 +00:00
coverage-run-rustdoc coverage: Restrict empty-span expansion to only cover { and } 2024-11-08 20:43:08 +11:00
crashes Rollup merge of #133368 - compiler-errors:codegen-select-unconstrained-params, r=lcnr 2024-11-28 03:14:46 +01:00
debuginfo Mark numeric-types.rs as 64-bit only for now 2024-11-17 04:16:59 +08:00
incremental fixup some test directives 2024-11-17 22:15:54 +00:00
mir-opt Rollup merge of #133418 - Zalathar:spans, r=jieyouxu 2024-11-27 22:23:25 +01:00
pretty
run-make Rollup merge of #133513 - ChrisDenton:windows-msvc, r=jieyouxu 2024-11-26 20:35:41 -05:00
rustdoc Add regression test for prelude types 2024-11-25 17:25:25 +01:00
rustdoc-gui rustdoc-search: simplify rules for generics and type params 2024-10-30 12:27:48 -07:00
rustdoc-js rustdoc-search: add standalone trailing :: test 2024-11-17 08:07:16 -07:00
rustdoc-js-std rustdoc search: allow queries to end in an empty path segment 2024-11-15 16:32:40 -06:00
rustdoc-json
rustdoc-ui Rollup merge of #133394 - compiler-errors:dyn-more-errors, r=lcnr 2024-11-26 12:03:44 -05:00
ui Rollup merge of #133463 - taiki-e:aarch64-asm-x18, r=Amanieu 2024-11-28 12:06:02 +01:00
ui-fulldeps Rollup merge of #132410 - bjorn3:yet_another_driver_refactor_round, r=cjgillot 2024-11-27 22:23:24 +01:00
COMPILER_TESTS.md