Hacker News new | ask | show | jobs
by edflsafoiewq 2141 days ago
> The compiler's -json optimization logging now reports large (>= 128 byte) copies and includes explanations of escape analysis decisions.

This sounds interesting.

1 comments

I haven't found any more info about this feature. Anyone have better search skills than me?
As far as I understand, it's only about including more information in the compilers json output. But that information was already available in non-json output in previos Go versions.

To get explanations on the optimization decisions by the compiler build your package with:

    go build -gcflags="-m -m"
See also:

    go tool compile -h
    go doc cmd/compile
Thanks.