diff --git a/src/cmd/compile/internal/amd64/cgen.go b/src/cmd/compile/internal/amd64/cgen.go index dc1a9f3beb..4b00003018 100644 --- a/src/cmd/compile/internal/amd64/cgen.go +++ b/src/cmd/compile/internal/amd64/cgen.go @@ -80,7 +80,7 @@ func blockcopy(n, ns *gc.Node, osrc, odst, w int64) { gins(x86.ACLD, nil, nil) } else { // normal direction - if q > 128 || (gc.Nacl && q >= 4) { + if q > 128 || (gc.Nacl && q >= 4) || (obj.Getgoos() == "plan9" && q >= 4) { gconreg(movptr, q, x86.REG_CX) gins(x86.AREP, nil, nil) // repeat gins(x86.AMOVSQ, nil, nil) // MOVQ *(SI)+,*(DI)+