diff options
author | David Chase <drchase@google.com> | 2021-02-04 16:42:35 -0500 |
---|---|---|
committer | David Chase <drchase@google.com> | 2021-02-26 02:52:33 +0000 |
commit | e25040d16288563c89cead5e8da8d3b9c74ab655 (patch) | |
tree | 4e57425c9764cf01ac69447f06d1bb52f07d9e46 /src/cmd/compile/internal/ssa/location.go | |
parent | 9a555fc24c318bf1b07bdc07d5c02e372681e401 (diff) | |
download | go-e25040d16288563c89cead5e8da8d3b9c74ab655.tar.gz go-e25040d16288563c89cead5e8da8d3b9c74ab655.zip |
cmd/compile: change StaticCall to return a "Results"
StaticLECall (multiple value in +mem, multiple value result +mem) ->
StaticCall (multiple ergister value in +mem,
multiple register-sized-value result +mem) ->
ARCH CallStatic (multiple ergister value in +mem,
multiple register-sized-value result +mem)
But the architecture-dependent stuff is indifferent to whether
it is mem->mem or (mem)->(mem) until Prog generation.
Deal with OpSelectN -> Prog in ssagen/ssa.go, others, as they
appear.
For #40724.
Change-Id: I1d0436f6371054f1881862641d8e7e418e4a6a16
Reviewed-on: https://go-review.googlesource.com/c/go/+/293391
Trust: David Chase <drchase@google.com>
Run-TryBot: David Chase <drchase@google.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Diffstat (limited to 'src/cmd/compile/internal/ssa/location.go')
-rw-r--r-- | src/cmd/compile/internal/ssa/location.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/cmd/compile/internal/ssa/location.go b/src/cmd/compile/internal/ssa/location.go index 4cd0ac8d77..af0a913d17 100644 --- a/src/cmd/compile/internal/ssa/location.go +++ b/src/cmd/compile/internal/ssa/location.go @@ -88,6 +88,20 @@ func (t LocPair) String() string { return fmt.Sprintf("<%s,%s>", n0, n1) } +type LocResults []Location + +func (t LocResults) String() string { + s := "<" + a := "" + for _, r := range t { + a += s + s = "," + a += r.String() + } + a += ">" + return a +} + type ArgPair struct { reg *Register mem LocalSlot |