Revert "Revert "Fix benchmark alignment""

This reverts commit b8e6bd45be.
This commit is contained in:
Miek Gieben 2014-01-29 07:52:23 +00:00
parent f2f9d43da5
commit 509a6ff9e2
2 changed files with 5 additions and 3 deletions

View File

@ -242,7 +242,8 @@ func TestMsgLenTest(t *testing.T) {
}
}
func BenchmarkMsgLen(b *testing.B) {
// Padded to fix alignment
func BenchmarkMsgLen____(b *testing.B) {
b.StopTimer()
makeMsg := func(question string, ans, ns, e []RR) *Msg {
msg := new(Msg)

View File

@ -65,7 +65,8 @@ func TestServing(t *testing.T) {
}
}
func BenchmarkServing(b *testing.B) {
// Padded to fix alignment
func BenchmarkServe____(b *testing.B) {
b.StopTimer()
HandleFunc("miek.nl.", HelloServer)
a := runtime.GOMAXPROCS(4)
@ -92,7 +93,7 @@ func HelloServerCompress(w ResponseWriter, req *Msg) {
w.WriteMsg(m)
}
func BenchmarkServingCompress(b *testing.B) {
func BenchmarkServeCompress(b *testing.B) {
b.StopTimer()
HandleFunc("miek.nl.", HelloServerCompress)
a := runtime.GOMAXPROCS(4)