Commit Graph
808 Commits
Author SHA1 Message Date
Nigel Tao ad787cba11 Change ractool default codec from zlib to zstd 2019-12-11 10:21:29 +11:00
Nigel Tao 03f0d84a3a Remove -Werror from "wuffs test/bench" 2019-11-30 15:32:05 +11:00
Nigel Tao bd96dad333 Update ractool's numbers for zstd-with-dictionary 2019-10-25 11:18:48 +11:00
Nigel Tao 3b466277dc Fix "wuffs gen" null pointer dereference 2019-10-22 08:31:53 +11:00
Nigel Tao 7d76140429 Have "wuffs genlib" take a -ccompilers arg 2019-10-19 16:32:07 +11:00
Nigel Tao 1520a1f345 Rename x T to x: T for fields and func args 2019-10-12 21:49:04 +11:00
Nigel Tao d501daddc3 Rename [i..j] to [i ..= j], the same as Rust 2019-10-12 18:40:53 +11:00
Nigel Tao b4808596ac Add a ractool -tmpdir flag 2019-09-28 11:40:57 +10:00
Nigel Tao ac7f476c25 Fix cmd/ractool doc typo 2019-09-15 19:49:34 +10:00
Nigel Tao ee4904f1f4 Update cmd/ractool performance numbers 2019-09-15 15:36:15 +10:00
Nigel Tao 7d4c042c49 Add cmd/ractool note about supported codecs 2019-09-15 14:29:44 +10:00
Nigel Tao 00b6d22333 Add a lib/raclz4 package 2019-09-15 14:13:45 +10:00
Nigel Tao 996cb765b9 Add RAC+Zstd support to cmd/ractool 2019-09-14 12:58:42 +10:00
Nigel Tao fed2073b00 Have lib/raczlib use lib/cgozlib
As the cmd/ractool comment changes say, this is almost a 2x speed-up for
RAC+Zlib decoding on the enwik8 test file, comparable to the cgozlib
benchmark numbers:

$ go test -test.bench=. github.com/google/wuffs/lib/cgozlib
goos: linux
goarch: amd64
pkg: github.com/google/wuffs/lib/cgozlib
BenchmarkCgo-56     	    2514	    477230 ns/op
BenchmarkPure-56    	    1090	   1080853 ns/op
2019-09-07 11:35:48 +10:00
Nigel Tao 5125e51916 Add ractool example time for -singlethreaded 2019-09-07 11:29:05 +10:00
Nigel Tao 84878498ef Replace RAC's Brotli Short Codec value by LZ4
RAC still supports Brotli (as a Long Codec, not a Short Codec). It's
just no longer given a dedicated Short Codec value (and therefore less
likely to be supported out-of-the-box by cmd/ractool). Brotli occupies a
similar position to Zstandard on the speed versus size frontier. LZ4
occupies a noticably different position, faster but larger.
2019-09-07 11:19:10 +10:00
Nigel Tao 396921817d Have ractool drange syntax accept i..=j 2019-09-01 08:37:22 +10:00
Nigel Tao a97dac93e1 Change ractool drange syntax from i:j to i..j
This is more consistent with the RAC spec, and on the Windows command
line the colon might be confused with the ":" in "C:\" names.
2019-09-01 08:27:21 +10:00
Nigel Tao b8cd560594 Add a rac.Reader.SeekRange method 2019-08-31 22:19:54 +10:00
Nigel Tao 7753d147b7 Move RAC concurrent decode from program to library 2019-08-31 17:14:28 +10:00
Nigel Tao 5d6e110e1e Add ractool message about the -help cmd line arg 2019-08-25 07:17:55 +10:00
Nigel Tao a51577270b Add ractool documentation about parsing "256K" 2019-08-24 16:39:02 +10:00
Nigel Tao f75a10a230 Add "random access" definition to ractool docs 2019-08-24 15:41:35 +10:00
Nigel Tao 22c030b2e0 Have ractool decode in parallel
The "middle of the decompressed file" numbers changed because the
programs were re-run on a desktop, not a laptop.
2019-08-24 12:59:49 +10:00
Nigel Tao ca4a6c8846 Restore rac's CompressedSize to avoid Seek calls 2019-08-24 09:34:12 +10:00
Nigel Tao bed69b00c5 Add comment on installing cmd/ractool 2019-08-10 20:51:17 +10:00
Nigel Tao 594b26b1c9 Add cmd/ractool extended example 2019-08-09 20:17:33 +10:00
Nigel Tao 6e7c88f42f Add a -resources flag to cmd/ractool 2019-08-09 18:59:10 +10:00
Nigel Tao 08798669eb Remove unnecessary rac CompressedSize field 2019-08-09 15:31:03 +10:00
Nigel Tao 6461695fb1 Add ractool comment that "1M" means 1 mebibyte 2019-08-08 16:57:14 +10:00
Nigel Tao 31eb600ad3 Remove unused raczlib constants 2019-08-08 15:41:00 +10:00
Nigel Tao 4d2f575f2a Refactor raczlib.Writer as rac part + zlib part 2019-08-08 15:38:21 +10:00
Nigel Tao 635c3c8fe9 Rename foo.raczlib to foo.rac 2019-08-08 11:31:30 +10:00
Nigel Tao eb017abd31 Have ractool parse "2k" to mean 2048 2019-08-08 11:27:25 +10:00
Nigel Tao 1944a35d4c Add more commentary to ractool's indexlocation 2019-08-08 10:48:01 +10:00
Nigel Tao 917f028f46 Default ractool to use dchunksize not cchunksize 2019-08-08 10:43:54 +10:00
Nigel Tao 737571cef8 Generate ractool's usage from its doc comment 2019-08-08 10:36:43 +10:00
Nigel Tao 6e3c54256c Re-organize ractool's usage as a doc comment 2019-08-08 10:21:37 +10:00
Nigel Tao 290b2256ce Add a -drange flage to cmd/ractool 2019-08-07 15:34:15 +10:00
Nigel Tao b65807d79d Have cmd/ractool support decoding 2019-08-06 17:37:30 +10:00
Nigel Tao d3c33aa232 Add cmd/ractool and lib/raczlib 2019-06-16 11:36:29 +10:00
Nigel Tao 6826f2f748 Move internal/cgen up a couple of directories 2019-03-09 13:28:59 +11:00
Nigel Tao 489284dfda Remove the deprecated foo__check_wuffs_version 2019-03-09 11:11:41 +11:00
Nigel Tao c4b8a6a4cc Don't use designated initializers
Some C/C++ compilers, such as MSVC, don't always support them. They're
also not supported by GCC's "g++ -std=c++11 -Wpedantic".
2019-03-09 10:08:00 +11:00
Nigel Tao fbd1ae8391 Disable -Wmaybe-uninitialized for GCC 2019-02-24 17:22:14 +11:00
Nigel Tao ffeb2bff63 Split benchmarks for full / partial initialization 2019-02-24 16:54:19 +11:00
Nigel Tao dd861416ff Allow calling pure functions after seeing an error
Updates #20
2019-02-24 11:13:51 +11:00
Nigel Tao 045f180a6c Rename errors from "?msg" to "#msg" 2019-02-23 17:06:24 +11:00
Nigel Tao 8b2c948f1b Work around clang memset / branch performance
name                                             old speed      new speed      delta

wuffs_deflate_decode_1k/clang5                    163MB/s ± 0%   163MB/s ± 0%    ~     (p=0.151 n=5+5)
wuffs_deflate_decode_10k/clang5                   230MB/s ± 1%   234MB/s ± 0%  +1.60%  (p=0.008 n=5+5)
wuffs_deflate_decode_100k_just_one_read/clang5    262MB/s ± 1%   265MB/s ± 0%  +0.97%  (p=0.008 n=5+5)
wuffs_deflate_decode_100k_many_big_reads/clang5   220MB/s ± 0%   221MB/s ± 0%  +0.59%  (p=0.008 n=5+5)

wuffs_deflate_decode_1k/gcc7                      193MB/s ± 1%   194MB/s ± 0%    ~     (p=0.151 n=5+5)
wuffs_deflate_decode_10k/gcc7                     276MB/s ± 1%   276MB/s ± 1%    ~     (p=0.690 n=5+5)
wuffs_deflate_decode_100k_just_one_read/gcc7      325MB/s ± 0%   324MB/s ± 1%    ~     (p=0.690 n=5+5)
wuffs_deflate_decode_100k_many_big_reads/gcc7     258MB/s ± 1%   258MB/s ± 0%    ~     (p=0.690 n=5+5)

wuffs_gif_decode_1k_bw/clang5                     430MB/s ± 1%   445MB/s ± 1%  +3.58%  (p=0.008 n=5+5)
wuffs_gif_decode_1k_color/clang5                  186MB/s ± 1%   192MB/s ± 0%  +3.17%  (p=0.008 n=5+5)
wuffs_gif_decode_10k_bgra/clang5                  729MB/s ± 1%   748MB/s ± 1%  +2.53%  (p=0.008 n=5+5)
wuffs_gif_decode_10k_indexed/clang5               196MB/s ± 1%   202MB/s ± 1%  +2.71%  (p=0.008 n=5+5)
wuffs_gif_decode_20k/clang5                       242MB/s ± 2%   251MB/s ± 0%  +3.54%  (p=0.016 n=5+4)
wuffs_gif_decode_100k_artificial/clang5           539MB/s ± 1%   545MB/s ± 1%    ~     (p=0.095 n=5+5)
wuffs_gif_decode_100k_realistic/clang5            221MB/s ± 0%   226MB/s ± 1%  +2.32%  (p=0.008 n=5+5)
wuffs_gif_decode_1000k/clang5                     224MB/s ± 0%   230MB/s ± 1%  +2.28%  (p=0.008 n=5+5)
wuffs_gif_decode_anim_screencap/clang5           1.06GB/s ± 0%  1.07GB/s ± 1%  +1.31%  (p=0.008 n=5+5)

wuffs_gif_decode_1k_bw/gcc7                       478MB/s ± 0%   467MB/s ± 0%  -2.27%  (p=0.008 n=5+5)
wuffs_gif_decode_1k_color/gcc7                    194MB/s ± 0%   196MB/s ± 0%  +0.94%  (p=0.008 n=5+5)
wuffs_gif_decode_10k_bgra/gcc7                    635MB/s ± 1%   639MB/s ± 1%    ~     (p=0.056 n=5+5)
wuffs_gif_decode_10k_indexed/gcc7                 200MB/s ± 1%   202MB/s ± 1%    ~     (p=0.095 n=5+5)
wuffs_gif_decode_20k/gcc7                         242MB/s ± 1%   243MB/s ± 1%    ~     (p=0.421 n=5+5)
wuffs_gif_decode_100k_artificial/gcc7             509MB/s ± 0%   510MB/s ± 0%    ~     (p=1.000 n=5+5)
wuffs_gif_decode_100k_realistic/gcc7              210MB/s ± 0%   211MB/s ± 0%  +0.50%  (p=0.016 n=5+5)
wuffs_gif_decode_1000k/gcc7                       214MB/s ± 0%   214MB/s ± 0%    ~     (p=0.151 n=5+5)
wuffs_gif_decode_anim_screencap/gcc7             1.03GB/s ± 0%  1.03GB/s ± 1%    ~     (p=0.421 n=5+5)

wuffs_lzw_decode_20k/clang5                       263MB/s ± 1%   267MB/s ± 2%    ~     (p=0.151 n=5+5)
wuffs_lzw_decode_100k/clang5                      427MB/s ± 1%   451MB/s ± 2%  +5.61%  (p=0.008 n=5+5)

wuffs_lzw_decode_20k/gcc7                         270MB/s ± 0%   268MB/s ± 0%  -0.66%  (p=0.008 n=5+5)
wuffs_lzw_decode_100k/gcc7                        481MB/s ± 1%   483MB/s ± 1%    ~     (p=0.222 n=5+5)
2019-02-23 12:47:41 +11:00
Nigel Tao 2952f130f6 Fold a memset call into an initialize call 2019-02-16 14:28:47 +11:00