• David Crawshaw's avatar
    cmd/compile: compute second method type at runtime · f2772a49
    David Crawshaw authored
    The type information for a method includes two variants: a func
    without the receiver, and a func with the receiver as the first
    parameter. The former is used as part of the dynamic interface
    checks, but the latter is only returned as a type in the
    reflect.Method struct.
    
    Instead of computing it at compile time, construct it at run time
    with reflect.FuncOf.
    
    Using cl/20701 as a baseline,
    
    	cmd/go: -480KB, (4.4%)
    	jujud:  -5.6MB, (7.8%)
    
    For #6853.
    
    Change-Id: I1b8c73f3ab894735f53d00cb9c0b506d84d54e92
    Reviewed-on: https://go-review.googlesource.com/20709
    Run-TryBot: David Crawshaw <crawshaw@golang.org>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarIan Lance Taylor <iant@golang.org>
    f2772a49
Name
Last commit
Last update
..
all_test.go Loading commit data...
asm_386.s Loading commit data...
asm_amd64.s Loading commit data...
asm_amd64p32.s Loading commit data...
asm_arm.s Loading commit data...
asm_arm64.s Loading commit data...
asm_mips64x.s Loading commit data...
asm_ppc64x.s Loading commit data...
deepequal.go Loading commit data...
example_test.go Loading commit data...
export_test.go Loading commit data...
makefunc.go Loading commit data...
set_test.go Loading commit data...
tostring_test.go Loading commit data...
type.go Loading commit data...
value.go Loading commit data...