aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/internal/obj/objfile.go
diff options
context:
space:
mode:
authorKeith Randall <khr@golang.org>2016-02-24 09:53:27 -0800
committerKeith Randall <khr@golang.org>2016-02-24 18:52:28 +0000
commitf388b58540c2cc401dfa79e3d7b6a1846ac9a59f (patch)
treecb0b4157af02d7e60887fe8401e7a73a945df756 /src/cmd/internal/obj/objfile.go
parent45c2e38b37e40c3b6bdc508065edce0643f79110 (diff)
downloadgo-f388b58540c2cc401dfa79e3d7b6a1846ac9a59f.tar.xz
cmd/compile: reuseable cache of Prog structs
Reuseable cache of Prog entries. Improves compiler speed by ~10%. Update #13646 Change-Id: I01bd8606540d989ea8b8ba5131d1275ba380d976 Reviewed-on: https://go-review.googlesource.com/19868 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd/internal/obj/objfile.go')
-rw-r--r--src/cmd/internal/obj/objfile.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cmd/internal/obj/objfile.go b/src/cmd/internal/obj/objfile.go
index 3dc5152f54..2d5c82376b 100644
--- a/src/cmd/internal/obj/objfile.go
+++ b/src/cmd/internal/obj/objfile.go
@@ -318,6 +318,7 @@ func Flushplist(ctxt *Link) {
ctxt.Plist = nil
ctxt.Plast = nil
ctxt.Curp = nil
+ ctxt.freeProgs()
}
func Writeobjfile(ctxt *Link, b *Biobuf) {