]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: mark function Syms
authorAustin Clements <austin@google.com>
Thu, 1 Nov 2018 16:20:28 +0000 (12:20 -0400)
committerAustin Clements <austin@google.com>
Mon, 12 Nov 2018 20:46:50 +0000 (20:46 +0000)
commit16e6cd9a4dc499db164624a048f25e2f382ac016
treefcf2eb5fcc0c780d3ad55fab972048915c52d863
parentc5718b6b261a66aa47312037f17281d3d810c98c
cmd/compile: mark function Syms

In order to mark the obj.LSyms produced by the compiler with the
correct ABI, we need to know which types.Syms refer to function
symbols. This CL adds a flag to types.Syms to mark symbols for
functions, and sets this flag everywhere we create a PFUNC-class node,
and in the one place where we directly create function symbols without
always wrapping them in a PFUNC node (methodSym).

We'll use this information to construct obj.LSyms with correct ABI
information.

For #27539.

Change-Id: Ie3ac8bf3da013e449e78f6ca85546a055f275463
Reviewed-on: https://go-review.googlesource.com/c/147158
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: David Chase <drchase@google.com>
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/gc/alg.go
src/cmd/compile/internal/gc/dcl.go
src/cmd/compile/internal/gc/export.go
src/cmd/compile/internal/gc/iimport.go
src/cmd/compile/internal/gc/main.go
src/cmd/compile/internal/gc/ssa.go
src/cmd/compile/internal/gc/subr.go
src/cmd/compile/internal/gc/typecheck.go
src/cmd/compile/internal/gc/walk.go
src/cmd/compile/internal/types/sym.go