aboutsummaryrefslogtreecommitdiff
path: root/test/codegen
diff options
context:
space:
mode:
authorKeith Randall <khr@golang.org>2025-09-10 10:39:17 -0700
committerGopher Robot <gobot@golang.org>2025-09-10 11:11:11 -0700
commit80a2aae922fa64f0d37b1fc81812d2ef95c0b4e6 (patch)
tree33d8e284583b5d46424ab0b15d58e009b0be2ff1 /test/codegen
parentf327a05419860a782c81a0d57a2e8fb9c517a1d1 (diff)
downloadgo-80a2aae922fa64f0d37b1fc81812d2ef95c0b4e6.tar.xz
Revert "cmd/compile: improve stp merging for non-sequent cases"
This reverts commit 4c63d798cb947a3cdd5a5b68f254a73d83eb288f. Reason for revert: Causes miscompilations. See issue 75365. Change-Id: Icd1fcfeb23d2ec524b16eb556030f43875e1c90d Reviewed-on: https://go-review.googlesource.com/c/go/+/702455 Reviewed-by: Keith Randall <khr@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Cherry Mui <cherryyz@google.com> Auto-Submit: Keith Randall <khr@golang.org> Reviewed-by: Mark Freeman <markfreeman@google.com>
Diffstat (limited to 'test/codegen')
-rw-r--r--test/codegen/memcombine.go21
1 files changed, 2 insertions, 19 deletions
diff --git a/test/codegen/memcombine.go b/test/codegen/memcombine.go
index 9457d15f6a..fa0e902ac2 100644
--- a/test/codegen/memcombine.go
+++ b/test/codegen/memcombine.go
@@ -1053,34 +1053,17 @@ func dwstoreF32(p *struct{ a, b float32 }, x, y float32) {
}
func dwstoreBig(p *struct{ a, b, c, d, e, f int64 }, a, b, c, d, e, f int64) {
- // arm64:`STP\s\(R[0-9]+, R[0-9]+\), 16\(R[0-9]+\)`
+ // This is not perfect. We merge b+a, then d+e, then c and f have no pair.
p.c = c
- // arm64:`STP\s\(R[0-9]+, R[0-9]+\), 32\(R[0-9]+\)`
p.f = f
// arm64:`STP\s\(R[0-9]+, R[0-9]+\), \(R[0-9]+\)`
p.a = a
+ // arm64:`STP\s\(R[0-9]+, R[0-9]+\), 24\(R[0-9]+\)`
p.e = e
p.d = d
p.b = b
}
-func dwstoreUnorderedArray(p *struct{ a, b, c, d int }, a, b, c, d int) {
- // arm64:`STP\s\(R[0-9]+, R[0-9]+\), 16\(R[0-9]+\)`
- p.c = c
- p.d = d
- // arm64:`STP\s\(R[0-9]+, R[0-9]+\), \(R[0-9]+\)`
- p.a = a
- p.b = b
-}
-
-func dwstoreBigNil(p *struct{ i, j struct{ a, b, c int } }) {
- // arm64:`STP\s\(ZR, ZR\), 32\(R[0-9]+\)`
- // arm64:`STP\s\(ZR, ZR\), 16\(R[0-9]+\)`
- p.j = struct{ a, b, c int }{}
- // arm64:`STP\s\(ZR, ZR\), \(R[0-9]+\)`
- p.i = struct{ a, b, c int }{}
-}
-
func dwstoreRet() [2]int {
// arm64:"STP\t"
return [2]int{5, 6}