]> Cypherpunks repositories - gostls13.git/commit
cmd/asm: restore supporting of *1 scaling on ARM64
authorCherry Mui <cherryyz@google.com>
Tue, 15 Jun 2021 16:47:57 +0000 (12:47 -0400)
committerCherry Mui <cherryyz@google.com>
Wed, 16 Jun 2021 14:23:50 +0000 (14:23 +0000)
commita6a853f94cf00d8f581d0e6fbcc28898e39557b2
tree8525e8279a3a069c0eb59d206cf2a2f4342ff39b
parent785a8f677fbba9432ee67b14d41004ba7fd35ddb
cmd/asm: restore supporting of *1 scaling on ARM64

On ARM64, instruction like "MOVD (R1)(R2*1), R3" is accepted and
assembles correctly with Go 1.16, but errors out on tip with
"arm64 doesn't support scaled register format", since CL 289589.

"MOVD (R1)(R2), R3" is the preferred form. But the *1 form works
before and assembles correctly. Keep supporting it.

Fixes #46766.

Change-Id: I0f7fd71fa87ea698919a936b6c68aa5a91afd486
Reviewed-on: https://go-review.googlesource.com/c/go/+/328229
Trust: Cherry Mui <cherryyz@google.com>
Trust: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: eric fang <eric.fang@arm.com>
src/cmd/asm/internal/asm/parse.go
src/cmd/asm/internal/asm/testdata/arm64.s