We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b22c152 commit 13eec69Copy full SHA for 13eec69
1 file changed
tests/codegen/move-operands.rs
@@ -0,0 +1,12 @@
1
+// compile-flags: -C no-prepopulate-passes -Zmir-enable-passes=+DestinationPropagation
2
+
3
+#![crate_type = "lib"]
4
5
+type T = [u8; 256];
6
7
+#[no_mangle]
8
+pub fn f(a: T, b: fn(_: T, _: T)) {
9
+ // CHECK: call void @llvm.memcpy.{{.*}}({{i8\*|ptr}} align 1 %{{.*}}, {{i8\*|ptr}} align 1 %{{.*}}, {{.*}} 256, i1 false)
10
+ // CHECK-NOT: call void @llvm.memcpy.{{.*}}({{i8\*|ptr}} align 1 %{{.*}}, {{i8\*|ptr}} align 1 %{{.*}}, {{.*}} 256, i1 false)
11
+ b(a, a)
12
+}
0 commit comments