• Matthew Dempsky's avatar
    cmd/compile: stop adding implicit OKEY nodes · bba1ac4f
    Matthew Dempsky authored
    Keys are uncommon in array and slice literals, and normalizing
    OARRAYLIT and OSLICELIT nodes to always use OKEY ends up not reducing
    complexity much. Instead, only create OKEY nodes to represent explicit
    keys, and recalculate implicit keys when/where necessary.
    
    Fixes #15350.
    
    name       old time/op     new time/op     delta
    Template       299ms ± 9%      299ms ±12%    ~           (p=0.694 n=28+30)
    Unicode        165ms ± 7%      162ms ± 9%    ~           (p=0.084 n=27+27)
    GoTypes        950ms ± 9%      963ms ± 5%    ~           (p=0.301 n=30+29)
    Compiler       4.23s ± 7%      4.17s ± 7%    ~           (p=0.057 n=29+27)
    
    name       old user-ns/op  new user-ns/op  delta
    Template        389M ±15%       400M ±12%    ~           (p=0.202 n=30+29)
    Unicode         246M ±21%       232M ±22%  -5.76%        (p=0.006 n=28+29)
    GoTypes        1.34G ± 8%      1.34G ± 7%    ~           (p=0.775 n=28+30)
    Compiler       5.91G ± 6%      5.87G ± 7%    ~           (p=0.298 n=28+29)
    
    name       old alloc/op    new alloc/op    delta
    Template      41.2MB ± 0%     41.2MB ± 0%    ~           (p=0.085 n=30+30)
    Unicode       34.0MB ± 0%     31.5MB ± 0%  -7.28%        (p=0.000 n=30+29)
    GoTypes        121MB ± 0%      121MB ± 0%    ~           (p=0.657 n=30+30)
    Compiler       511MB ± 0%      511MB ± 0%  -0.01%        (p=0.001 n=29+29)
    
    name       old allocs/op   new allocs/op   delta
    Template        390k ± 0%       390k ± 0%    ~           (p=0.225 n=30+29)
    Unicode         318k ± 0%       293k ± 0%  -8.03%        (p=0.000 n=30+29)
    GoTypes        1.16M ± 0%      1.16M ± 0%    ~           (p=0.745 n=30+30)
    Compiler       4.35M ± 0%      4.35M ± 0%    ~           (p=0.105 n=30+30)
    
    Change-Id: I6310739a0bfdb54f1ab8a460b2c03615ad1ff5bc
    Reviewed-on: https://go-review.googlesource.com/32221Reviewed-by: 's avatarJosh Bleecher Snyder <josharian@gmail.com>
    Run-TryBot: Matthew Dempsky <mdempsky@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    bba1ac4f
Name
Last commit
Last update
..
archive Loading commit data...
bufio Loading commit data...
builtin Loading commit data...
bytes Loading commit data...
cmd Loading commit data...
compress Loading commit data...
container Loading commit data...
context Loading commit data...
crypto Loading commit data...
database/sql Loading commit data...
debug Loading commit data...
encoding Loading commit data...
errors Loading commit data...
expvar Loading commit data...
flag Loading commit data...
fmt Loading commit data...
go Loading commit data...
hash Loading commit data...
html Loading commit data...
image Loading commit data...
index/suffixarray Loading commit data...
internal Loading commit data...
io Loading commit data...
log Loading commit data...
math Loading commit data...
mime Loading commit data...
net Loading commit data...
os Loading commit data...
path Loading commit data...
plugin Loading commit data...
reflect Loading commit data...
regexp Loading commit data...
runtime Loading commit data...
sort Loading commit data...
strconv Loading commit data...
strings Loading commit data...
sync Loading commit data...
syscall Loading commit data...
testing Loading commit data...
text Loading commit data...
time Loading commit data...
unicode Loading commit data...
unsafe Loading commit data...
vendor/golang_org/x Loading commit data...
Make.dist Loading commit data...
all.bash Loading commit data...
all.bat Loading commit data...
all.rc Loading commit data...
androidtest.bash Loading commit data...
bootstrap.bash Loading commit data...
buildall.bash Loading commit data...
clean.bash Loading commit data...
clean.bat Loading commit data...
clean.rc Loading commit data...
cmp.bash Loading commit data...
iostest.bash Loading commit data...
make.bash Loading commit data...
make.bat Loading commit data...
make.rc Loading commit data...
naclmake.bash Loading commit data...
nacltest.bash Loading commit data...
race.bash Loading commit data...
race.bat Loading commit data...
run.bash Loading commit data...
run.bat Loading commit data...
run.rc Loading commit data...