• Rui Ueyama's avatar
    net: efficient text processing · f7c99f33
    Rui Ueyama authored
    Optimize IP.String, IPMask.String and ParseIP.
    
    benchmark                old ns/op    new ns/op    delta
    BenchmarkParseIP              2216         1849  -16.56%
    BenchmarkIPString             7828         2486  -68.24%
    BenchmarkIPMaskString         3872          659  -82.98%
    
    LGTM=mikioh.mikioh, dave, bradfitz
    R=golang-codereviews, mikioh.mikioh, dave, bradfitz
    CC=golang-codereviews
    https://golang.org/cl/95750043
    f7c99f33
ip_test.go 17 KB