Skip to content

Commit

Permalink
Update for Go 1.2.1 vs Go 1.3beta1
Browse files Browse the repository at this point in the history
  • Loading branch information
davecheney committed May 3, 2014
1 parent 49c8d65 commit 19bdd20
Show file tree
Hide file tree
Showing 20 changed files with 255 additions and 3,773 deletions.
18 changes: 11 additions & 7 deletions Makefile
Expand Up @@ -2,8 +2,8 @@ TOP := $(shell pwd)
WORK := $(TOP)/work

# set these two values to the tags (or revisions) you wish to compare
OLD := go1.1.2
NEW := go1.2
OLD := go1.2.1
NEW := f8b50ad4cac4

GO_CHECKOUT=$(WORK)/go
GO_OLD_ROOT=$(WORK)/$(OLD)
Expand All @@ -16,17 +16,19 @@ GO1_BENCH=$(GO_NEW_ROOT)/test/bench/go1
# uncomment to benchmark with gccgo
# TESTFLAGS=-compiler=gccgo

BENCHCMP=$(GO_CHECKOUT)/misc/benchcmp
all: bench

# setup our benchmarking environment
GOPATH=$(TOP)
export GOPATH
unexport GOROOT GOBIN

BENCHCMP=$(GO_OLD_ROOT)/misc/benchcmp

bench: go1 runtime http floats cipher megajson snappy
extra: bench bytes strings goquery

go1: $(WORK)/go1-$(OLD).txt $(WORK)/go1-$(NEW).txt
go1: $(WORK)/go1-$(OLD).txt $(WORK)/go1-$(NEW).txt
@echo "# go1"
@$(BENCHCMP) $^

Expand Down Expand Up @@ -95,7 +97,7 @@ $(GO1_BENCH): $(GO_NEW_ROOT)
$(WORK)/go1-$(OLD).txt: $(GO_OLD_BIN) $(GO1_BENCH)
cd $(GO1_BENCH) && $(GO_OLD_BIN) test $(TESTFLAGS) -bench=. > $@

$(WORK)/go1-$(NEW).txt: $(GO_NEW_BIN) $(GO1_BENCH)
$(WORK)/go1-$(NEW).txt: $(GO_NEW_BIN) $(GO1_BENCH)
cd $(GO1_BENCH) && $(GO_NEW_BIN) test $(TESTFLAGS) -bench=. > $@

$(WORK)/runtime-$(OLD).txt: $(GO_OLD_BIN)
Expand Down Expand Up @@ -136,11 +138,11 @@ $(WORK)/floats-$(NEW).txt: $(GO_NEW_BIN)

$(WORK)/megajson-$(OLD).txt: $(GO_OLD_BIN)
$(GO_OLD_BIN) get -u -v -d github.com/benbjohnson/megajson
$(GO_OLD_BIN) test $(TESTFLAGS) -test.run=XXX -test.bench=. github.com/benbjohnson/megajson/bench > $@
cd $(GOPATH)/src/github.com/benbjohnson/megajson/.bench && $(GO_OLD_BIN) test $(TESTFLAGS) -test.run=XXX -test.bench=. . > $@

$(WORK)/megajson-$(NEW).txt: $(GO_NEW_BIN)
$(GO_NEW_BIN) get -u -v -d github.com/benbjohnson/megajson
$(GO_NEW_BIN) test $(TESTFLAGS) -test.run=XXX -test.bench=. github.com/benbjohnson/megajson/bench > $@
cd $(GOPATH)/src/github.com/benbjohnson/megajson/.bench && $(GO_OLD_BIN) test $(TESTFLAGS) -test.run=XXX -test.bench=. . > $@

$(WORK)/snappy-$(OLD).txt: $(GO_OLD_BIN)
$(GO_OLD_BIN) get -u -v -d code.google.com/p/snappy-go/snappy
Expand All @@ -160,3 +162,5 @@ $(WORK)/goquery-$(NEW).txt: $(GO_NEW_BIN)

clean:
rm -f $(WORK)/*.txt

.PHONEY: $(BENCHCMP)
202 changes: 0 additions & 202 deletions darwin-amd64-mac-mini-go1.1.2-vs-go1.2rc3.txt

This file was deleted.

0 comments on commit 19bdd20

Please sign in to comment.