mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-24 00:52:18 +01:00
Discuss "puffs bench" in doc/benchmarks.md.
This commit is contained in:
1 parent
a0fd42f6d4
commit
9ebcd54d43
2 files changed
+25
-5
No files matched your search
@@ -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`.
|
cloning the repository, move it to that path under your `$GOPATH`.
|
||||||
|
|
||||||
Running `go install -v github.com/google/puffs/cmd/...` will then install the
|
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`,
|
`clang-format`, `gofmt` or `rustfmt`) and `puffs` (roughly analogous to `make`,
|
||||||
`go` or `cargo`).
|
`go` or `cargo`).
|
||||||
|
|
||||||
@@ -343,4 +343,4 @@ owned by Google.
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
Updated on August 2017.
|
Updated on November 2017.
|
||||||
+23
-3
@@ -16,7 +16,8 @@ Broadwell.
|
|||||||
The benchmark programs aim to be runnable "out of the box" without any
|
The benchmark programs aim to be runnable "out of the box" without any
|
||||||
configuration or installation. For example, to run the `std/flate` benchmarks:
|
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
|
cd puffs/test/c/std
|
||||||
gcc -O3 flate.c
|
gcc -O3 flate.c
|
||||||
./a.out -bench
|
./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
|
code change. To install it, first install Go, then run `go get
|
||||||
golang.org/x/perf/cmd/benchstat`.
|
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
|
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
|
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.
|
||||||
Reference in new issue
Block a user