1// asmcheck
2
3// Copyright 2022 The Go Authors. All rights reserved.
4// Use of this source code is governed by a BSD-style
5// license that can be found in the LICENSE file.
6
7package codegen
8
9func f1(x *[4]int, y *[4]int) {
10	// amd64:".*memmove"
11	*x = *y
12}
13func f2(x *[4]int, y [4]int) {
14	// amd64:-".*memmove"
15	*x = y
16}
17func f3(x *[4]int, y *[4]int) {
18	// amd64:-".*memmove"
19	t := *y
20	// amd64:-".*memmove"
21	*x = t
22}
23func f4(x *[4]int, y [4]int) {
24	// amd64:-".*memmove"
25	t := y
26	// amd64:-".*memmove"
27	*x = t
28}
29
30type T struct {
31	a [4]int
32}
33
34func f5(x, y *T) {
35	// amd64:-".*memmove"
36	x.a = y.a
37}
38func f6(x *T, y T) {
39	// amd64:-".*memmove"
40	x.a = y.a
41}
42func f7(x *T, y *[4]int) {
43	// amd64:-".*memmove"
44	x.a = *y
45}
46func f8(x *[4]int, y *T) {
47	// amd64:-".*memmove"
48	*x = y.a
49}
50
51func f9(x [][4]int, y [][4]int, i, j int) {
52	// amd64:-".*memmove"
53	x[i] = y[j]
54}
55
56func f10() []byte {
57	// amd64:-".*memmove"
58	return []byte("aReasonablyBigTestString")
59}
60