mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-24 00:52:18 +01:00
1 parent
e1a6a7cd8c
commit
425eefeb35
14 files changed
+29
-19
No files matched your search
+1
-1
@@ -124,7 +124,7 @@ Installation:
|
|||||||
|
|
||||||
Like any other implemented-in-Go program, to install the ractool program:
|
Like any other implemented-in-Go program, to install the ractool program:
|
||||||
|
|
||||||
go get github.com/google/wuffs/cmd/ractool
|
go install github.com/google/wuffs/cmd/ractool
|
||||||
|
|
||||||
Extended Example:
|
Extended Example:
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -125,7 +125,7 @@ Installation:
|
|||||||
|
|
||||||
Like any other implemented-in-Go program, to install the ractool program:
|
Like any other implemented-in-Go program, to install the ractool program:
|
||||||
|
|
||||||
go get github.com/google/wuffs/cmd/ractool
|
go install github.com/google/wuffs/cmd/ractool
|
||||||
|
|
||||||
Extended Example:
|
Extended Example:
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -38,7 +38,7 @@ The output of those benchmark programs is compatible with the
|
|||||||
[benchstat](https://godoc.org/golang.org/x/perf/cmd/benchstat) tool. For
|
[benchstat](https://godoc.org/golang.org/x/perf/cmd/benchstat) tool. For
|
||||||
example, that tool can calculate confidence intervals based on multiple
|
example, that tool can calculate confidence intervals based on multiple
|
||||||
benchmark runs, or calculate p-values when comparing numbers before and after a
|
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 install
|
||||||
golang.org/x/perf/cmd/benchstat`.
|
golang.org/x/perf/cmd/benchstat`.
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+16
-6
@@ -22,15 +22,25 @@ test suite, you might also have to install C compilers like clang and gcc, as
|
|||||||
well as C libraries (and their .h files) like libjpeg and libpng, as some tests
|
well as C libraries (and their .h files) like libjpeg and libpng, as some tests
|
||||||
compare that Wuffs produces exactly the same output as these other libraries.
|
compare that Wuffs produces exactly the same output as these other libraries.
|
||||||
|
|
||||||
Running `go get -v github.com/google/wuffs/cmd/...` will download and install
|
Run `git clone https://github.com/google/wuffs.git` to get the latest Wuffs
|
||||||
the Wuffs tools. Change `get` to `install` to re-install those programs without
|
code, `cd` into its directory and run `go install -v ./cmd/wuffs*` to install
|
||||||
downloading, e.g. after you've modified their source code, or after a manually
|
the Wuffs tools. The Wuffs tools that you'll most often use are `wuffsfmt`
|
||||||
issued `git pull`. The Wuffs tools that you'll most often use are `wuffsfmt`
|
|
||||||
(analogous to `clang-format`, `gofmt` or `rustfmt`) and `wuffs` (roughly
|
(analogous to `clang-format`, `gofmt` or `rustfmt`) and `wuffs` (roughly
|
||||||
analogous to `make`, `go` or `cargo`).
|
analogous to `make`, `go` or `cargo`).
|
||||||
|
|
||||||
You should now be able to run `wuffs test`. If all goes well, you should see
|
You should now be able to run `wuffs test`. If you only have the `gcc` C
|
||||||
some output containing the word "PASS" multiple times.
|
compiler installed, but not `clang`, then you can run `wuffs
|
||||||
|
test -ccompilers=gcc` instead. If all goes well, you should see some output
|
||||||
|
containing the word "PASS" multiple times.
|
||||||
|
|
||||||
|
Remember to re-run `go install etc` whenever you've modified the Wuffs *tools'*
|
||||||
|
source code (i.e. `*.go` files) or after a manually issued `git pull`. If
|
||||||
|
you're only modifying the Wuffs *standard library's* source code (i.e.
|
||||||
|
`*.wuffs` files), re-running `go install etc` is unnecessary.
|
||||||
|
|
||||||
|
If you're modifying just one particular codec in the standard library, such as
|
||||||
|
the `std/png/*.wuffs` files, then you can exclude unrelated tests by running
|
||||||
|
`wuffs test std/png`.
|
||||||
|
|
||||||
|
|
||||||
## Poking Around
|
## Poking Around
|
||||||
|
|||||||
@@ -661,7 +661,7 @@ Go programming language libraries:
|
|||||||
- [RAC](https://godoc.org/github.com/google/wuffs/lib/rac)
|
- [RAC](https://godoc.org/github.com/google/wuffs/lib/rac)
|
||||||
- [RAC + Zlib](https://godoc.org/github.com/google/wuffs/lib/raczlib)
|
- [RAC + Zlib](https://godoc.org/github.com/google/wuffs/lib/raczlib)
|
||||||
|
|
||||||
Command line tool, installable via `go get
|
Command line tool, installable via `go install
|
||||||
github.com/google/wuffs/cmd/ractool`:
|
github.com/google/wuffs/cmd/ractool`:
|
||||||
|
|
||||||
- [ractool](https://godoc.org/github.com/google/wuffs/cmd/ractool)
|
- [ractool](https://godoc.org/github.com/google/wuffs/cmd/ractool)
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
CC=${CC:-gcc}
|
CC=${CC:-gcc}
|
||||||
|
|
||||||
# You may need to run
|
# You may need to run
|
||||||
# go get github.com/google/wuffs/cmd/wuffs-c
|
# go install github.com/google/wuffs/cmd/wuffs-c
|
||||||
# beforehand, to install the wuffs-c compiler.
|
# beforehand, to install the wuffs-c compiler.
|
||||||
wuffs-c gen -package_name demo < parse.wuffs > parse.c
|
wuffs-c gen -package_name demo < parse.wuffs > parse.c
|
||||||
|
|
||||||
|
|||||||
@@ -396,7 +396,7 @@ main(int argc, char** argv) {
|
|||||||
"compatible with the\n"
|
"compatible with the\n"
|
||||||
"# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install "
|
"# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install "
|
||||||
"it, first\n"
|
"it, first\n"
|
||||||
"# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n");
|
"# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n");
|
||||||
|
|
||||||
for (int i = 0; i < 5; i++) {
|
for (int i = 0; i < 5; i++) {
|
||||||
msg = decode(true, true);
|
msg = decode(true, true);
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ func main1() error {
|
|||||||
fmt.Printf("#\n")
|
fmt.Printf("#\n")
|
||||||
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
||||||
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
||||||
fmt.Printf("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n")
|
fmt.Printf("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n")
|
||||||
|
|
||||||
for i := -1; i < reps; i++ {
|
for i := -1; i < reps; i++ {
|
||||||
for _, tc := range testCases {
|
for _, tc := range testCases {
|
||||||
|
|||||||
@@ -106,7 +106,7 @@ func main1() error {
|
|||||||
fmt.Printf("#\n")
|
fmt.Printf("#\n")
|
||||||
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
||||||
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
||||||
fmt.Printf("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n")
|
fmt.Printf("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n")
|
||||||
|
|
||||||
for i := -1; i < reps; i++ {
|
for i := -1; i < reps; i++ {
|
||||||
for _, tc := range testCases {
|
for _, tc := range testCases {
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ func main1() error {
|
|||||||
fmt.Printf("#\n")
|
fmt.Printf("#\n")
|
||||||
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
fmt.Printf("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n")
|
||||||
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
fmt.Printf("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n")
|
||||||
fmt.Printf("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n")
|
fmt.Printf("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n")
|
||||||
|
|
||||||
for i := -1; i < reps; i++ {
|
for i := -1; i < reps; i++ {
|
||||||
for _, tc := range testCases {
|
for _, tc := range testCases {
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ fn main() {
|
|||||||
print!("#\n");
|
print!("#\n");
|
||||||
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
||||||
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
||||||
print!("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n");
|
print!("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n");
|
||||||
|
|
||||||
let mut dst = vec![0u8; 64 * 1024 * 1024];
|
let mut dst = vec![0u8; 64 * 1024 * 1024];
|
||||||
|
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ fn main() {
|
|||||||
print!("#\n");
|
print!("#\n");
|
||||||
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
||||||
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
||||||
print!("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n");
|
print!("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n");
|
||||||
|
|
||||||
let mut dst = vec![0u8; 64 * 1024 * 1024];
|
let mut dst = vec![0u8; 64 * 1024 * 1024];
|
||||||
|
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ fn main() {
|
|||||||
print!("#\n");
|
print!("#\n");
|
||||||
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
print!("# The output format, including the \"Benchmark\" prefixes, is compatible with the\n");
|
||||||
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
print!("# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install it, first\n");
|
||||||
print!("# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n");
|
print!("# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n");
|
||||||
|
|
||||||
let mut dst0 = vec![0u8; 64 * 1024 * 1024];
|
let mut dst0 = vec![0u8; 64 * 1024 * 1024];
|
||||||
let mut dst1 = vec![0u8; 64 * 1024 * 1024];
|
let mut dst1 = vec![0u8; 64 * 1024 * 1024];
|
||||||
|
|||||||
@@ -422,7 +422,7 @@ test_main(int argc, char** argv, proc* tests, proc* benches) {
|
|||||||
"compatible with the\n"
|
"compatible with the\n"
|
||||||
"# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install "
|
"# https://godoc.org/golang.org/x/perf/cmd/benchstat tool. To install "
|
||||||
"it, first\n"
|
"it, first\n"
|
||||||
"# install Go, then run \"go get golang.org/x/perf/cmd/benchstat\".\n");
|
"# install Go, then run \"go install golang.org/x/perf/cmd/benchstat\".\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i = 0; i < reps; i++) {
|
for (int i = 0; i < reps; i++) {
|
||||||
|
|||||||
Reference in new issue
Block a user