Skip to content

Commit a161a7b

Browse files
committed
Auto merge of rust-lang#105384 - uweigand:s390x-test-codegen, r=Mark-Simulacrum
Fix failing codegen tests on s390x Several codegen tests are currently failing due to making assumptions that are not valid for the s390x architecture: - catch-unwind.rs: fails due to inlining differences. Already ignored on another platform for the same reason. Solution: Ignore on s390x. - remap_path_prefix/main.rs: fails due to different alignment requirement for string constants. Solution: Do not test for the alignment requirement. - repr-transparent-aggregates-1.rs: many ABI assumptions. Already ignored on many platforms for the same reason. Solution: Ignore on s390x. - repr-transparent.rs: no vector ABI by default on s390x. Already ignored on another platform for a similar reason. Solution: Ignore on s390x. - uninit-consts.rs: hard-coded little-endian constant. Solution: Match both little- and big-endian versions. Fixes part of rust-lang#105383.
2 parents b12b836 + 3d33af3 commit a161a7b

File tree

5 files changed

+6
-2
lines changed

5 files changed

+6
-2
lines changed

src/test/codegen/catch-unwind.rs

+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
// On riscv the closure is another function, placed before fn foo so CHECK can't
99
// find it
1010
// ignore-riscv64 FIXME
11+
// On s390x the closure is also in another function
12+
// ignore-s390x FIXME
1113

1214
#![crate_type = "lib"]
1315
#![feature(c_unwind)]

src/test/codegen/remap_path_prefix/main.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ mod aux_mod;
1212
include!("aux_mod.rs");
1313

1414
// Here we check that the expansion of the file!() macro is mapped.
15-
// CHECK: @alloc2 = private unnamed_addr constant <{ [34 x i8] }> <{ [34 x i8] c"/the/src/remap_path_prefix/main.rs" }>, align 1
15+
// CHECK: @alloc2 = private unnamed_addr constant <{ [34 x i8] }> <{ [34 x i8] c"/the/src/remap_path_prefix/main.rs" }>
1616
pub static FILE_PATH: &'static str = file!();
1717

1818
fn main() {

src/test/codegen/repr-transparent-aggregates-1.rs

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
// ignore-powerpc
99
// ignore-powerpc64
1010
// ignore-riscv64 see codegen/riscv-abi
11+
// ignore-s390x
1112
// ignore-windows
1213
// See repr-transparent.rs
1314

src/test/codegen/repr-transparent.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
// ignore-riscv64 riscv64 has an i128 type used with test_Vector
44
// see codegen/riscv-abi for riscv functiona call tests
5+
// ignore-s390x s390x with default march passes vector types per reference
56

67
#![crate_type="lib"]
78
#![feature(repr_simd, transparent_unions)]

src/test/codegen/uninit-consts.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ pub struct PartiallyUninit {
1414

1515
// CHECK: [[FULLY_UNINIT:@[0-9]+]] = private unnamed_addr constant <{ [10 x i8] }> undef
1616

17-
// CHECK: [[PARTIALLY_UNINIT:@[0-9]+]] = private unnamed_addr constant <{ [4 x i8], [12 x i8] }> <{ [4 x i8] c"\EF\BE\AD\DE", [12 x i8] undef }>, align 4
17+
// CHECK: [[PARTIALLY_UNINIT:@[0-9]+]] = private unnamed_addr constant <{ [4 x i8], [12 x i8] }> <{ [4 x i8] c"{{\\EF\\BE\\AD\\DE|\\DE\\AD\\BE\\EF}}", [12 x i8] undef }>, align 4
1818

1919
// This shouldn't contain undef, since it contains more chunks
2020
// than the default value of uninit_const_chunk_threshold.

0 commit comments

Comments
 (0)