arch/arm
Ben Shi 7d04a2ea6b arm/armasm: Improve Plan 9 syntax decoding
The arm disassembler can not decode many instructions to
correct Plan 9 syntax.

This patch fixes 3 major issues.

1. Change memory addresses in PLD/PLI/SWP/STREX/LDREX to the correct
Plan 9 syntax (in accordance with MOVW/MOVB/MOVH). For example,
   [rx] -> (Rx)
   [rx, #imm] -> imm(Rx)
   [rx, ry, lsl #imm] -> (Rx)(Ry<<imm)

2. Apply the Plan 9 syntax naming rule to more instructions. Such as,
   VMRS -> MOVW
   VMSR -> MOVW
   XTB  -> MOVBS
   XTHU -> MOVHU
   XTH  -> MOVHS
   XTBU -> MOVBU

3. Improve FP instructions decoding.
   3.1 instruction name: VADD.F32 -> ADDF, VSUB.F64 -> SUBD, ...
   3.2 register name: S0 -> F0, D0 -> F0, S2 -> F1, D1 -> F1, ...

Many test cases are also changed.

Change-Id: I5f8ac0e82c6edec2f4bdc4db58f6bcbab40d299a
Reviewed-on: https://go-review.googlesource.com/85455
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2018-02-14 15:20:09 +00:00
..
armasm arm/armasm: Improve Plan 9 syntax decoding 2018-02-14 15:20:09 +00:00
armmap arm: move rsc.io/arm here 2015-08-27 18:02:36 +00:00
armspec arm/armspec, vendor/rsc.io/pdf: require Go 1.6+ for use of vendored packages 2016-07-15 20:53:32 +00:00
arm.csv arm: support MSR instruction in the disassembler 2017-07-15 15:20:43 +00:00