diff options
Diffstat (limited to 'src/cmd/internal/obj/ppc64/obj9.go')
| -rw-r--r-- | src/cmd/internal/obj/ppc64/obj9.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/cmd/internal/obj/ppc64/obj9.go b/src/cmd/internal/obj/ppc64/obj9.go index b6b2a8a9a7..9aa5c87d1f 100644 --- a/src/cmd/internal/obj/ppc64/obj9.go +++ b/src/cmd/internal/obj/ppc64/obj9.go @@ -1382,12 +1382,23 @@ func (c *ctxt9) stacksplit(p *obj.Prog, framesize int32) *obj.Prog { return p } +// MMA accumulator to/from instructions are slightly ambiguous since +// the argument represents both source and destination, specified as +// an accumulator. It is treated as a unary destination to simplify +// the code generation in ppc64map. +var unaryDst = map[obj.As]bool{ + AXXSETACCZ: true, + AXXMTACC: true, + AXXMFACC: true, +} + var Linkppc64 = obj.LinkArch{ Arch: sys.ArchPPC64, Init: buildop, Preprocess: preprocess, Assemble: span9, Progedit: progedit, + UnaryDst: unaryDst, DWARFRegisters: PPC64DWARFRegisters, } @@ -1397,5 +1408,6 @@ var Linkppc64le = obj.LinkArch{ Preprocess: preprocess, Assemble: span9, Progedit: progedit, + UnaryDst: unaryDst, DWARFRegisters: PPC64DWARFRegisters, } |
