aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBalaram Makam <bmakam.qdt@qualcommdatacenter.com>2018-03-05 15:51:54 -0500
committerCherry Zhang <cherryyz@google.com>2018-03-06 18:37:19 +0000
commit0e8b7110f6db272e354c73cbf2357e2889be964d (patch)
treec20546ff2b497aafeb9ed6d8d776f4794149c2d1 /src
parent18ae5eca3b12a64a81ecc994f4e79b1c3dbbecbc (diff)
downloadgo-0e8b7110f6db272e354c73cbf2357e2889be964d.tar.xz
cmd/compile/internal/ssa: inline small memmove for arm64
This patch enables the optimization for arm64 target. Performance results on Amberwing for strconv benchmark: name old time/op new time/op delta Quote 721ns ± 0% 617ns ± 0% -14.40% (p=0.016 n=5+4) QuoteRune 118ns ± 0% 117ns ± 0% -0.85% (p=0.008 n=5+5) AppendQuote 436ns ± 2% 321ns ± 0% -26.31% (p=0.008 n=5+5) AppendQuoteRune 34.7ns ± 0% 28.4ns ± 0% -18.16% (p=0.000 n=5+4) [Geo mean] 189ns 160ns -15.41% Change-Id: I5714c474e7483d07ca338fbaf49beb4bbcc11c44 Reviewed-on: https://go-review.googlesource.com/98735 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Giovanni Bajo <rasky@develer.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src')
-rw-r--r--src/cmd/compile/internal/ssa/rewrite.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmd/compile/internal/ssa/rewrite.go b/src/cmd/compile/internal/ssa/rewrite.go
index c55685f91f..971c21554a 100644
--- a/src/cmd/compile/internal/ssa/rewrite.go
+++ b/src/cmd/compile/internal/ssa/rewrite.go
@@ -830,7 +830,7 @@ func isInlinableMemmoveSize(sz int64, c *Config) bool {
switch c.arch {
case "amd64", "amd64p32":
return sz <= 16
- case "386", "ppc64", "s390x", "ppc64le":
+ case "386", "ppc64", "s390x", "ppc64le", "arm64":
return sz <= 8
case "arm", "mips", "mips64", "mipsle", "mips64le":
return sz <= 4