Skip to content

Commit 6936671

Browse files
mvdanmdempsky
authored andcommitted
cmd/compile: clarify adjustctxt inlining comment
The reason why adjustctxt wasn't being inlined was reported as: function too complex: cost 92 exceeds budget 80 However, after tweaking the code to be under the budget limit, we see the real blocker: non-leaf function There is little we can do about this one in particular at the moment. Create a section with funcs that will need mid-stack inlining to be inlineable, since this will likely come up again in other cases. Change-Id: I3a8eb1546b289a060ac896506a007b0496946e84 Reviewed-on: https://go-review.googlesource.com/65650 Run-TryBot: Daniel Martí <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Matthew Dempsky <[email protected]>
1 parent 7537bb7 commit 6936671

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/cmd/compile/internal/gc/inl_test.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,10 @@ func TestIntendedInlining(t *testing.T) {
2929
// be inlined.
3030
want := map[string][]string{
3131
"runtime": {
32+
// TODO(mvdan): enable these once mid-stack
33+
// inlining is available
34+
// "adjustctxt",
35+
3236
"add",
3337
"addb",
3438
"adjustpanics",
@@ -58,8 +62,6 @@ func TestIntendedInlining(t *testing.T) {
5862
"(*bmap).keys",
5963
"(*bmap).overflow",
6064
"(*waitq).enqueue",
61-
62-
//"adjustctxt", TODO(mvdan): fix and re-enable
6365
},
6466
"runtime/internal/sys": {},
6567
"unicode/utf8": {

0 commit comments

Comments
 (0)