Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rollup of 8 pull requests #120359

Closed
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
c824399
Fix broken markdown in csky-unknown-linux-gnuabiv2.md
mbrubeck Jan 4, 2024
933e334
remove dead code in CGREP script
jyn514 Dec 24, 2023
19ca307
give a better error for tuple structs in `derive(Diagnostic)`
jyn514 Dec 24, 2023
56fc9c7
show linker warnings even if it returns 0
jyn514 Dec 24, 2023
aac51d5
don't show the full linker args unless `--verbose` is passed
jyn514 Dec 25, 2023
56bc552
Bump `object` version
clubby789 Jan 21, 2024
b50b333
Bump `uniq-langid` version
clubby789 Jan 21, 2024
dbf55f6
Add the wasm32-wasi-preview2 target
rylev Dec 18, 2023
8c2ae80
Don't manually resolve async closures in rustc_resolve
compiler-errors Jan 24, 2024
886108b
Add feature gate
Nadrieril Jan 8, 2024
95a14d4
Implement feature gate logic
Nadrieril Jan 18, 2024
8866449
Split assembly tests for ELF and MachO
nikic Jan 19, 2024
27717db
Builtin macros effectively have implicit #[collapse_debuginfo(yes)] a…
azhogin Jan 21, 2024
e1cd05a
Rollup merge of #118803 - Nadrieril:min-exhaustive-patterns, r=compil…
compiler-errors Jan 26, 2024
c8e8ab2
Rollup merge of #119286 - jyn514:linker-output, r=bjorn3
compiler-errors Jan 26, 2024
2f19fb1
Rollup merge of #119616 - rylev:wasm32-wasi-preview2, r=petrochenkov,…
compiler-errors Jan 26, 2024
d3eda76
Rollup merge of #120124 - nikic:fix-assembly-test, r=davidtwco
compiler-errors Jan 26, 2024
c4a2e80
Rollup merge of #120201 - clubby789:dep-update, r=dtolnay
compiler-errors Jan 26, 2024
10de17a
Rollup merge of #120204 - azhogin:azhogin/collapse_debuginfo_for_buil…
compiler-errors Jan 26, 2024
4950b02
Rollup merge of #120322 - compiler-errors:higher-ranked-async-closure…
compiler-errors Jan 26, 2024
907936e
Rollup merge of #120356 - mbrubeck:patch-2, r=ehuss
compiler-errors Jan 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Split assembly tests for ELF and MachO
On ELF, the text section is opened with ".text", on MachO with
".section __TEXT,__text".

Previously, on ELF this test was actually matching a GNU note
section, which is no longer emitted on Solaris starting with
LLVM 18.

Fixes #120105.
  • Loading branch information
nikic committed Jan 25, 2024
commit 8866449c6672f3fc7887edb96616a46530e18947
65 changes: 1 addition & 64 deletions tests/assembly/targets/targets-elf.rs
Original file line number Diff line number Diff line change
@@ -1,29 +1,5 @@
// assembly-output: emit-asm
// ignore-tidy-linelength
// revisions: aarch64_apple_darwin
// [aarch64_apple_darwin] compile-flags: --target aarch64-apple-darwin
// [aarch64_apple_darwin] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios
// [aarch64_apple_ios] compile-flags: --target aarch64-apple-ios
// [aarch64_apple_ios] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios_macabi
// [aarch64_apple_ios_macabi] compile-flags: --target aarch64-apple-ios-macabi
// [aarch64_apple_ios_macabi] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios_sim
// [aarch64_apple_ios_sim] compile-flags: --target aarch64-apple-ios-sim
// [aarch64_apple_ios_sim] needs-llvm-components: aarch64
// revisions: aarch64_apple_tvos
// [aarch64_apple_tvos] compile-flags: --target aarch64-apple-tvos
// [aarch64_apple_tvos] needs-llvm-components: aarch64
// revisions: aarch64_apple_tvos_sim
// [aarch64_apple_tvos_sim] compile-flags: --target aarch64-apple-tvos-sim
// [aarch64_apple_tvos_sim] needs-llvm-components: aarch64
// revisions: aarch64_apple_watchos
// [aarch64_apple_watchos] compile-flags: --target aarch64-apple-watchos
// [aarch64_apple_watchos] needs-llvm-components: aarch64
// revisions: aarch64_apple_watchos_sim
// [aarch64_apple_watchos_sim] compile-flags: --target aarch64-apple-watchos-sim
// [aarch64_apple_watchos_sim] needs-llvm-components: aarch64
// revisions: aarch64_be_unknown_linux_gnu
// [aarch64_be_unknown_linux_gnu] compile-flags: --target aarch64_be-unknown-linux-gnu
// [aarch64_be_unknown_linux_gnu] needs-llvm-components: aarch64
Expand Down Expand Up @@ -93,15 +69,6 @@
// revisions: aarch64_wrs_vxworks
// [aarch64_wrs_vxworks] compile-flags: --target aarch64-wrs-vxworks
// [aarch64_wrs_vxworks] needs-llvm-components: aarch64
// revisions: arm64_32_apple_watchos
// [arm64_32_apple_watchos] compile-flags: --target arm64_32-apple-watchos
// [arm64_32_apple_watchos] needs-llvm-components: aarch64
// revisions: arm64e_apple_darwin
// [arm64e_apple_darwin] compile-flags: --target arm64e-apple-darwin
// [arm64e_apple_darwin] needs-llvm-components: aarch64
// revisions: arm64e_apple_ios
// [arm64e_apple_ios] compile-flags: --target arm64e-apple-ios
// [arm64e_apple_ios] needs-llvm-components: aarch64
// revisions: arm_linux_androideabi
// [arm_linux_androideabi] compile-flags: --target arm-linux-androideabi
// [arm_linux_androideabi] needs-llvm-components: arm
Expand Down Expand Up @@ -201,18 +168,12 @@
// revisions: armv7a_none_eabihf
// [armv7a_none_eabihf] compile-flags: --target armv7a-none-eabihf
// [armv7a_none_eabihf] needs-llvm-components: arm
// revisions: armv7k_apple_watchos
// [armv7k_apple_watchos] compile-flags: --target armv7k-apple-watchos
// [armv7k_apple_watchos] needs-llvm-components: arm
// revisions: armv7r_none_eabi
// [armv7r_none_eabi] compile-flags: --target armv7r-none-eabi
// [armv7r_none_eabi] needs-llvm-components: arm
// revisions: armv7r_none_eabihf
// [armv7r_none_eabihf] compile-flags: --target armv7r-none-eabihf
// [armv7r_none_eabihf] needs-llvm-components: arm
// revisions: armv7s_apple_ios
// [armv7s_apple_ios] compile-flags: --target armv7s-apple-ios
// [armv7s_apple_ios] needs-llvm-components: arm
// FIXME: disabled since it fails on CI saying the csky component is missing
/*
revisions: csky_unknown_linux_gnuabiv2
Expand All @@ -228,9 +189,6 @@
// revisions: hexagon_unknown_none_elf
// [hexagon_unknown_none_elf] compile-flags: --target hexagon-unknown-none-elf
// [hexagon_unknown_none_elf] needs-llvm-components: hexagon
// revisions: i386_apple_ios
// [i386_apple_ios] compile-flags: --target i386-apple-ios
// [i386_apple_ios] needs-llvm-components: x86
// revisions: i586_pc_nto_qnx700
// [i586_pc_nto_qnx700] compile-flags: --target i586-pc-nto-qnx700
// [i586_pc_nto_qnx700] needs-llvm-components: x86
Expand All @@ -243,9 +201,6 @@
// revisions: i586_unknown_netbsd
// [i586_unknown_netbsd] compile-flags: --target i586-unknown-netbsd
// [i586_unknown_netbsd] needs-llvm-components: x86
// revisions: i686_apple_darwin
// [i686_apple_darwin] compile-flags: --target i686-apple-darwin
// [i686_apple_darwin] needs-llvm-components: x86
// revisions: i686_linux_android
// [i686_linux_android] compile-flags: --target i686-linux-android
// [i686_linux_android] needs-llvm-components: x86
Expand Down Expand Up @@ -537,21 +492,6 @@
// revisions: wasm32_wasi_preview2
// [wasm32_wasi_preview2] compile-flags: --target wasm32-wasi-preview2
// [wasm32_wasi_preview2] needs-llvm-components: webassembly
// revisions: x86_64_apple_darwin
// [x86_64_apple_darwin] compile-flags: --target x86_64-apple-darwin
// [x86_64_apple_darwin] needs-llvm-components: x86
// revisions: x86_64_apple_ios
// [x86_64_apple_ios] compile-flags: --target x86_64-apple-ios
// [x86_64_apple_ios] needs-llvm-components: x86
// revisions: x86_64_apple_ios_macabi
// [x86_64_apple_ios_macabi] compile-flags: --target x86_64-apple-ios-macabi
// [x86_64_apple_ios_macabi] needs-llvm-components: x86
// revisions: x86_64_apple_tvos
// [x86_64_apple_tvos] compile-flags: --target x86_64-apple-tvos
// [x86_64_apple_tvos] needs-llvm-components: x86
// revisions: x86_64_apple_watchos_sim
// [x86_64_apple_watchos_sim] compile-flags: --target x86_64-apple-watchos-sim
// [x86_64_apple_watchos_sim] needs-llvm-components: x86
// revisions: x86_64_fortanix_unknown_sgx
// [x86_64_fortanix_unknown_sgx] compile-flags: --target x86_64-fortanix-unknown-sgx
// [x86_64_fortanix_unknown_sgx] needs-llvm-components: x86
Expand Down Expand Up @@ -618,9 +558,6 @@
// revisions: x86_64_wrs_vxworks
// [x86_64_wrs_vxworks] compile-flags: --target x86_64-wrs-vxworks
// [x86_64_wrs_vxworks] needs-llvm-components: x86
// revisions: x86_64h_apple_darwin
// [x86_64h_apple_darwin] compile-flags: --target x86_64h-apple-darwin
// [x86_64h_apple_darwin] needs-llvm-components: x86

// Sanity-check that each target can produce assembly code.

Expand All @@ -636,4 +573,4 @@ pub fn test() -> u8 {
42
}

// CHECK: .section
// CHECK: .text
81 changes: 81 additions & 0 deletions tests/assembly/targets/targets-macho.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
// assembly-output: emit-asm
// ignore-tidy-linelength
// revisions: aarch64_apple_darwin
// [aarch64_apple_darwin] compile-flags: --target aarch64-apple-darwin
// [aarch64_apple_darwin] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios
// [aarch64_apple_ios] compile-flags: --target aarch64-apple-ios
// [aarch64_apple_ios] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios_macabi
// [aarch64_apple_ios_macabi] compile-flags: --target aarch64-apple-ios-macabi
// [aarch64_apple_ios_macabi] needs-llvm-components: aarch64
// revisions: aarch64_apple_ios_sim
// [aarch64_apple_ios_sim] compile-flags: --target aarch64-apple-ios-sim
// [aarch64_apple_ios_sim] needs-llvm-components: aarch64
// revisions: aarch64_apple_tvos
// [aarch64_apple_tvos] compile-flags: --target aarch64-apple-tvos
// [aarch64_apple_tvos] needs-llvm-components: aarch64
// revisions: aarch64_apple_tvos_sim
// [aarch64_apple_tvos_sim] compile-flags: --target aarch64-apple-tvos-sim
// [aarch64_apple_tvos_sim] needs-llvm-components: aarch64
// revisions: aarch64_apple_watchos
// [aarch64_apple_watchos] compile-flags: --target aarch64-apple-watchos
// [aarch64_apple_watchos] needs-llvm-components: aarch64
// revisions: aarch64_apple_watchos_sim
// [aarch64_apple_watchos_sim] compile-flags: --target aarch64-apple-watchos-sim
// [aarch64_apple_watchos_sim] needs-llvm-components: aarch64
// revisions: arm64_32_apple_watchos
// [arm64_32_apple_watchos] compile-flags: --target arm64_32-apple-watchos
// [arm64_32_apple_watchos] needs-llvm-components: aarch64
// revisions: arm64e_apple_darwin
// [arm64e_apple_darwin] compile-flags: --target arm64e-apple-darwin
// [arm64e_apple_darwin] needs-llvm-components: aarch64
// revisions: arm64e_apple_ios
// [arm64e_apple_ios] compile-flags: --target arm64e-apple-ios
// [arm64e_apple_ios] needs-llvm-components: aarch64
// revisions: armv7k_apple_watchos
// [armv7k_apple_watchos] compile-flags: --target armv7k-apple-watchos
// [armv7k_apple_watchos] needs-llvm-components: arm
// revisions: armv7s_apple_ios
// [armv7s_apple_ios] compile-flags: --target armv7s-apple-ios
// [armv7s_apple_ios] needs-llvm-components: arm
// revisions: i386_apple_ios
// [i386_apple_ios] compile-flags: --target i386-apple-ios
// [i386_apple_ios] needs-llvm-components: x86
// revisions: i686_apple_darwin
// [i686_apple_darwin] compile-flags: --target i686-apple-darwin
// [i686_apple_darwin] needs-llvm-components: x86
// revisions: x86_64_apple_darwin
// [x86_64_apple_darwin] compile-flags: --target x86_64-apple-darwin
// [x86_64_apple_darwin] needs-llvm-components: x86
// revisions: x86_64_apple_ios
// [x86_64_apple_ios] compile-flags: --target x86_64-apple-ios
// [x86_64_apple_ios] needs-llvm-components: x86
// revisions: x86_64_apple_ios_macabi
// [x86_64_apple_ios_macabi] compile-flags: --target x86_64-apple-ios-macabi
// [x86_64_apple_ios_macabi] needs-llvm-components: x86
// revisions: x86_64_apple_tvos
// [x86_64_apple_tvos] compile-flags: --target x86_64-apple-tvos
// [x86_64_apple_tvos] needs-llvm-components: x86
// revisions: x86_64_apple_watchos_sim
// [x86_64_apple_watchos_sim] compile-flags: --target x86_64-apple-watchos-sim
// [x86_64_apple_watchos_sim] needs-llvm-components: x86
// revisions: x86_64h_apple_darwin
// [x86_64h_apple_darwin] compile-flags: --target x86_64h-apple-darwin
// [x86_64h_apple_darwin] needs-llvm-components: x86

// Sanity-check that each target can produce assembly code.

#![feature(no_core, lang_items)]
#![no_std]
#![no_core]
#![crate_type = "lib"]

#[lang = "sized"]
trait Sized {}

pub fn test() -> u8 {
42
}

// CHECK: .section __TEXT,__text
Loading