mirror of
https://github.com/golang/go.git
synced 2025-05-05 15:43:04 +00:00
cmd/compile: update GOSSAFUNC doc for printing CFG
Updates #30074 Change-Id: I160124afb65849c624a225d384c35313723f9f30 Reviewed-on: https://go-review.googlesource.com/c/go/+/661415 Reviewed-by: Keith Randall <khr@google.com> Auto-Submit: Junyang Shao <shaojunyang@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Keith Randall <khr@golang.org>
This commit is contained in:
parent
a645bc5eb9
commit
b17a99d6fc
@ -206,6 +206,16 @@ name, e.g.
|
|||||||
This will match any function named "Foo" within a package whose final
|
This will match any function named "Foo" within a package whose final
|
||||||
suffix is "blah" (e.g. something/blah.Foo, anotherthing/extra/blah.Foo).
|
suffix is "blah" (e.g. something/blah.Foo, anotherthing/extra/blah.Foo).
|
||||||
|
|
||||||
|
The users may also print the Control Flow Graph(CFG) by specifying in
|
||||||
|
`GOSSAFUNC` value in the following format:
|
||||||
|
|
||||||
|
GOSSAFUNC="$FunctionName:$PassName1,$PassName2,..." go build
|
||||||
|
|
||||||
|
For example, the following command will print SSA with CFGs attached to the
|
||||||
|
`sccp` and `generic deadcode` pass columns:
|
||||||
|
|
||||||
|
GOSSAFUNC="blah.Foo:sccp,generic deadcode" go build
|
||||||
|
|
||||||
If non-HTML dumps are needed, append a "+" to the GOSSAFUNC value
|
If non-HTML dumps are needed, append a "+" to the GOSSAFUNC value
|
||||||
and dumps will be written to stdout:
|
and dumps will be written to stdout:
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user