diff options
author | Jeremy Faller <jeremy@golang.org> | 2020-08-03 13:19:46 -0400 |
---|---|---|
committer | Jeremy Faller <jeremy@golang.org> | 2020-08-12 17:14:51 +0000 |
commit | 9ae8f71c9431d287893443fa2b7fbdb72a9b56a2 (patch) | |
tree | 6fe9e3fe2f23d14cc21d85c9e8d91541545e8485 /src/runtime/runtime2.go | |
parent | ffa9f33803c424753e384508b2dc4e5b3a83974f (diff) | |
download | go-9ae8f71c9431d287893443fa2b7fbdb72a9b56a2.tar.gz go-9ae8f71c9431d287893443fa2b7fbdb72a9b56a2.zip |
[dev.link] cmd/link: stop renumbering files for pclntab generation
Creates two new symbols: runtime.cutab, and runtime.filetab, and strips
the filenames out of runtime.pclntab_old.
All stats are for cmd/compile.
Time:
Pclntab_GC 48.2ms ± 3% 45.5ms ± 9% -5.47% (p=0.004 n=9+9)
Alloc/op:
Pclntab_GC 30.0MB ± 0% 29.5MB ± 0% -1.88% (p=0.000 n=10+10)
Allocs/op:
Pclntab_GC 90.4k ± 0% 73.1k ± 0% -19.11% (p=0.000 n=10+10)
live-B:
Pclntab_GC 29.1M ± 0% 29.2M ± 0% +0.10% (p=0.000 n=10+10)
binary sizes:
NEW: 18565600
OLD: 18532768
The size differences in the binary are caused by the increased size of
the Func objects, and (less likely) some extra alignment padding needed
as a result. This is probably the maximum increase in size we'll size
from the pclntab reworking.
Change-Id: Idd95a9b159fea46f7701cfe6506813b88257fbea
Reviewed-on: https://go-review.googlesource.com/c/go/+/246497
Run-TryBot: Jeremy Faller <jeremy@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Than McIntosh <thanm@google.com>
Reviewed-by: Austin Clements <austin@google.com>
Diffstat (limited to 'src/runtime/runtime2.go')
-rw-r--r-- | src/runtime/runtime2.go | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/runtime/runtime2.go b/src/runtime/runtime2.go index 0bddcaa789..5a79c7e6ec 100644 --- a/src/runtime/runtime2.go +++ b/src/runtime/runtime2.go @@ -804,9 +804,10 @@ type _func struct { pcfile int32 pcln int32 npcdata int32 - cuIndex uint16 // TODO(jfaller): 16 bits is never enough, make this larger. - funcID funcID // set for certain special runtime functions - nfuncdata uint8 // must be last + cuOffset uint32 // runtime.cutab offset of this function's CU + funcID funcID // set for certain special runtime functions + _ [2]byte // pad + nfuncdata uint8 // must be last } // Pseudo-Func that is returned for PCs that occur in inlined code. |