tests/assembly: use -Copt-level=3 instead of -O
This commit is contained in:
parent
b3464fa65f
commit
ee111b24e3
25 changed files with 29 additions and 28 deletions
|
@ -1,6 +1,6 @@
|
|||
//@ add-core-stubs
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O -C panic=abort
|
||||
//@ compile-flags: -Copt-level=3 -C panic=abort
|
||||
//@ compile-flags: --target aarch64-unknown-linux-gnu
|
||||
//@ compile-flags: -Zmerge-functions=disabled
|
||||
//@ needs-llvm-components: aarch64
|
||||
|
@ -15,7 +15,7 @@ use minicore::*;
|
|||
|
||||
macro_rules! check {
|
||||
($func:ident $reg:ident $code:literal) => {
|
||||
// -O and extern "C" guarantee that the selected register is always r0/s0/d0/q0
|
||||
// -Copt-level=3 and extern "C" guarantee that the selected register is always r0/s0/d0/q0
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn $func() -> i32 {
|
||||
let y;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O
|
||||
//@ compile-flags: -Copt-level=3
|
||||
//@ compile-flags: --target aarch64-unknown-linux-gnu
|
||||
//@ needs-llvm-components: aarch64
|
||||
//@ only-aarch64
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ add-core-stubs
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O -C panic=abort
|
||||
//@ compile-flags: -Copt-level=3 -C panic=abort
|
||||
//@ compile-flags: --target armv7-unknown-linux-gnueabihf
|
||||
//@ compile-flags: -C target-feature=+neon
|
||||
//@ compile-flags: -Zmerge-functions=disabled
|
||||
|
@ -21,7 +21,7 @@ impl Copy for f32x4 {}
|
|||
|
||||
macro_rules! check {
|
||||
($func:ident $modifier:literal $reg:ident $ty:ident $mov:literal) => {
|
||||
// -O and extern "C" guarantee that the selected register is always r0/s0/d0/q0
|
||||
// -Copt-level=3 and extern "C" guarantee that the selected register is always r0/s0/d0/q0
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn $func() -> $ty {
|
||||
let y;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
//@ add-core-stubs
|
||||
//@ revisions: x86_64 i686
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O -C panic=abort
|
||||
//@ compile-flags: -Copt-level=3 -C panic=abort
|
||||
//@[x86_64] compile-flags: --target x86_64-unknown-linux-gnu
|
||||
//@[x86_64] needs-llvm-components: x86
|
||||
//@[i686] compile-flags: --target i686-unknown-linux-gnu
|
||||
|
@ -20,7 +20,7 @@ use minicore::*;
|
|||
|
||||
macro_rules! check {
|
||||
($func:ident $modifier:literal $reg:ident $mov:literal) => {
|
||||
// -O and extern "C" guarantee that the selected register is always ax/xmm0
|
||||
// -Copt-level=3 and extern "C" guarantee that the selected register is always ax/xmm0
|
||||
#[no_mangle]
|
||||
pub unsafe extern "C" fn $func() -> i32 {
|
||||
let y;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ assembly-output: emit-asm
|
||||
// # zen3 previously exhibited odd vectorization
|
||||
//@ compile-flags: --crate-type=lib -Ctarget-cpu=znver3 -O
|
||||
//@ compile-flags: --crate-type=lib -Ctarget-cpu=znver3 -Copt-level=3
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// Regression test for #106269
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ assembly-output: emit-asm
|
||||
//@ only-x86_64-unknown-linux-gnu
|
||||
//@ compile-flags: -C panic=unwind -C force-unwind-tables=n -O
|
||||
//@ compile-flags: -C panic=unwind -C force-unwind-tables=n -Copt-level=3
|
||||
|
||||
#![crate_type = "lib"]
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ revisions: elfv1-be elfv2-be elfv2-le aix
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O
|
||||
//@ compile-flags: -Copt-level=3
|
||||
//@[elfv1-be] compile-flags: --target powerpc64-unknown-linux-gnu
|
||||
//@[elfv1-be] needs-llvm-components: powerpc
|
||||
//@[elfv2-be] compile-flags: --target powerpc64-unknown-linux-musl
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ revisions: enable-backchain disable-backchain
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O --crate-type=lib --target=s390x-unknown-linux-gnu
|
||||
//@ compile-flags: -Copt-level=3 --crate-type=lib --target=s390x-unknown-linux-gnu
|
||||
//@ needs-llvm-components: systemz
|
||||
//@[enable-backchain] compile-flags: -Ctarget-feature=+backchain
|
||||
//@[disable-backchain] compile-flags: -Ctarget-feature=-backchain
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
//@ revisions: z10 z10_vector z13 z13_no_vector
|
||||
// ignore-tidy-linelength
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O -Z merge-functions=disabled
|
||||
//@ compile-flags: -Copt-level=3 -Z merge-functions=disabled
|
||||
//@[z10] compile-flags: --target s390x-unknown-linux-gnu --cfg no_vector
|
||||
//@[z10] needs-llvm-components: systemz
|
||||
//@[z10_vector] compile-flags: --target s390x-unknown-linux-gnu -C target-feature=+vector
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
//@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
|
||||
//@ [aarch64] needs-llvm-components: aarch64
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
//@ [x86-avx512] compile-flags: -C target-feature=+avx512f,+avx512vl,+avx512bw,+avx512dq
|
||||
//@ [x86-avx512] needs-llvm-components: x86
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
//@ [x86-avx512] compile-flags: -C target-feature=+avx512f,+avx512vl,+avx512bw,+avx512dq
|
||||
//@ [x86-avx512] needs-llvm-components: x86
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
//@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
|
||||
//@ [aarch64] needs-llvm-components: aarch64
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
//@ [x86-avx512] compile-flags: -C target-feature=+avx512f,+avx512vl,+avx512bw,+avx512dq
|
||||
//@ [x86-avx512] needs-llvm-components: x86
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
//@ [x86-avx512] compile-flags: -C target-feature=+avx512f,+avx512vl,+avx512bw,+avx512dq
|
||||
//@ [x86-avx512] needs-llvm-components: x86
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
//@ [aarch64] compile-flags: --target=aarch64-unknown-linux-gnu
|
||||
//@ [aarch64] needs-llvm-components: aarch64
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C panic=abort
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C panic=abort
|
||||
|
||||
#![feature(no_core, lang_items, repr_simd, intrinsics)]
|
||||
#![no_core]
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
//@ revisions: x86_64 aarch64
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3
|
||||
|
||||
//@[aarch64] only-aarch64
|
||||
//@[x86_64] only-x86_64
|
||||
//@[x86_64] compile-flags: -Ctarget-feature=+sse3
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
//@ [WIN] only-windows
|
||||
//@ [LIN] only-linux
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
// Use the same target CPU as `i686` so that LLVM orders the instructions in the same order.
|
||||
//@ compile-flags: -Ctarget-feature=+sse2 -Ctarget-cpu=pentium4
|
||||
// Force frame pointers to make ASM more consistent between targets
|
||||
//@ compile-flags: -O -C force-frame-pointers
|
||||
//@ compile-flags: -Copt-level=3 -C force-frame-pointers
|
||||
//@ filecheck-flags: --implicit-check-not fld --implicit-check-not fst
|
||||
//@ revisions: normal win
|
||||
//@[normal] ignore-windows
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
//@ ignore-apple (manipulates rsp too)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
//@ only-x86_64
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: --crate-type=lib -O -C target-cpu=x86-64-v4
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C target-cpu=x86-64-v4
|
||||
//@ compile-flags: -C llvm-args=-x86-asm-syntax=intel
|
||||
//@ revisions: llvm-pre-20 llvm-20
|
||||
//@ [llvm-20] min-llvm-version: 20
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
//@ assembly-output: emit-asm
|
||||
// Set the base cpu explicitly, in case the default has been changed.
|
||||
//@ compile-flags: --crate-type=lib -O -C llvm-args=-x86-asm-syntax=intel -C target-cpu=x86-64
|
||||
//@ compile-flags: --crate-type=lib -Copt-level=3 -C llvm-args=-x86-asm-syntax=intel -C target-cpu=x86-64
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
//@ revisions: unset keep thunk-extern keep-thunk-extern thunk-extern-keep
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O
|
||||
//@ compile-flags: -Copt-level=3
|
||||
//@ [keep] compile-flags: -Zfunction-return=keep
|
||||
//@ [thunk-extern] compile-flags: -Zfunction-return=thunk-extern
|
||||
//@ [keep-thunk-extern] compile-flags: -Zfunction-return=keep -Zfunction-return=thunk-extern
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
//@ revisions: unset set
|
||||
//@ assembly-output: emit-asm
|
||||
//@ compile-flags: -O
|
||||
//@ compile-flags: -Copt-level=3
|
||||
//@ [set] compile-flags: -Zno-jump-tables
|
||||
//@ only-x86_64
|
||||
//@ ignore-sgx
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue