diff --git a/README.md b/README.md index 6e0a2842..5f99c469 100644 --- a/README.md +++ b/README.md @@ -216,7 +216,7 @@ home of the software project will be at `github.com/google/puffs`. After cloning the repository, move it to that path under your `$GOPATH`. Running `go install -v github.com/google/puffs/cmd/...` will then install the -puffs tools. The ones that you'll most often use are `puffsfmt` (analogous to +Puffs tools. The ones that you'll most often use are `puffsfmt` (analogous to `clang-format`, `gofmt` or `rustfmt`) and `puffs` (roughly analogous to `make`, `go` or `cargo`). @@ -343,4 +343,4 @@ owned by Google. --- -Updated on August 2017. +Updated on November 2017. diff --git a/doc/benchmarks.md b/doc/benchmarks.md index 7fadc3c2..ad1cb364 100644 --- a/doc/benchmarks.md +++ b/doc/benchmarks.md @@ -16,7 +16,8 @@ Broadwell. The benchmark programs aim to be runnable "out of the box" without any configuration or installation. For example, to run the `std/flate` benchmarks: - git clone etc + # TODO: confirm that we will live at github.com/google/puffs + git clone https://github.com/google/puffs.git cd puffs/test/c/std gcc -O3 flate.c ./a.out -bench @@ -31,8 +32,27 @@ benchmark runs, or calculate p-values when comparing numbers before and after a code change. To install it, first install Go, then run `go get golang.org/x/perf/cmd/benchstat`. +## puffs bench -## GIF +As mentioned above, individual benchmark programs can be run manually. However, +the canonical way to run the benchmarks (across multiple compilers and multiple +packages like GIF and PNG) is to use the `puffs` command line tool, as it will +also re-generate (transpile) the C code whenever you edit the \*.puffs code. +Running `go install -v github.com/google/puffs/cmd/...` will install the Puffs +tools. After that, you can say + + puffs bench + +or + + puffs bench -mimic std/flate + +or + + puffs bench -ccompilers=gcc -reps=3 -focus=Benchmarkpuffs_gif_lzw std/gif + + +# GIF The 1k, 10k, etc. numbers are approximately how many bytes of pixel data there is in the decoded image. For example, the `test/testdata/harvesters.*` images @@ -67,4 +87,4 @@ to run the test harness. --- -Updated on October 2017. +Updated on November 2017.