diff options
Diffstat (limited to 'test/codegen')
| -rw-r--r-- | test/codegen/issue70409.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/test/codegen/issue70409.go b/test/codegen/issue70409.go new file mode 100644 index 0000000000..bfb4560582 --- /dev/null +++ b/test/codegen/issue70409.go @@ -0,0 +1,20 @@ +// asmcheck -gcflags=-d=ssa/check/on + +// Copyright 2024 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package codegen + +// amd64:-"MOVQ" +func foo(v uint64) (b [8]byte) { + b[0] = byte(v) + b[1] = byte(v >> 8) + b[2] = byte(v >> 16) + b[3] = byte(v >> 24) + b[4] = byte(v >> 32) + b[5] = byte(v >> 40) + b[6] = byte(v >> 48) + b[7] = byte(v >> 56) + return b +} |
