Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 6718371

Browse files
committedNov 10, 2024·
Support s390x z13 vector ABI
1 parent 7660aed commit 6718371

File tree

9 files changed

+838
-16
lines changed

9 files changed

+838
-16
lines changed
 

‎compiler/rustc_target/src/callconv/s390x.rs‎

Lines changed: 36 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,36 @@
1-
// FIXME: The assumes we're using the non-vector ABI, i.e., compiling
2-
// for a pre-z13 machine or using -mno-vx.
1+
use rustc_abi::{BackendRepr, HasDataLayout, Size, TyAbiInterface, TyAndLayout};
32

4-
use crate::abi::call::{ArgAbi, FnAbi, Reg};
5-
use crate::abi::{HasDataLayout, TyAbiInterface};
3+
use crate::abi::call::{ArgAbi, FnAbi, Reg, RegKind};
64
use crate::spec::HasTargetSpec;
75

6+
fn contains_vector<'a, Ty, C>(cx: &C, layout: TyAndLayout<'a, Ty>, expected_size: Size) -> bool
7+
where
8+
Ty: TyAbiInterface<'a, C> + Copy,
9+
{
10+
match layout.backend_repr {
11+
BackendRepr::Uninhabited | BackendRepr::Scalar(_) | BackendRepr::ScalarPair(..) => false,
12+
BackendRepr::Vector { .. } => layout.size == expected_size,
13+
BackendRepr::Memory { .. } => {
14+
for i in 0..layout.fields.count() {
15+
if contains_vector(cx, layout.field(cx, i), expected_size) {
16+
return true;
17+
}
18+
}
19+
false
20+
}
21+
}
22+
}
23+
824
fn classify_ret<Ty>(ret: &mut ArgAbi<'_, Ty>) {
9-
if !ret.layout.is_aggregate() && ret.layout.size.bits() <= 64 {
25+
let size = ret.layout.size;
26+
if size.bits() <= 128 && matches!(ret.layout.backend_repr, BackendRepr::Vector { .. }) {
27+
return;
28+
}
29+
if !ret.layout.is_aggregate() && size.bits() <= 64 {
1030
ret.extend_integer_width_to(64);
11-
} else {
12-
ret.make_indirect();
31+
return;
1332
}
33+
ret.make_indirect();
1434
}
1535

1636
fn classify_arg<'a, Ty, C>(cx: &C, arg: &mut ArgAbi<'a, Ty>)
@@ -32,19 +52,25 @@ where
3252
}
3353
return;
3454
}
35-
if !arg.layout.is_aggregate() && arg.layout.size.bits() <= 64 {
55+
56+
let size = arg.layout.size;
57+
if size.bits() <= 128 && contains_vector(cx, arg.layout, size) {
58+
arg.cast_to(Reg { kind: RegKind::Vector, size });
59+
return;
60+
}
61+
if !arg.layout.is_aggregate() && size.bits() <= 64 {
3662
arg.extend_integer_width_to(64);
3763
return;
3864
}
3965

4066
if arg.layout.is_single_fp_element(cx) {
41-
match arg.layout.size.bytes() {
67+
match size.bytes() {
4268
4 => arg.cast_to(Reg::f32()),
4369
8 => arg.cast_to(Reg::f64()),
4470
_ => arg.make_indirect(),
4571
}
4672
} else {
47-
match arg.layout.size.bytes() {
73+
match size.bytes() {
4874
1 => arg.cast_to(Reg::i8()),
4975
2 => arg.cast_to(Reg::i16()),
5076
4 => arg.cast_to(Reg::i32()),

‎compiler/rustc_target/src/spec/targets/s390x_unknown_linux_gnu.rs‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ pub(crate) fn target() -> Target {
66
base.endian = Endian::Big;
77
// z10 is the oldest CPU supported by LLVM
88
base.cpu = "z10".into();
9-
// FIXME: The ABI implementation in abi/call/s390x.rs is for now hard-coded to assume the no-vector
10-
// ABI. Pass the -vector feature string to LLVM to respect this assumption.
11-
base.features = "-vector".into();
129
base.max_atomic_width = Some(128);
1310
base.min_global_align = Some(16);
1411
base.stack_probes = StackProbeType::Inline;

‎compiler/rustc_target/src/spec/targets/s390x_unknown_linux_musl.rs‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@ pub(crate) fn target() -> Target {
66
base.endian = Endian::Big;
77
// z10 is the oldest CPU supported by LLVM
88
base.cpu = "z10".into();
9-
// FIXME: The ABI implementation in abi/call/s390x.rs is for now hard-coded to assume the no-vector
10-
// ABI. Pass the -vector feature string to LLVM to respect this assumption.
11-
base.features = "-vector".into();
129
base.max_atomic_width = Some(128);
1310
base.min_global_align = Some(16);
1411
base.static_position_independent_executables = true;

‎compiler/rustc_target/src/target_features.rs‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -582,6 +582,7 @@ pub fn all_rust_features() -> impl Iterator<Item = (&'static str, Stability)> {
582582
const X86_FEATURES_FOR_CORRECT_VECTOR_ABI: &'static [(u64, &'static str)] =
583583
&[(128, "sse"), (256, "avx"), (512, "avx512f")];
584584
const AARCH64_FEATURES_FOR_CORRECT_VECTOR_ABI: &'static [(u64, &'static str)] = &[(128, "neon")];
585+
const S390X_FEATURES_FOR_CORRECT_VECTOR_ABI: &'static [(u64, &'static str)] = &[(128, "vector")];
585586

586587
impl super::spec::Target {
587588
pub fn rust_target_features(&self) -> &'static [(&'static str, Stability, ImpliedFeatures)] {
@@ -608,6 +609,7 @@ impl super::spec::Target {
608609
match &*self.arch {
609610
"x86" | "x86_64" => Some(X86_FEATURES_FOR_CORRECT_VECTOR_ABI),
610611
"aarch64" => Some(AARCH64_FEATURES_FOR_CORRECT_VECTOR_ABI),
612+
"s390x" => Some(S390X_FEATURES_FOR_CORRECT_VECTOR_ABI),
611613
// FIXME: add support for non-tier1 architectures
612614
_ => None,
613615
}

‎tests/assembly/s390x-vector-abi.rs‎

Lines changed: 293 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,293 @@
1+
//@ revisions: z10 z10_vector z13 z13_no_vector
2+
// ignore-tidy-linelength
3+
//@ assembly-output: emit-asm
4+
//@ compile-flags: -O -Z merge-functions=disabled
5+
//@[z10] compile-flags: --target s390x-unknown-linux-gnu --cfg no_vector
6+
//@[z10] needs-llvm-components: systemz
7+
//@[z10_vector] compile-flags: --target s390x-unknown-linux-gnu -C target-feature=+vector
8+
//@[z10_vector] needs-llvm-components: systemz
9+
//@[z13] compile-flags: --target s390x-unknown-linux-gnu -C target-cpu=z13
10+
//@[z13] needs-llvm-components: systemz
11+
//@[z13_no_vector] compile-flags: --target s390x-unknown-linux-gnu -C target-cpu=z13 -C target-feature=-vector --cfg no_vector
12+
//@[z13_no_vector] needs-llvm-components: systemz
13+
14+
#![feature(no_core, lang_items, repr_simd, s390x_target_feature)]
15+
#![no_core]
16+
#![crate_type = "lib"]
17+
#![allow(non_camel_case_types)]
18+
19+
// Cases where vector feature is disabled are rejected.
20+
// See tests/ui/simd-abi-checks-s390x.rs for test for them.
21+
22+
#[lang = "sized"]
23+
pub trait Sized {}
24+
#[lang = "copy"]
25+
pub trait Copy {}
26+
#[lang = "freeze"]
27+
pub trait Freeze {}
28+
29+
impl<T: Copy, const N: usize> Copy for [T; N] {}
30+
31+
#[lang = "phantom_data"]
32+
pub struct PhantomData<T: ?Sized>;
33+
impl<T: ?Sized> Copy for PhantomData<T> {}
34+
35+
#[repr(simd)]
36+
pub struct i8x8([i8; 8]);
37+
#[repr(simd)]
38+
pub struct i8x16([i8; 16]);
39+
#[repr(simd)]
40+
pub struct i8x32([i8; 32]);
41+
#[repr(C)]
42+
pub struct Wrapper<T>(T);
43+
#[repr(C)]
44+
pub struct WrapperWithZst<T>(T, PhantomData<()>);
45+
#[repr(transparent)]
46+
pub struct TransparentWrapper<T>(T);
47+
48+
impl Copy for i8 {}
49+
impl Copy for i64 {}
50+
impl Copy for i8x8 {}
51+
impl Copy for i8x16 {}
52+
impl Copy for i8x32 {}
53+
impl<T: Copy> Copy for Wrapper<T> {}
54+
impl<T: Copy> Copy for WrapperWithZst<T> {}
55+
impl<T: Copy> Copy for TransparentWrapper<T> {}
56+
57+
// CHECK-LABEL: vector_ret_small:
58+
// CHECK: vlrepg %v24, 0(%r2)
59+
// CHECK-NEXT: br %r14
60+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
61+
#[no_mangle]
62+
unsafe extern "C" fn vector_ret_small(x: &i8x8) -> i8x8 {
63+
*x
64+
}
65+
// CHECK-LABEL: vector_ret:
66+
// CHECK: vl %v24, 0(%r2), 3
67+
// CHECK-NEXT: br %r14
68+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
69+
#[no_mangle]
70+
unsafe extern "C" fn vector_ret(x: &i8x16) -> i8x16 {
71+
*x
72+
}
73+
// CHECK-LABEL: vector_ret_large:
74+
// z10: vl %v0, 16(%r3), 4
75+
// z10-NEXT: vl %v1, 0(%r3), 4
76+
// z10-NEXT: vst %v0, 16(%r2), 4
77+
// z10-NEXT: vst %v1, 0(%r2), 4
78+
// z10-NEXT: br %r14
79+
// z13: vl %v0, 0(%r3), 4
80+
// z13-NEXT: vl %v1, 16(%r3), 4
81+
// z13-NEXT: vst %v1, 16(%r2), 4
82+
// z13-NEXT: vst %v0, 0(%r2), 4
83+
// z13-NEXT: br %r14
84+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
85+
#[no_mangle]
86+
unsafe extern "C" fn vector_ret_large(x: &i8x32) -> i8x32 {
87+
*x
88+
}
89+
90+
// CHECK-LABEL: vector_wrapper_ret_small:
91+
// CHECK: mvc 0(8,%r2), 0(%r3)
92+
// CHECK-NEXT: br %r14
93+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
94+
#[no_mangle]
95+
unsafe extern "C" fn vector_wrapper_ret_small(x: &Wrapper<i8x8>) -> Wrapper<i8x8> {
96+
*x
97+
}
98+
// CHECK-LABEL: vector_wrapper_ret:
99+
// CHECK: mvc 0(16,%r2), 0(%r3)
100+
// CHECK-NEXT: br %r14
101+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
102+
#[no_mangle]
103+
unsafe extern "C" fn vector_wrapper_ret(x: &Wrapper<i8x16>) -> Wrapper<i8x16> {
104+
*x
105+
}
106+
// CHECK-LABEL: vector_wrapper_ret_large:
107+
// z10: vl %v0, 16(%r3), 4
108+
// z10-NEXT: vl %v1, 0(%r3), 4
109+
// z10-NEXT: vst %v0, 16(%r2), 4
110+
// z10-NEXT: vst %v1, 0(%r2), 4
111+
// z10-NEXT: br %r14
112+
// z13: vl %v0, 16(%r3), 4
113+
// z13-NEXT: vst %v0, 16(%r2), 4
114+
// z13-NEXT: vl %v0, 0(%r3), 4
115+
// z13-NEXT: vst %v0, 0(%r2), 4
116+
// z13-NEXT: br %r14
117+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
118+
#[no_mangle]
119+
unsafe extern "C" fn vector_wrapper_ret_large(x: &Wrapper<i8x32>) -> Wrapper<i8x32> {
120+
*x
121+
}
122+
123+
// CHECK-LABEL: vector_wrapper_with_zst_ret_small:
124+
// CHECK: mvc 0(8,%r2), 0(%r3)
125+
// CHECK-NEXT: br %r14
126+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
127+
#[no_mangle]
128+
unsafe extern "C" fn vector_wrapper_with_zst_ret_small(x: &WrapperWithZst<i8x8>) -> WrapperWithZst<i8x8> {
129+
*x
130+
}
131+
// CHECK-LABEL: vector_wrapper_with_zst_ret:
132+
// CHECK: mvc 0(16,%r2), 0(%r3)
133+
// CHECK-NEXT: br %r14
134+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
135+
#[no_mangle]
136+
unsafe extern "C" fn vector_wrapper_with_zst_ret(x: &WrapperWithZst<i8x16>) -> WrapperWithZst<i8x16> {
137+
*x
138+
}
139+
// CHECK-LABEL: vector_wrapper_with_zst_ret_large:
140+
// z10: vl %v0, 16(%r3), 4
141+
// z10-NEXT: vl %v1, 0(%r3), 4
142+
// z10-NEXT: vst %v0, 16(%r2), 4
143+
// z10-NEXT: vst %v1, 0(%r2), 4
144+
// z10-NEXT: br %r14
145+
// z13: vl %v0, 16(%r3), 4
146+
// z13-NEXT: vst %v0, 16(%r2), 4
147+
// z13-NEXT: vl %v0, 0(%r3), 4
148+
// z13-NEXT: vst %v0, 0(%r2), 4
149+
// z13-NEXT: br %r14
150+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
151+
#[no_mangle]
152+
unsafe extern "C" fn vector_wrapper_with_zst_ret_large(x: &WrapperWithZst<i8x32>) -> WrapperWithZst<i8x32> {
153+
*x
154+
}
155+
156+
// CHECK-LABEL: vector_transparent_wrapper_ret_small:
157+
// CHECK: vlrepg %v24, 0(%r2)
158+
// CHECK-NEXT: br %r14
159+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
160+
#[no_mangle]
161+
unsafe extern "C" fn vector_transparent_wrapper_ret_small(
162+
x: &TransparentWrapper<i8x8>,
163+
) -> TransparentWrapper<i8x8> {
164+
*x
165+
}
166+
// CHECK-LABEL: vector_transparent_wrapper_ret:
167+
// CHECK: vl %v24, 0(%r2), 3
168+
// CHECK-NEXT: br %r14
169+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
170+
#[no_mangle]
171+
unsafe extern "C" fn vector_transparent_wrapper_ret(
172+
x: &TransparentWrapper<i8x16>,
173+
) -> TransparentWrapper<i8x16> {
174+
*x
175+
}
176+
// CHECK-LABEL: vector_transparent_wrapper_ret_large:
177+
// z10: vl %v0, 16(%r3), 4
178+
// z10-NEXT: vl %v1, 0(%r3), 4
179+
// z10-NEXT: vst %v0, 16(%r2), 4
180+
// z10-NEXT: vst %v1, 0(%r2), 4
181+
// z10-NEXT: br %r14
182+
// z13: vl %v0, 0(%r3), 4
183+
// z13-NEXT: vl %v1, 16(%r3), 4
184+
// z13-NEXT: vst %v1, 16(%r2), 4
185+
// z13-NEXT: vst %v0, 0(%r2), 4
186+
// z13-NEXT: br %r14
187+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
188+
#[no_mangle]
189+
unsafe extern "C" fn vector_transparent_wrapper_ret_large(
190+
x: &TransparentWrapper<i8x32>,
191+
) -> TransparentWrapper<i8x32> {
192+
*x
193+
}
194+
195+
// CHECK-LABEL: vector_arg_small:
196+
// CHECK: vlgvg %r2, %v24, 0
197+
// CHECK-NEXT: br %r14
198+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
199+
#[no_mangle]
200+
unsafe extern "C" fn vector_arg_small(x: i8x8) -> i64 {
201+
unsafe { *(&x as *const i8x8 as *const i64) }
202+
}
203+
// CHECK-LABEL: vector_arg:
204+
// CHECK: vlgvg %r2, %v24, 0
205+
// CHECK-NEXT: br %r14
206+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
207+
#[no_mangle]
208+
unsafe extern "C" fn vector_arg(x: i8x16) -> i64 {
209+
unsafe { *(&x as *const i8x16 as *const i64) }
210+
}
211+
// CHECK-LABEL: vector_arg_large:
212+
// CHECK: lg %r2, 0(%r2)
213+
// CHECK-NEXT: br %r14
214+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
215+
#[no_mangle]
216+
unsafe extern "C" fn vector_arg_large(x: i8x32) -> i64 {
217+
unsafe { *(&x as *const i8x32 as *const i64) }
218+
}
219+
220+
// CHECK-LABEL: vector_wrapper_arg_small:
221+
// CHECK: vlgvg %r2, %v24, 0
222+
// CHECK-NEXT: br %r14
223+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
224+
#[no_mangle]
225+
unsafe extern "C" fn vector_wrapper_arg_small(x: Wrapper<i8x8>) -> i64 {
226+
unsafe { *(&x as *const Wrapper<i8x8> as *const i64) }
227+
}
228+
// CHECK-LABEL: vector_wrapper_arg:
229+
// CHECK: vlgvg %r2, %v24, 0
230+
// CHECK-NEXT: br %r14
231+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
232+
#[no_mangle]
233+
unsafe extern "C" fn vector_wrapper_arg(x: Wrapper<i8x16>) -> i64 {
234+
unsafe { *(&x as *const Wrapper<i8x16> as *const i64) }
235+
}
236+
// CHECK-LABEL: vector_wrapper_arg_large:
237+
// CHECK: lg %r2, 0(%r2)
238+
// CHECK-NEXT: br %r14
239+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
240+
#[no_mangle]
241+
unsafe extern "C" fn vector_wrapper_arg_large(x: Wrapper<i8x32>) -> i64 {
242+
unsafe { *(&x as *const Wrapper<i8x32> as *const i64) }
243+
}
244+
245+
// CHECK-LABEL: vector_wrapper_with_zst_arg_small:
246+
// CHECK: vlgvg %r2, %v24, 0
247+
// CHECK-NEXT: br %r14
248+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
249+
#[no_mangle]
250+
unsafe extern "C" fn vector_wrapper_with_zst_arg_small(x: WrapperWithZst<i8x8>) -> i64 {
251+
unsafe { *(&x as *const WrapperWithZst<i8x8> as *const i64) }
252+
}
253+
// CHECK-LABEL: vector_wrapper_with_zst_arg:
254+
// CHECK: vlgvg %r2, %v24, 0
255+
// CHECK-NEXT: br %r14
256+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
257+
#[no_mangle]
258+
unsafe extern "C" fn vector_wrapper_with_zst_arg(x: WrapperWithZst<i8x16>) -> i64 {
259+
unsafe { *(&x as *const WrapperWithZst<i8x16> as *const i64) }
260+
}
261+
// CHECK-LABEL: vector_wrapper_with_zst_arg_large:
262+
// CHECK: lg %r2, 0(%r2)
263+
// CHECK-NEXT: br %r14
264+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
265+
#[no_mangle]
266+
unsafe extern "C" fn vector_wrapper_with_zst_arg_large(x: WrapperWithZst<i8x32>) -> i64 {
267+
unsafe { *(&x as *const WrapperWithZst<i8x32> as *const i64) }
268+
}
269+
270+
// CHECK-LABEL: vector_transparent_wrapper_arg_small:
271+
// CHECK: vlgvg %r2, %v24, 0
272+
// CHECK-NEXT: br %r14
273+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
274+
#[no_mangle]
275+
unsafe extern "C" fn vector_transparent_wrapper_arg_small(x: TransparentWrapper<i8x8>) -> i64 {
276+
unsafe { *(&x as *const TransparentWrapper<i8x8> as *const i64) }
277+
}
278+
// CHECK-LABEL: vector_transparent_wrapper_arg:
279+
// CHECK: vlgvg %r2, %v24, 0
280+
// CHECK-NEXT: br %r14
281+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
282+
#[no_mangle]
283+
unsafe extern "C" fn vector_transparent_wrapper_arg(x: TransparentWrapper<i8x16>) -> i64 {
284+
unsafe { *(&x as *const TransparentWrapper<i8x16> as *const i64) }
285+
}
286+
// CHECK-LABEL: vector_transparent_wrapper_arg_large:
287+
// CHECK: lg %r2, 0(%r2)
288+
// CHECK-NEXT: br %r14
289+
#[cfg_attr(no_vector, target_feature(enable = "vector"))]
290+
#[no_mangle]
291+
unsafe extern "C" fn vector_transparent_wrapper_arg_large(x: TransparentWrapper<i8x32>) -> i64 {
292+
unsafe { *(&x as *const TransparentWrapper<i8x32> as *const i64) }
293+
}

‎tests/ui/simd-abi-checks-s390x.rs‎

Lines changed: 174 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,174 @@
1+
//@ revisions: z10 z13_no_vector z13_soft_float
2+
//@ build-fail
3+
//@[z10] compile-flags: --target s390x-unknown-linux-gnu
4+
//@[z10] needs-llvm-components: systemz
5+
//@[z13_no_vector] compile-flags: --target s390x-unknown-linux-gnu -C target-cpu=z13 -C target-feature=-vector
6+
//@[z13_no_vector] needs-llvm-components: systemz
7+
// FIXME: +soft-float itself doesn't set -vector
8+
//@[z13_soft_float] compile-flags: --target s390x-unknown-linux-gnu -C target-cpu=z13 -C target-feature=-vector,+soft-float
9+
//@[z13_soft_float] needs-llvm-components: systemz
10+
11+
#![feature(no_core, lang_items, repr_simd, s390x_target_feature)]
12+
#![no_core]
13+
#![crate_type = "lib"]
14+
#![allow(non_camel_case_types, improper_ctypes_definitions)]
15+
#![deny(abi_unsupported_vector_types)]
16+
17+
#[lang = "sized"]
18+
pub trait Sized {}
19+
#[lang = "copy"]
20+
pub trait Copy {}
21+
#[lang = "freeze"]
22+
pub trait Freeze {}
23+
24+
impl<T: Copy, const N: usize> Copy for [T; N] {}
25+
26+
#[repr(simd)]
27+
pub struct i8x8([i8; 8]);
28+
#[repr(simd)]
29+
pub struct i8x16([i8; 16]);
30+
#[repr(simd)]
31+
pub struct i8x32([i8; 32]);
32+
#[repr(C)]
33+
pub struct Wrapper<T>(T);
34+
#[repr(transparent)]
35+
pub struct TransparentWrapper<T>(T);
36+
37+
impl Copy for i8 {}
38+
impl Copy for i64 {}
39+
impl Copy for i8x8 {}
40+
impl Copy for i8x16 {}
41+
impl Copy for i8x32 {}
42+
impl<T: Copy> Copy for Wrapper<T> {}
43+
impl<T: Copy> Copy for TransparentWrapper<T> {}
44+
45+
#[no_mangle]
46+
extern "C" fn vector_ret_small(x: &i8x8) -> i8x8 {
47+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
48+
//~^^ WARN this was previously accepted
49+
*x
50+
}
51+
#[no_mangle]
52+
extern "C" fn vector_ret(x: &i8x16) -> i8x16 {
53+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
54+
//~^^ WARN this was previously accepted
55+
*x
56+
}
57+
#[no_mangle]
58+
extern "C" fn vector_ret_large(x: &i8x32) -> i8x32 {
59+
// Ok
60+
*x
61+
}
62+
63+
#[no_mangle]
64+
#[target_feature(enable = "vector")]
65+
unsafe extern "C" fn vector_ret_target_feature_small(x: &i8x8) -> i8x8 {
66+
// Ok
67+
*x
68+
}
69+
#[no_mangle]
70+
#[target_feature(enable = "vector")]
71+
unsafe extern "C" fn vector_target_feature_ret(x: &i8x16) -> i8x16 {
72+
// Ok
73+
*x
74+
}
75+
#[no_mangle]
76+
#[target_feature(enable = "vector")]
77+
unsafe extern "C" fn vector_ret_target_feature_large(x: &i8x32) -> i8x32 {
78+
// Ok
79+
*x
80+
}
81+
82+
#[no_mangle]
83+
extern "C" fn vector_wrapper_ret_small(x: &Wrapper<i8x8>) -> Wrapper<i8x8> {
84+
// Ok
85+
*x
86+
}
87+
#[no_mangle]
88+
extern "C" fn vector_wrapper_ret(x: &Wrapper<i8x16>) -> Wrapper<i8x16> {
89+
// Ok
90+
*x
91+
}
92+
#[no_mangle]
93+
extern "C" fn vector_wrapper_ret_large(x: &Wrapper<i8x32>) -> Wrapper<i8x32> {
94+
// Ok
95+
*x
96+
}
97+
98+
#[no_mangle]
99+
extern "C" fn vector_transparent_wrapper_ret_small(
100+
x: &TransparentWrapper<i8x8>,
101+
) -> TransparentWrapper<i8x8> {
102+
//~^^^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
103+
//~^^^^ WARN this was previously accepted
104+
*x
105+
}
106+
#[no_mangle]
107+
extern "C" fn vector_transparent_wrapper_ret(
108+
x: &TransparentWrapper<i8x16>,
109+
) -> TransparentWrapper<i8x16> {
110+
//~^^^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
111+
//~^^^^ WARN this was previously accepted
112+
*x
113+
}
114+
#[no_mangle]
115+
extern "C" fn vector_transparent_wrapper_ret_large(
116+
x: &TransparentWrapper<i8x32>,
117+
) -> TransparentWrapper<i8x32> {
118+
// Ok
119+
*x
120+
}
121+
122+
#[no_mangle]
123+
extern "C" fn vector_arg_small(x: i8x8) -> i64 {
124+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
125+
//~^^ WARN this was previously accepted
126+
unsafe { *(&x as *const i8x8 as *const i64) }
127+
}
128+
#[no_mangle]
129+
extern "C" fn vector_arg(x: i8x16) -> i64 {
130+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
131+
//~^^ WARN this was previously accepted
132+
unsafe { *(&x as *const i8x16 as *const i64) }
133+
}
134+
#[no_mangle]
135+
extern "C" fn vector_arg_large(x: i8x32) -> i64 {
136+
// Ok
137+
unsafe { *(&x as *const i8x32 as *const i64) }
138+
}
139+
140+
#[no_mangle]
141+
extern "C" fn vector_wrapper_arg_small(x: Wrapper<i8x8>) -> i64 {
142+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
143+
//~^^ WARN this was previously accepted
144+
unsafe { *(&x as *const Wrapper<i8x8> as *const i64) }
145+
}
146+
#[no_mangle]
147+
extern "C" fn vector_wrapper_arg(x: Wrapper<i8x16>) -> i64 {
148+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
149+
//~^^ WARN this was previously accepted
150+
unsafe { *(&x as *const Wrapper<i8x16> as *const i64) }
151+
}
152+
#[no_mangle]
153+
extern "C" fn vector_wrapper_arg_large(x: Wrapper<i8x32>) -> i64 {
154+
// Ok
155+
unsafe { *(&x as *const Wrapper<i8x32> as *const i64) }
156+
}
157+
158+
#[no_mangle]
159+
extern "C" fn vector_transparent_wrapper_arg_small(x: TransparentWrapper<i8x8>) -> i64 {
160+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
161+
//~^^ WARN this was previously accepted
162+
unsafe { *(&x as *const TransparentWrapper<i8x8> as *const i64) }
163+
}
164+
#[no_mangle]
165+
extern "C" fn vector_transparent_wrapper_arg(x: TransparentWrapper<i8x16>) -> i64 {
166+
//~^ ERROR this function definition uses a vector type that requires the `vector` target feature, which is not enabled
167+
//~^^ WARN this was previously accepted
168+
unsafe { *(&x as *const TransparentWrapper<i8x16> as *const i64) }
169+
}
170+
#[no_mangle]
171+
extern "C" fn vector_transparent_wrapper_arg_large(x: TransparentWrapper<i8x32>) -> i64 {
172+
// Ok
173+
unsafe { *(&x as *const TransparentWrapper<i8x32> as *const i64) }
174+
}
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
2+
--> $DIR/simd-abi-checks-s390x.rs:46:1
3+
|
4+
LL | extern "C" fn vector_ret_small(x: &i8x8) -> i8x8 {
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
6+
|
7+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
8+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
9+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
10+
note: the lint level is defined here
11+
--> $DIR/simd-abi-checks-s390x.rs:15:9
12+
|
13+
LL | #![deny(abi_unsupported_vector_types)]
14+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15+
16+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
17+
--> $DIR/simd-abi-checks-s390x.rs:52:1
18+
|
19+
LL | extern "C" fn vector_ret(x: &i8x16) -> i8x16 {
20+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
21+
|
22+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
23+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
24+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
25+
26+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
27+
--> $DIR/simd-abi-checks-s390x.rs:99:1
28+
|
29+
LL | / extern "C" fn vector_transparent_wrapper_ret_small(
30+
LL | | x: &TransparentWrapper<i8x8>,
31+
LL | | ) -> TransparentWrapper<i8x8> {
32+
| |_____________________________^ function defined here
33+
|
34+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
35+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
36+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
37+
38+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
39+
--> $DIR/simd-abi-checks-s390x.rs:107:1
40+
|
41+
LL | / extern "C" fn vector_transparent_wrapper_ret(
42+
LL | | x: &TransparentWrapper<i8x16>,
43+
LL | | ) -> TransparentWrapper<i8x16> {
44+
| |______________________________^ function defined here
45+
|
46+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
47+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
48+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
49+
50+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
51+
--> $DIR/simd-abi-checks-s390x.rs:123:1
52+
|
53+
LL | extern "C" fn vector_arg_small(x: i8x8) -> i64 {
54+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
55+
|
56+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
57+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
58+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
59+
60+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
61+
--> $DIR/simd-abi-checks-s390x.rs:129:1
62+
|
63+
LL | extern "C" fn vector_arg(x: i8x16) -> i64 {
64+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
65+
|
66+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
67+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
68+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
69+
70+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
71+
--> $DIR/simd-abi-checks-s390x.rs:141:1
72+
|
73+
LL | extern "C" fn vector_wrapper_arg_small(x: Wrapper<i8x8>) -> i64 {
74+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
75+
|
76+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
77+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
78+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
79+
80+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
81+
--> $DIR/simd-abi-checks-s390x.rs:147:1
82+
|
83+
LL | extern "C" fn vector_wrapper_arg(x: Wrapper<i8x16>) -> i64 {
84+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
85+
|
86+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
87+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
88+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
89+
90+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
91+
--> $DIR/simd-abi-checks-s390x.rs:159:1
92+
|
93+
LL | extern "C" fn vector_transparent_wrapper_arg_small(x: TransparentWrapper<i8x8>) -> i64 {
94+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
95+
|
96+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
97+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
98+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
99+
100+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
101+
--> $DIR/simd-abi-checks-s390x.rs:165:1
102+
|
103+
LL | extern "C" fn vector_transparent_wrapper_arg(x: TransparentWrapper<i8x16>) -> i64 {
104+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
105+
|
106+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
107+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
108+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
109+
110+
error: aborting due to 10 previous errors
111+
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
2+
--> $DIR/simd-abi-checks-s390x.rs:46:1
3+
|
4+
LL | extern "C" fn vector_ret_small(x: &i8x8) -> i8x8 {
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
6+
|
7+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
8+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
9+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
10+
note: the lint level is defined here
11+
--> $DIR/simd-abi-checks-s390x.rs:15:9
12+
|
13+
LL | #![deny(abi_unsupported_vector_types)]
14+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15+
16+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
17+
--> $DIR/simd-abi-checks-s390x.rs:52:1
18+
|
19+
LL | extern "C" fn vector_ret(x: &i8x16) -> i8x16 {
20+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
21+
|
22+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
23+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
24+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
25+
26+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
27+
--> $DIR/simd-abi-checks-s390x.rs:99:1
28+
|
29+
LL | / extern "C" fn vector_transparent_wrapper_ret_small(
30+
LL | | x: &TransparentWrapper<i8x8>,
31+
LL | | ) -> TransparentWrapper<i8x8> {
32+
| |_____________________________^ function defined here
33+
|
34+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
35+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
36+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
37+
38+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
39+
--> $DIR/simd-abi-checks-s390x.rs:107:1
40+
|
41+
LL | / extern "C" fn vector_transparent_wrapper_ret(
42+
LL | | x: &TransparentWrapper<i8x16>,
43+
LL | | ) -> TransparentWrapper<i8x16> {
44+
| |______________________________^ function defined here
45+
|
46+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
47+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
48+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
49+
50+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
51+
--> $DIR/simd-abi-checks-s390x.rs:123:1
52+
|
53+
LL | extern "C" fn vector_arg_small(x: i8x8) -> i64 {
54+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
55+
|
56+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
57+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
58+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
59+
60+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
61+
--> $DIR/simd-abi-checks-s390x.rs:129:1
62+
|
63+
LL | extern "C" fn vector_arg(x: i8x16) -> i64 {
64+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
65+
|
66+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
67+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
68+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
69+
70+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
71+
--> $DIR/simd-abi-checks-s390x.rs:141:1
72+
|
73+
LL | extern "C" fn vector_wrapper_arg_small(x: Wrapper<i8x8>) -> i64 {
74+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
75+
|
76+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
77+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
78+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
79+
80+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
81+
--> $DIR/simd-abi-checks-s390x.rs:147:1
82+
|
83+
LL | extern "C" fn vector_wrapper_arg(x: Wrapper<i8x16>) -> i64 {
84+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
85+
|
86+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
87+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
88+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
89+
90+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
91+
--> $DIR/simd-abi-checks-s390x.rs:159:1
92+
|
93+
LL | extern "C" fn vector_transparent_wrapper_arg_small(x: TransparentWrapper<i8x8>) -> i64 {
94+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
95+
|
96+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
97+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
98+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
99+
100+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
101+
--> $DIR/simd-abi-checks-s390x.rs:165:1
102+
|
103+
LL | extern "C" fn vector_transparent_wrapper_arg(x: TransparentWrapper<i8x16>) -> i64 {
104+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
105+
|
106+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
107+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
108+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
109+
110+
error: aborting due to 10 previous errors
111+
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
2+
--> $DIR/simd-abi-checks-s390x.rs:46:1
3+
|
4+
LL | extern "C" fn vector_ret_small(x: &i8x8) -> i8x8 {
5+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
6+
|
7+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
8+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
9+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
10+
note: the lint level is defined here
11+
--> $DIR/simd-abi-checks-s390x.rs:15:9
12+
|
13+
LL | #![deny(abi_unsupported_vector_types)]
14+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
15+
16+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
17+
--> $DIR/simd-abi-checks-s390x.rs:52:1
18+
|
19+
LL | extern "C" fn vector_ret(x: &i8x16) -> i8x16 {
20+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
21+
|
22+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
23+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
24+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
25+
26+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
27+
--> $DIR/simd-abi-checks-s390x.rs:99:1
28+
|
29+
LL | / extern "C" fn vector_transparent_wrapper_ret_small(
30+
LL | | x: &TransparentWrapper<i8x8>,
31+
LL | | ) -> TransparentWrapper<i8x8> {
32+
| |_____________________________^ function defined here
33+
|
34+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
35+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
36+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
37+
38+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
39+
--> $DIR/simd-abi-checks-s390x.rs:107:1
40+
|
41+
LL | / extern "C" fn vector_transparent_wrapper_ret(
42+
LL | | x: &TransparentWrapper<i8x16>,
43+
LL | | ) -> TransparentWrapper<i8x16> {
44+
| |______________________________^ function defined here
45+
|
46+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
47+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
48+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
49+
50+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
51+
--> $DIR/simd-abi-checks-s390x.rs:123:1
52+
|
53+
LL | extern "C" fn vector_arg_small(x: i8x8) -> i64 {
54+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
55+
|
56+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
57+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
58+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
59+
60+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
61+
--> $DIR/simd-abi-checks-s390x.rs:129:1
62+
|
63+
LL | extern "C" fn vector_arg(x: i8x16) -> i64 {
64+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
65+
|
66+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
67+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
68+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
69+
70+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
71+
--> $DIR/simd-abi-checks-s390x.rs:141:1
72+
|
73+
LL | extern "C" fn vector_wrapper_arg_small(x: Wrapper<i8x8>) -> i64 {
74+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
75+
|
76+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
77+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
78+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
79+
80+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
81+
--> $DIR/simd-abi-checks-s390x.rs:147:1
82+
|
83+
LL | extern "C" fn vector_wrapper_arg(x: Wrapper<i8x16>) -> i64 {
84+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
85+
|
86+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
87+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
88+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
89+
90+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
91+
--> $DIR/simd-abi-checks-s390x.rs:159:1
92+
|
93+
LL | extern "C" fn vector_transparent_wrapper_arg_small(x: TransparentWrapper<i8x8>) -> i64 {
94+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
95+
|
96+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
97+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
98+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
99+
100+
error: ABI error: this function definition uses a vector type that requires the `vector` target feature, which is not enabled
101+
--> $DIR/simd-abi-checks-s390x.rs:165:1
102+
|
103+
LL | extern "C" fn vector_transparent_wrapper_arg(x: TransparentWrapper<i8x16>) -> i64 {
104+
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ function defined here
105+
|
106+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
107+
= note: for more information, see issue #116558 <https://github.com/rust-lang/rust/issues/116558>
108+
= help: consider enabling it globally (`-C target-feature=+vector`) or locally (`#[target_feature(enable="vector")]`)
109+
110+
error: aborting due to 10 previous errors
111+

0 commit comments

Comments
 (0)
Please sign in to comment.