• Todd Neal's avatar
    http2/hpack: move initialization to a static table · c9b681d3
    Todd Neal authored
    This shrinks a binary that just does an http.ListenAndServe by about
    90kb due to using less code for the static array.
    
     syms
     delta   name                                                old-size  new-size  pct-difference
    -54206   vendor/golang_org/x/net/http2/hpack.newStaticTable  55233     1027      -98.14%
    -4744    runtime.pclntab                                     1041055   1036311   -0.46%
    -204     runtime.findfunctab                                 10675     10471     -1.91%
    8        runtime.typelink                                    9852      9860      0.08%
    41       runtime.gcbss                                       869       910       4.72%
    11711    vendor/golang_org/x/net/http2/hpack.init            572       12283     2047.38%
    
     sections
     delta   name             old-size  new-size  pct-difference
    -41888   .text            2185840   2143952   -1.92%
    -37644   .rodata          842131    804487    -4.47%
    -4744    .gopclntab       1041055   1036311   -0.46%
    -3343    .debug_info      981995    978652    -0.34%
    -2931    .debug_line      291295    288364    -1.01%
    8        .typelink        9852      9860      0.08%
    59       .debug_pubnames  81986     82045     0.07%
    96       .symtab          186312    186408    0.05%
    113      .debug_pubtypes  137500    137613    0.08%
    128      .debug_frame     219140    219268    0.06%
    220      .strtab          217109    217329    0.10%
    2464     .bss             127752    130216    1.93%
    
    Updates golang/go#6853
    
    Change-Id: I3383e63300585539507b75faac1072264d8f37e7
    Reviewed-on: https://go-review.googlesource.com/43090Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
    Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    c9b681d3
Name
Last commit
Last update
bpf Loading commit data...
context Loading commit data...
dict Loading commit data...
dns/dnsmessage Loading commit data...
html Loading commit data...
http2 Loading commit data...
icmp Loading commit data...
idna Loading commit data...
internal Loading commit data...
ipv4 Loading commit data...
ipv6 Loading commit data...
lex/httplex Loading commit data...
lif Loading commit data...
nettest Loading commit data...
netutil Loading commit data...
proxy Loading commit data...
publicsuffix Loading commit data...
route Loading commit data...
trace Loading commit data...
webdav Loading commit data...
websocket Loading commit data...
xsrftoken Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README Loading commit data...
codereview.cfg Loading commit data...