mirror of
https://github.com/golang/go.git
synced 2026-01-30 07:32:05 +03:00
test/codegen: fix a tab in comparisons.go to ensure pattern works
Fix a pattern in test/codegen/comparisons.go to use whitespace instead of a tab. The test needs a whitespace to properly fail if the regalloc change from CL686655 would be missing (in that case we would have a spill immediately after call to memequal, which is supposed to be captured by this pattern). Change-Id: I5b6fb5e861b9327c7f071660592b8ffa265e0030 Reviewed-on: https://go-review.googlesource.com/c/go/+/727620 Reviewed-by: Keith Randall <khr@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Auto-Submit: Keith Randall <khr@golang.org> Reviewed-by: Keith Randall <khr@google.com>
This commit is contained in:
committed by
Gopher Robot
parent
cd668d744f
commit
df4e08ac65
@@ -660,13 +660,13 @@ func equalVarString8(a string) bool {
|
||||
return a[:8] == b
|
||||
}
|
||||
|
||||
func equalVarStringNoSpill(a,b string) bool {
|
||||
func equalVarStringNoSpill(a, b string) bool {
|
||||
s := string("ZZZZZZZZZ")
|
||||
// arm64:".*memequal"
|
||||
memeq1 := a[:9] == s
|
||||
// arm64:-".*"
|
||||
memeq2 := s == a[:9]
|
||||
// arm64:-"MOVB\tR0,.*SP",".*memequal"
|
||||
// arm64:-"MOVB R0,.*SP",".*memequal"
|
||||
memeq3 := s == b[:9]
|
||||
return memeq1 && memeq2 && memeq3
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user