• Josh Bleecher Snyder's avatar
    runtime: iterate over set bits in adjustpointers · 5af0b28a
    Josh Bleecher Snyder authored
    There are several things combined in this change.
    
    First, eliminate the gobitvector type in favor
    of adding a ptrbit method to bitvector.
    In non-performance-critical code, use that method.
    In performance critical code, though, load the bitvector data
    one byte at a time and iterate only over set bits.
    To support that, add and use sys.Ctz8.
    
    name                old time/op  new time/op  delta
    StackCopyPtr-8      81.8ms ± 5%  78.9ms ± 3%   -3.58%  (p=0.000 n=97+96)
    StackCopy-8         65.9ms ± 3%  62.8ms ± 3%   -4.67%  (p=0.000 n=96+92)
    StackCopyNoCache-8   105ms ± 3%   102ms ± 3%   -3.38%  (p=0.000 n=96+95)
    
    Change-Id: I00b80f45612708bd440b1a411a57fa6dfa24aa74
    Reviewed-on: https://go-review.googlesource.com/109716
    Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarAustin Clements <austin@google.com>
    5af0b28a
Name
Last commit
Last update
..
arch.go Loading commit data...
arch_386.go Loading commit data...
arch_amd64.go Loading commit data...
arch_amd64p32.go Loading commit data...
arch_arm.go Loading commit data...
arch_arm64.go Loading commit data...
arch_mips.go Loading commit data...
arch_mips64.go Loading commit data...
arch_mips64le.go Loading commit data...
arch_mipsle.go Loading commit data...
arch_ppc64.go Loading commit data...
arch_ppc64le.go Loading commit data...
arch_s390x.go Loading commit data...
gengoos.go Loading commit data...
intrinsics.go Loading commit data...
intrinsics_386.s Loading commit data...
intrinsics_stubs.go Loading commit data...
intrinsics_test.go Loading commit data...
stubs.go Loading commit data...
sys.go Loading commit data...
zgoarch_386.go Loading commit data...
zgoarch_amd64.go Loading commit data...
zgoarch_amd64p32.go Loading commit data...
zgoarch_arm.go Loading commit data...
zgoarch_arm64.go Loading commit data...
zgoarch_arm64be.go Loading commit data...
zgoarch_armbe.go Loading commit data...
zgoarch_mips.go Loading commit data...
zgoarch_mips64.go Loading commit data...
zgoarch_mips64le.go Loading commit data...
zgoarch_mips64p32.go Loading commit data...
zgoarch_mips64p32le.go Loading commit data...
zgoarch_mipsle.go Loading commit data...
zgoarch_ppc.go Loading commit data...
zgoarch_ppc64.go Loading commit data...
zgoarch_ppc64le.go Loading commit data...
zgoarch_riscv.go Loading commit data...
zgoarch_riscv64.go Loading commit data...
zgoarch_s390.go Loading commit data...
zgoarch_s390x.go Loading commit data...
zgoarch_sparc.go Loading commit data...
zgoarch_sparc64.go Loading commit data...
zgoarch_wasm.go Loading commit data...
zgoos_android.go Loading commit data...
zgoos_darwin.go Loading commit data...
zgoos_dragonfly.go Loading commit data...
zgoos_freebsd.go Loading commit data...
zgoos_js.go Loading commit data...
zgoos_linux.go Loading commit data...
zgoos_nacl.go Loading commit data...
zgoos_netbsd.go Loading commit data...
zgoos_openbsd.go Loading commit data...
zgoos_plan9.go Loading commit data...
zgoos_solaris.go Loading commit data...
zgoos_windows.go Loading commit data...
zgoos_zos.go Loading commit data...