aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfanzha02 <fannie.zhang@arm.com>2020-06-03 10:33:03 +0800
committerCherry Zhang <cherryyz@google.com>2020-06-03 14:51:34 +0000
commit5aaeda19c1876ecec85406726b544ac49c8f799b (patch)
tree0e367c7f347b59908fbed6ebc43d92c6d6093492
parent58f017bcea3d2f3dbb898ba175fe09beb32b4eb6 (diff)
downloadgo-5aaeda19c1876ecec85406726b544ac49c8f799b.tar.gz
go-5aaeda19c1876ecec85406726b544ac49c8f799b.zip
cmd/internal/obj/arm64: fix typos in document
The current document mismatches Go syntax loads a signed-byte instruction "MOVB" with GNU syntax loads an 64bit double-word instruction "ldr". This is just a typo in the document, the assembler has the correct encoding. This patch fix this error. Fixes #39367 Change-Id: Idb8f65ca540514ee5bc8f07073e756838710ba93 Reviewed-on: https://go-review.googlesource.com/c/go/+/236217 Reviewed-by: Cherry Zhang <cherryyz@google.com>
-rw-r--r--src/cmd/internal/obj/arm64/doc.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cmd/internal/obj/arm64/doc.go b/src/cmd/internal/obj/arm64/doc.go
index d66e6f85e6..7515217544 100644
--- a/src/cmd/internal/obj/arm64/doc.go
+++ b/src/cmd/internal/obj/arm64/doc.go
@@ -22,7 +22,8 @@ using different register names.
Examples:
MOVD.P -8(R10), R8 <=> ldr x8, [x10],#-8
- MOVB.W 16(R16), R10 <=> ldr x10, [x16,#16]!
+ MOVB.W 16(R16), R10 <=> ldrsb x10, [x16,#16]!
+ MOVBU.W 16(R16), R10 <=> ldrb x10, [x16,#16]!
3. Go uses a series of MOV instructions as load and store.