• Hana Kim's avatar
    cmd/trace: generate jsontrace data in a streaming fashion · ee465831
    Hana Kim authored
    Update #21870
    
    The Sys went down to 4.25G from 6.2G.
    
    $ DEBUG_MEMORY_USAGE=1 go tool trace trace.out
    2018/03/07 08:49:01 Parsing trace...
    after parsing trace
     Alloc:	3385757184 Bytes
     Sys:	3661195896 Bytes
     HeapReleased:	0 Bytes
     HeapSys:	3488841728 Bytes
     HeapInUse:	3426516992 Bytes
     HeapAlloc:	3385757184 Bytes
    Enter to continue...
    2018/03/07 08:49:18 Splitting trace...
    after spliting trace
     Alloc:	2352071904 Bytes
     Sys:	4243825464 Bytes
     HeapReleased:	0 Bytes
     HeapSys:	4025712640 Bytes
     HeapInUse:	2377703424 Bytes
     HeapAlloc:	2352071904 Bytes
    Enter to continue...
    after httpJsonTrace
     Alloc:	3228697832 Bytes
     Sys:	4250379064 Bytes
     HeapReleased:	0 Bytes
     HeapSys:	4025647104 Bytes
     HeapInUse:	3260014592 Bytes
     HeapAlloc:	3228697832 Bytes
    
    Change-Id: I546f26bdbc68b1e58f1af1235a0e299dc0ff115e
    Reviewed-on: https://go-review.googlesource.com/92375
    Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com>
    Reviewed-by: 's avatarPeter Weinberger <pjw@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    ee465831
trace_unix_test.go 2.35 KB