Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@feyeleanor
Created July 13, 2012 13:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save feyeleanor/3104898 to your computer and use it in GitHub Desktop.
Save feyeleanor/3104898 to your computer and use it in GitHub Desktop.
first attempt to run the gospeed micro-benchmarks on a raspberrypi
root@raspberrypi:/usr/local/go/src/pkg/github.com/feyeleanor/gospeed# go test -test.bench=".*"
PASS
BenchmarkBaselineCastInt32ToInt 100000000 13.4 ns/op
BenchmarkBaselineCastIntToInt32 100000000 14.1 ns/op
BenchmarkBaselineCastInt64ToUint64 100000000 18.0 ns/op
BenchmarkBaselineCastUint64ToInt64 100000000 17.2 ns/op
BenchmarkBaselineVariableGet 100000000 14.2 ns/op
BenchmarkBaselineVariableSet 100000000 23.0 ns/op
BenchmarkBaselineVariableGetInterface 100000000 13.4 ns/op
BenchmarkBaselineVariableSetInterface 50000000 32.7 ns/op
BenchmarkBaselineVariableIncrement 100000000 24.6 ns/op
BenchmarkBaselineVariableDecrement 100000000 23.8 ns/op
BenchmarkBaselineFieldGet 100000000 14.2 ns/op
BenchmarkBaselineFieldSet 100000000 21.5 ns/op
BenchmarkBaselineSliceGet 50000000 32.7 ns/op
BenchmarkBaselineSliceSet 50000000 35.5 ns/op
BenchmarkBaselineMapIntGet 1000000 2092 ns/op
BenchmarkBaselineMapIntSet 1000000 2507 ns/op
BenchmarkBaselineMapStringGet 1000000 1728 ns/op
BenchmarkBaselineMapStringSet 1000000 2287 ns/op
BenchmarkBaselineIf 100000000 15.7 ns/op
BenchmarkBaselineIfElse 100000000 15.6 ns/op
BenchmarkBaselineSwitchDefault 100000000 14.1 ns/op
BenchmarkBaselineSwitchOneCase 100000000 15.6 ns/op
BenchmarkBaselineSwitchTwoCases 100000000 20.1 ns/op
BenchmarkBaselineSwitchTwoCasesFallthrough 100000000 20.1 ns/op
BenchmarkBaselineForLoopIteration 50000000 41.6 ns/op
BenchmarkBaselineForReverseLoopIteration 50000000 38.3 ns/op
BenchmarkBaselineForRange 20000000 87.1 ns/op
BenchmarkBaselineForSliceLength 50000000 38.7 ns/op
BenchmarkBaselineForReverseSliceLength 50000000 37.2 ns/op
BenchmarkBaselineForLoopIteration10 20000000 122 ns/op
BenchmarkBaselineForReverseLoopIteration10 20000000 90.1 ns/op
BenchmarkBaselineForRange10 10000000 235 ns/op
BenchmarkBaselineForSliceLength10 20000000 89.2 ns/op
BenchmarkBaselineForReverseSliceLength10 20000000 90.0 ns/op
BenchmarkBaselineForLoopIteration100 2000000 960 ns/op
BenchmarkBaselineForReverseLoopIteration100 5000000 637 ns/op
BenchmarkBaselineForRange100 1000000 1762 ns/op
BenchmarkBaselineForSliceLength100 5000000 641 ns/op
BenchmarkBaselineForReverseSliceLength100 5000000 646 ns/op
BenchmarkBaselineForLoopIteration10000 10000 127587 ns/op
BenchmarkBaselineForReverseLoopIteration10000 50000 61106 ns/op
BenchmarkBaselineForRange10000 10000 173620 ns/op
BenchmarkBaselineForSliceLength10000 50000 64688 ns/op
BenchmarkBaselineForReverseSliceLength10000 50000 61113 ns/op
BenchmarkBaselineMakeChannelBoolUnbuffered 200000 10606 ns/op
BenchmarkBaselineMakeChannelBool1 200000 13064 ns/op
BenchmarkBaselineMakeChannelBool10 200000 13029 ns/op
BenchmarkBaselineMakeChannelStringUnbuffered 200000 10973 ns/op
BenchmarkBaselineMakeChannelString1 200000 13351 ns/op
BenchmarkBaselineMakeChannelString10 100000 23490 ns/op
BenchmarkBaselineGo signal 9
FAIL github.com/feyeleanor/gospeed 138.916s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment