• Dave Cheney's avatar
    time: add Now()/UnixNano() malloc tests · 1e9ab9e7
    Dave Cheney authored
    The fix for issue 4403 may include more calls to time.Now().UnixNano(). I was concerned that if this function allocated it would cause additional garbage on the heap. It turns out that it doesn't, which is a nice surprise.
    
    Also add benchmark for Now().UnixNano()
    
    R=bradfitz, minux.ma
    CC=golang-dev
    https://golang.org/cl/6849097
    1e9ab9e7
time_test.go 34.8 KB