-
Matthew Dempsky authored
Use a single *struct{} type instance rather than reconstructing one for every declared/imported interface method. Minor allocations win: name old alloc/op new alloc/op delta Template 41.8MB ± 0% 41.7MB ± 0% -0.10% (p=0.000 n=9+10) Unicode 34.2MB ± 0% 34.2MB ± 0% ~ (p=0.971 n=10+10) GoTypes 123MB ± 0% 122MB ± 0% -0.03% (p=0.000 n=9+10) Compiler 495MB ± 0% 495MB ± 0% -0.01% (p=0.000 n=10+10) name old allocs/op new allocs/op delta Template 409k ± 0% 408k ± 0% -0.13% (p=0.000 n=10+10) Unicode 354k ± 0% 354k ± 0% ~ (p=0.516 n=10+10) GoTypes 1.22M ± 0% 1.22M ± 0% -0.03% (p=0.009 n=10+10) Compiler 4.43M ± 0% 4.43M ± 0% -0.02% (p=0.000 n=10+10) Change-Id: Id3a4ca3dd09112bb96ccc982b06c9e79f661d31f Reviewed-on: https://go-review.googlesource.com/32051Reviewed-by: Robert Griesemer <gri@golang.org>
d89b70d4