mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
Update instructions to match what seems to be the historical practice: to generate canned traces when a version is finalized, rather than waiting until it is superseded. Follow rename of trace-internal tests from "Span" to "Region". Update the net/http test invocation to match the apparent intent and the actual http_1_5_good behavior (about 7ms of total run time and trace file size under 50kB). Change-Id: Ifd4c85882159478852e0b8f0d771b6f16b8f3c1b Reviewed-on: https://go-review.googlesource.com/c/go/+/413776 Run-TryBot: Rhys Hiltner <rhys@justin.tv> Reviewed-by: Carlos Amedee <carlos@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Michael Pratt <mpratt@google.com>
20 lines
794 B
Bash
Executable file
20 lines
794 B
Bash
Executable file
#!/usr/bin/env bash
|
|
# Copyright 2016 The Go Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style
|
|
# license that can be found in the LICENSE file.
|
|
|
|
# mkcanned.bash creates canned traces for the trace test suite using
|
|
# the current Go version.
|
|
|
|
set -e
|
|
|
|
if [ $# != 1 ]; then
|
|
echo "usage: $0 <label>" >&2
|
|
exit 1
|
|
fi
|
|
|
|
go test -run '^$' -bench ClientServerParallel4 -benchtime 10x -trace "testdata/http_$1_good" net/http
|
|
go test -run 'TraceStress$|TraceStressStartStop$|TestUserTaskRegion$' runtime/trace -savetraces
|
|
mv ../../runtime/trace/TestTraceStress.trace "testdata/stress_$1_good"
|
|
mv ../../runtime/trace/TestTraceStressStartStop.trace "testdata/stress_start_stop_$1_good"
|
|
mv ../../runtime/trace/TestUserTaskRegion.trace "testdata/user_task_region_$1_good"
|