]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/internal/obj/arm: delete unnecessary code
authorBen Shi <powerman1st@163.com>
Sat, 29 Sep 2018 08:35:32 +0000 (08:35 +0000)
committerCherry Zhang <cherryyz@google.com>
Wed, 3 Oct 2018 01:05:56 +0000 (01:05 +0000)
In the arm assembler, "AMOVW" never falls into optab
case 13, so the check "if p.As == AMOVW" is useless.

Change-Id: Iec241d5b4cffb358a1477f470619dc9a6287884a
Reviewed-on: https://go-review.googlesource.com/c/138575
Run-TryBot: Ben Shi <powerman1st@163.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
src/cmd/internal/obj/arm/asm5.go

index 3427ea9161c62c0b268fb5956de90adeff771602..dd6d9265c4bf017020d3dfa8f6d64a920454aef8 100644 (file)
@@ -2007,7 +2007,7 @@ func (c *ctxt5) asmout(p *obj.Prog, o *Optab, out []uint32) {
                o2 = c.oprrr(p, p.As, int(p.Scond))
                o2 |= REGTMP & 15
                r := int(p.Reg)
-               if p.As == AMOVW || p.As == AMVN {
+               if p.As == AMVN {
                        r = 0
                } else if r == 0 {
                        r = int(p.To.Reg)