]> git.lizzy.rs Git - rust.git/blobdiff - src/test/codegen/stores.rs
Add #[rustc_no_mir] to make tests pass with -Z orbit.
[rust.git] / src / test / codegen / stores.rs
index 46e4c5f341be86c9d395c780b8c02b6e051b3913..f849a6c9b18b847b0ec491c51331484e8feccb5c 100644 (file)
@@ -11,6 +11,7 @@
 // compile-flags: -C no-prepopulate-passes
 
 #![crate_type = "lib"]
+#![feature(rustc_attrs)]
 
 pub struct Bytes {
   a: u8,
@@ -23,6 +24,7 @@ pub struct Bytes {
 // The array is stored as i32, but its alignment is lower, go with 1 byte to avoid target
 // dependent alignment
 #[no_mangle]
+#[rustc_no_mir] // FIXME #27840 MIR has different codegen.
 pub fn small_array_alignment(x: &mut [i8; 4], y: [i8; 4]) {
 // CHECK: [[VAR:%[0-9]+]] = bitcast [4 x i8]* %y to i32*
 // CHECK: store i32 %{{.*}}, i32* [[VAR]], align 1
@@ -33,6 +35,7 @@ pub struct Bytes {
 // The struct is stored as i32, but its alignment is lower, go with 1 byte to avoid target
 // dependent alignment
 #[no_mangle]
+#[rustc_no_mir] // FIXME #27840 MIR has different codegen.
 pub fn small_struct_alignment(x: &mut Bytes, y: Bytes) {
 // CHECK: [[VAR:%[0-9]+]] = bitcast %Bytes* %y to i32*
 // CHECK: store i32 %{{.*}}, i32* [[VAR]], align 1