Skip to content

Commit 4eb7ceb

Browse files
committed
doc/go1.16: update runtime and compiler sections
This resolves all TODOs for the runtime and compiler and mentions several other changes. For #40700. Fixes #42892. Fixes #42894. Change-Id: I18d14cfe572baf679ecf8b0a4e82c4b866da5a04 Reviewed-on: https://go-review.googlesource.com/c/go/+/275176 Trust: Austin Clements <austin@google.com> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
1 parent bacb307 commit 4eb7ceb

File tree

1 file changed

+34
-20
lines changed

1 file changed

+34
-20
lines changed

Diff for: doc/go1.16.html

+34-20
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,17 @@ <h2 id="runtime">Runtime</h2>
286286
See the package documentation for more details.
287287
</p>
288288

289+
<p><!-- CL 254659 -->
290+
Setting the <code>GODEBUG<code> environment variable
291+
to <code>inittrace=1</code> now causes the runtime to emit a single
292+
line to standard error for each package <code>init</code>,
293+
summarizing its execution time and memory allocation. This trace can
294+
be used to find bottlenecks or regressions in Go startup
295+
performance.
296+
The <a href="/pkg/runtime/#hdr-Environment_Variables"><code>GODEBUG</code><
297+
documentation</a> describes the format.
298+
</p>
299+
289300
<p><!-- CL 267100 -->
290301
On Linux, the runtime now defaults to releasing memory to the
291302
operating system promptly (using <code>MADV_DONTNEED</code>), rather
@@ -298,10 +309,19 @@ <h2 id="runtime">Runtime</h2>
298309
variable.
299310
</p>
300311

312+
<p><!-- CL 220419, CL 271987 -->
313+
The race detector's model for channel operations now more precisely
314+
follows the <a href="/ref/mem">Go memory model</a>. As a result, it
315+
may report now races that it previously missed.
316+
</p>
317+
301318
<h2 id="compiler">Compiler</h2>
302319

303-
<p>
304-
TODO
320+
<p><!-- CL 256459, CL 264837, CL 266203, CL 256460 -->
321+
The compiler can now inline functions with
322+
non-labeled <code>for</code> loops, method values, and type
323+
switches. The inliner can also detect more indirect calls where
324+
inlining is possible.
305325
</p>
306326

307327
<h2 id="linker">Linker</h2>
@@ -762,22 +782,6 @@ <h3 id="minor_library_changes">Minor changes to the library</h3>
762782
</dd>
763783
</dl><!-- reflect -->
764784

765-
<dl id="runtime"><dt><a href="/pkg/runtime/">runtime</a></dt>
766-
<dd>
767-
<p><!-- CL 37222 -->
768-
TODO: <a href="https://golang.org/cl/37222">https://golang.org/cl/37222</a>: make stack traces of endless recursion print only top and bottom 50
769-
</p>
770-
771-
<p><!-- CL 242258 -->
772-
TODO: <a href="https://golang.org/cl/242258">https://golang.org/cl/242258</a>: add 24 byte allocation size class
773-
</p>
774-
775-
<p><!-- CL 254659 -->
776-
TODO: <a href="https://golang.org/cl/254659">https://golang.org/cl/254659</a>: implement GODEBUG=inittrace=1 support
777-
</p>
778-
</dd>
779-
</dl><!-- runtime -->
780-
781785
<dl id="runtime/debug"><dt><a href="/pkg/runtime/debug/">runtime/debug</a></dt>
782786
<dd>
783787
<p><!-- CL 249677 -->
@@ -804,12 +808,22 @@ <h3 id="minor_library_changes">Minor changes to the library</h3>
804808

805809
<dl id="syscall"><dt><a href="/pkg/syscall/">syscall</a></dt>
806810
<dd>
811+
<p><!-- CL 263271 -->
812+
<a href="/pkg/syscall/?GOOS=windows#NewCallback"><code>NewCallback</code></a>
813+
and
814+
<a href="/pkg/syscall/?GOOS=windows#NewCallbackCDecl"><code>NewCallbackCDecl</code></a>
815+
now correctly support callback functions with multiple
816+
sub-<code>uintptr</code>-sized arguments in a row. This may
817+
require changing uses of these functions to eliminate manual
818+
padding between small arguments.
819+
</p>
820+
807821
<p><!-- CL 261917 -->
808-
<a href="/pkg/syscall/#SysProcAttr"><code>SysProcAttr</code></a> on Windows has a new NoInheritHandles field that disables inheriting handles when creating a new process.
822+
<a href="/pkg/syscall/?GOOS=windows#SysProcAttr"><code>SysProcAttr</code></a> on Windows has a new NoInheritHandles field that disables inheriting handles when creating a new process.
809823
</p>
810824

811825
<p><!-- CL 269761, golang.org/issue/42584 -->
812-
<a href="/pkg/syscall/#DLLError"><code>DLLError</code></a> on Windows now has an Unwrap function for unwrapping its underlying error.
826+
<a href="/pkg/syscall/?GOOS=windows#DLLError"><code>DLLError</code></a> on Windows now has an Unwrap function for unwrapping its underlying error.
813827
</p>
814828

815829
<p><!-- CL 210639 -->

0 commit comments

Comments
 (0)