From: Vladimir Stefanovic Date: Thu, 17 Nov 2016 19:06:27 +0000 (+0100) Subject: runtime/pprof/internal/protopprof: fix TestTranslateCPUProfileWithSamples test for... X-Git-Tag: go1.8beta1~110 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=5cd6ab5b6d8232d5443f474c378f1307ce502613;p=gostls13.git runtime/pprof/internal/protopprof: fix TestTranslateCPUProfileWithSamples test for mips Change-Id: I01168a7530e18dd1098d467d0c8a330f727ba91f Reviewed-on: https://go-review.googlesource.com/33281 Reviewed-by: Brad Fitzpatrick Run-TryBot: Brad Fitzpatrick TryBot-Result: Gobot Gobot --- diff --git a/src/runtime/pprof/internal/protopprof/protopprof_test.go b/src/runtime/pprof/internal/protopprof/protopprof_test.go index ad8b04bd37..f1937b5bd0 100644 --- a/src/runtime/pprof/internal/protopprof/protopprof_test.go +++ b/src/runtime/pprof/internal/protopprof/protopprof_test.go @@ -43,10 +43,10 @@ func createProfileWithTwoSamples(t *testing.T, periodMs uintptr, count1 uintptr, // Mock the sample header produced by cpu profiler. Write a sample // period of 2000 microseconds, followed by no samples. buf := new(bytes.Buffer) - words := []uint64{0, 3, 0, uint64(periodMs), 0, uint64(count1), 2, - uint64(address1), uint64(address1 + 2), - uint64(count2), 2, uint64(address2), uint64(address2 + 2), - 0, uint64(1), 0} + words := []uintptr{0, 3, 0, uintptr(periodMs), 0, uintptr(count1), 2, + uintptr(address1), uintptr(address1 + 2), + uintptr(count2), 2, uintptr(address2), uintptr(address2 + 2), + 0, 1, 0} for _, n := range words { var err error switch unsafe.Sizeof(int(0)) {