mirror of
https://github.com/golang/go.git
synced 2025-05-27 18:31:35 +00:00
[dev.ssa] cmd/compile: make GOSSAFUNC trigger logging
I find myself always adding this in temporarily. Make it permanent. Change-Id: I1646b3930a07d0ea01840736ccd449b7fd24f06e Reviewed-on: https://go-review.googlesource.com/13141 Reviewed-by: Keith Randall <khr@golang.org>
This commit is contained in:
parent
573c791e81
commit
9495e45c80
@ -20,7 +20,7 @@ import (
|
||||
// it will never return nil, and the bool can be removed.
|
||||
func buildssa(fn *Node) (ssafn *ssa.Func, usessa bool) {
|
||||
name := fn.Func.Nname.Sym.Name
|
||||
usessa = strings.HasSuffix(name, "_ssa")
|
||||
usessa = strings.HasSuffix(name, "_ssa") || name == os.Getenv("GOSSAFUNC")
|
||||
|
||||
if usessa {
|
||||
fmt.Println("generating SSA for", name)
|
||||
@ -150,7 +150,7 @@ func buildssa(fn *Node) (ssafn *ssa.Func, usessa bool) {
|
||||
|
||||
// TODO: enable codegen more broadly once the codegen stabilizes
|
||||
// and runtime support is in (gc maps, write barriers, etc.)
|
||||
return s.f, usessa || name == os.Getenv("GOSSAFUNC") || localpkg.Name == os.Getenv("GOSSAPKG")
|
||||
return s.f, usessa || localpkg.Name == os.Getenv("GOSSAPKG")
|
||||
}
|
||||
|
||||
type state struct {
|
||||
|
Loading…
x
Reference in New Issue
Block a user