• Russ Cox's avatar
    runtime: new profile buffer implementation supporting label pointers · b788fd80
    Russ Cox authored
    The existing CPU profiling buffer is a slice of uintptr, but we want to
    start including profiling label data in the profiles, and those labels need
    to be pointers in order to let them describe rich information.
    
    This CL implements a new profBuf type that holds both a slice of uint64
    for data and a slice of unsafe.Pointer for profiling labels (aka tags).
    Making the runtime use these buffers will happen in followup CLs.
    
    Change-Id: I9ff16b532d8edaf4ce0cbba1098229a561834efc
    Reviewed-on: https://go-review.googlesource.com/36713
    Run-TryBot: Russ Cox <rsc@golang.org>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarAustin Clements <austin@google.com>
    b788fd80
export_test.go 5.53 KB