• Hana Kim's avatar
    cmd/trace: don't drop sweep slice details · e57f24ab
    Hana Kim authored
    For sweep events, we used to modify the ViewerEvent returned from
    ctx.emitSlice later in order to embed more details about the sweep
    operation. The trick no longer works after the change
    https://golang.org/cl/92375 and caused a regression.
    
    ctx.emit method encodes the ViewerEvent, so any modification to the
    ViewerEvent object after ctx.emit returns will not be reflected.
    
    Refactor ctx.emitSlice, so ctx.makeSlice can be used when producing
    slices for SWEEP. ctx.emit* methods are meant to truely emit
    ViewerEvents.
    
    Fixes #27711
    
    Change-Id: I0b733ebbbfd4facd8714db0535809ec3cab0833d
    Reviewed-on: https://go-review.googlesource.com/135775Reviewed-by: 's avatarAustin Clements <austin@google.com>
    Run-TryBot: Austin Clements <austin@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    e57f24ab
Name
Last commit
Last update
..
addr2line Loading commit data...
api Loading commit data...
asm Loading commit data...
buildid Loading commit data...
cgo Loading commit data...
compile Loading commit data...
cover Loading commit data...
dist Loading commit data...
doc Loading commit data...
fix Loading commit data...
go Loading commit data...
gofmt Loading commit data...
internal Loading commit data...
link Loading commit data...
nm Loading commit data...
objdump Loading commit data...
pack Loading commit data...
pprof Loading commit data...
test2json Loading commit data...
trace Loading commit data...
vendor Loading commit data...
vet Loading commit data...