• Josh Bleecher Snyder's avatar
    [dev.ssa] cmd/compile/ssa: refine type equality in cse · d9a704cd
    Josh Bleecher Snyder authored
    The correct way to compare gc.Types is Eqtype,
    rather than pointer equality.
    Introduce an Equal method for ssa.Type to allow
    us to use it.
    
    In the cse pass, use a type's string to build
    the coarse partition, and then use Type.Equal
    during refinement.
    
    This lets the cse pass do a better job.
    In the ~20% of the standard library that SSA
    can compile, the number of common subexpressions
    recognized by the cse pass increases from
    27,550 to 32,199 (+17%). The number of nil checks
    eliminated increases from 75 to 115 (+50%).
    
    Change-Id: I0bdbfcf613ca6bc2ec987eb19b6b1217b51f3008
    Reviewed-on: https://go-review.googlesource.com/11451Reviewed-by: 's avatarKeith Randall <khr@golang.org>
    d9a704cd
Name
Last commit
Last update
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test 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.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...