]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/internal/obj/mips: use r instead of p.Reg in call to OP_IRR
authorLeon Klingele <git@leonklingele.de>
Sun, 3 Mar 2019 16:42:08 +0000 (16:42 +0000)
committerCherry Zhang <cherryyz@google.com>
Sun, 3 Mar 2019 17:04:38 +0000 (17:04 +0000)
Change-Id: Id77764ed2d693e632e2a7b4e4638c17e0caf2276
GitHub-Last-Rev: 9ebe28252086ddcd530905eb9cf50b4a66413291
GitHub-Pull-Request: golang/go#30003
Reviewed-on: https://go-review.googlesource.com/c/160427
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>

src/cmd/internal/obj/mips/asm0.go

index e4004be98d70c7cf4d6e8cb938790400cc6ea175..458e071e4767e20102429a150840152a70f311f2 100644 (file)
@@ -1275,7 +1275,7 @@ func (c *ctxt0) asmout(p *obj.Prog, o *Optab, out []uint32) {
                        r = REGZERO
                }
                /* only use 10 bits of trap code */
-               o1 = OP_IRR(c.opirr(p.As), (uint32(v)&0x3FF)<<6, uint32(p.Reg), uint32(p.To.Reg))
+               o1 = OP_IRR(c.opirr(p.As), (uint32(v)&0x3FF)<<6, uint32(r), uint32(p.To.Reg))
 
        case 16: /* sll $c,[r1],r2 */
                v := c.regoff(&p.From)