Nigel Tao
77f855206d
Have JSON line-comment tokens exclude the "\n"
...
Before this commit, line-comment token chains included the final "\n"
the way block-comments included the final "*/". The "\n" was mandatory.
However, when parsing with both QUIRK_ALLOW_COMMENT_LINE and
QUIRK_ALLOW_TRAILING_FILLER, input like "123//xyz" (without a "\n"
before the EOF) was rejected before and accepted after this commit.
So that line-comments are consistent, in that they either always or
never include the final "\n", they now never include the final "\n".
An input fragment (parsed with QUIRK_ALLOW_COMMENT_LINE) like
"//abc\n\t\t" was, before this commit, parsed as a 6 byte comment token
and a 2 byte other-filler token. That split is now 5+3.
2021-07-20 14:17:09 +10:00
Nigel Tao
40ffa334ee
Add more json allow_trailing_comments test cases
2021-07-18 23:27:56 +10:00
Nigel Tao
e88e28259e
wuffs gen -version=0.3.0-beta.7
2021-07-18 11:36:39 +10:00
Nigel Tao
6a30c1ede0
Inline wuffs_aux::DecodeJson work_buf variable
2021-07-18 11:25:46 +10:00
Nigel Tao
9c07523a84
Have wuffs_aux::DecodeJson consume trailing filler
...
Prior to this commit, wuffs_aux::DecodeJson would almost always consume
(optional) trailing filler, but in rare coincidences, it might not if a
wuffs_base__suspension__short_write coroutine suspension was needed
between the last token of the actual JSON value and the first token of
the filler after that JSON value.
This commit should change behavior only if the wuffs_aux::DecodeJson
caller had opted into WUFFS_JSON__QUIRK_ALLOW_TRAILING_FILLER or
WUFFS_JSON__QUIRK_EXPECT_TRAILING_NEW_LINE_OR_EOF.
Also remove an unnecessary std::move on a size_t typed value.
2021-07-18 11:12:41 +10:00
Nigel Tao
816475b285
Add "b" (for "binary") to fopen calls
...
Updates #50
2021-07-07 20:28:35 +10:00
Nigel Tao
d0451190ca
wuffs gen -version=0.3.0-beta.6
2021-07-05 21:51:37 +10:00
Nigel Tao
3842c519c9
Delete the WUFFS_BASE__FALLTHROUGH macro
...
Getting it to work on various compilers has been more trouble than it's
worth. The previous commit ignores "-Wimplicit-fallthrough" instead.
2021-07-05 21:40:25 +10:00
Nigel Tao
ea50956b5a
Ignore "-Wimplicit-fallthrough"
2021-07-05 21:40:25 +10:00
Nigel Tao
fd90553a8f
Tweak the WUFFS_BASE__FALLTHROUGH macro
...
When compiling with "-Werror,-Wimplicit-fallthrough", commit c90cc7b6
tweaked WUFFS_BASE__FALLTHROUGH to work with newer clang compilers, when
defined(__cplusplus) is false, but inadvertently broke older clang
compilers, when __has_attribute(fallthrough) is false.
This commit reverts some of c90cc7b6 to handle more cases. The next two
commits will delete the WUFFS_BASE__FALLTHROUGH macro entirely and
render this commit redundant, as the whole business is proving more
trouble than it's worth. But it's checked into the commit history in
case somebody in the future wants to revive WUFFS_BASE__FALLTHROUGH.
2021-07-05 21:40:18 +10:00
Nigel Tao
963a574f7d
wuffs gen -version=0.3.0-beta.5
2021-07-02 13:44:55 +10:00
Nigel Tao
edd87f0eda
Merge pull request #49 from pkasting/main
...
Fix -Wunreachable-code-aggressive.
2021-06-30 10:10:05 +10:00
Nigel Tao
6bfaf0f008
wuffs gen -version=0.3.0-beta.4
2021-06-28 10:11:25 +10:00
Nigel Tao
b9a10d051a
Fix -Werror=conversion in fundamental-public.h
2021-06-28 10:10:13 +10:00
Nigel Tao
7f93a94e7a
Tweak WUFFS_BASE__FALLTHROUGH comment
2021-06-28 10:07:01 +10:00
Nigel Tao
a0698fc1a2
Add Peter Kasting to CONTRIBUTORS
...
"Google Inc." is already in AUTHORS.
2021-06-28 10:00:13 +10:00
Nigel Tao
d8796aa6d9
Add wuffs_base__uxx__rotate_etc functions
2021-06-28 09:59:32 +10:00
Nigel Tao
a12771373e
Merge pull request #48 from pkasting/main
...
Fix -Wimplicit-fallthrough for Clang.
2021-06-28 09:58:23 +10:00
Nigel Tao
b2b8961126
wuffs gen -version=0.3.0-beta.3
2021-06-25 15:36:54 +10:00
Nigel Tao
f6945c0612
Remove unnecessary "goto ok;" in generated C code
2021-06-25 14:47:10 +10:00
Nigel Tao
76e6872498
Have clang-cl ignore unused-function etc warnings
2021-06-25 13:51:27 +10:00
Nigel Tao
98c66ef761
wuffs gen -version=0.3.0-beta.2
2021-06-24 22:43:15 +10:00
Nigel Tao
91857f4c4b
Disable cpu_arch specific code for Native Client
2021-06-24 22:40:54 +10:00
Nigel Tao
08797bc713
Have "x86_avx2" require PCLMUL, POPCNT and SSE4.2
...
The std/crc32 benchmark numbers get worse. The benches still run AVX2
code, but it runs slower for an unknown reason. The std/gzip and std/png
benchmark numbers are mixed.
Still, it's cleaner for Wuffs' "x86_avx2" to be a superset of
"x86_sse42" (and apart from PCLMUL, they're now similar to Clang 12 and
GCC 11's "x86-64-v3" and "x86-64-v2" micro-architecture feature levels).
Maybe future compiler versions can claw back the std/crc32 performance.
On a mid-range x86_64 laptop (2016, Skylake):
name old speed new speed delta
wuffs_crc32_ieee_10k/clang9 8.07GB/s ± 0% 7.61GB/s ± 1% -5.72% (p=0.000 n=8+8)
wuffs_crc32_ieee_100k/clang9 11.0GB/s ± 1% 9.7GB/s ± 3% -11.45% (p=0.000 n=7+8)
wuffs_crc32_ieee_10k/gcc10 9.77GB/s ± 1% 7.72GB/s ± 1% -21.00% (p=0.000 n=10+9)
wuffs_crc32_ieee_100k/gcc10 12.7GB/s ± 2% 11.9GB/s ± 2% -5.84% (p=0.000 n=9+9)
wuffs_gzip_decode_10k/clang9 217MB/s ± 2% 221MB/s ± 0% +1.80% (p=0.000 n=10+8)
wuffs_gzip_decode_100k/clang9 280MB/s ± 1% 283MB/s ± 0% +1.38% (p=0.000 n=9+8)
wuffs_gzip_decode_10k/gcc10 215MB/s ± 1% 220MB/s ± 1% +2.52% (p=0.000 n=10+9)
wuffs_gzip_decode_100k/gcc10 272MB/s ± 0% 274MB/s ± 1% +0.74% (p=0.000 n=9+10)
wuffs_png_decode_image_19k_8bpp/clang9 136MB/s ± 0% 142MB/s ± 0% +3.95% (p=0.000 n=8+8)
wuffs_png_decode_image_40k_24bpp/clang9 171MB/s ± 1% 172MB/s ± 0% +0.84% (p=0.000 n=10+8)
wuffs_png_decode_image_77k_8bpp/clang9 492MB/s ± 3% 501MB/s ± 2% +1.88% (p=0.009 n=10+10)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/clang9 456MB/s ± 1% 461MB/s ± 1% +1.04% (p=0.000 n=9+9)
wuffs_png_decode_image_552k_32bpp_verify_checksum/clang9 439MB/s ± 1% 440MB/s ± 3% ~ (p=0.173 n=8+10)
wuffs_png_decode_image_4002k_24bpp/clang9 172MB/s ± 1% 174MB/s ± 1% +1.29% (p=0.005 n=10+10)
wuffs_png_decode_image_19k_8bpp/gcc10 152MB/s ± 0% 149MB/s ± 1% -1.92% (p=0.000 n=9+9)
wuffs_png_decode_image_40k_24bpp/gcc10 184MB/s ± 0% 186MB/s ± 1% +1.37% (p=0.000 n=8+9)
wuffs_png_decode_image_77k_8bpp/gcc10 550MB/s ± 1% 542MB/s ± 2% -1.46% (p=0.000 n=10+10)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/gcc10 473MB/s ± 1% 478MB/s ± 1% +1.23% (p=0.000 n=9+10)
wuffs_png_decode_image_552k_32bpp_verify_checksum/gcc10 453MB/s ± 1% 458MB/s ± 1% +0.91% (p=0.000 n=9+10)
wuffs_png_decode_image_4002k_24bpp/gcc10 185MB/s ± 2% 188MB/s ± 0% +1.82% (p=0.000 n=9+8)
2021-06-22 13:27:25 +10:00
Nigel Tao
ec32eb3eb7
Add fuzz/c/std/gif_fuzzer.c quirks
2021-06-18 22:37:29 +10:00
Nigel Tao
a51867dc63
Fix "forseen" typo
2021-05-19 21:34:09 +10:00
Nigel Tao
3358730f6f
Have std/png reject zero width or height
2021-05-11 12:34:19 +10:00
Nigel Tao
97f5bec0e3
Fix doc/spec/rac-related-work.md typo
2021-05-04 13:29:22 +10:00
Nigel Tao
b0826d2ab7
Add test/data/archive.*
...
$ 7z a archive.7z \
artificial/0.bytes github-tags.json hello.sh non-ascii/αβ.txt \
non-ascii/😻 .txt pjw-thumbnail.png romeo.txt romeo.txt.gz
$ zip archive.zip etc etc
$ rar a archive.rar etc etc
$ tar cvf archive.tar etc etc
$ tar cvjf archive.tar.bz2 etc etc
$ tar cvzf archive.tar.gz etc etc
$ lcab etc etc archive.cab
And after curating a data/ directory (without non-ascii/😻 .txt):
$ genisoimage -v -J -r -V WUFFS_TEST_DATA_SUBSET -o archive.iso data/
2021-05-03 22:25:35 +10:00
Nigel Tao
a0984dcdd3
Limit the number of coroutines per type to 0x7FFF
2021-05-02 16:50:29 +10:00
Nigel Tao
b8f87debe3
Tweak wuffs_base__cpu_arch__have_foo_bar impl
2021-04-29 17:52:10 +10:00
Nigel Tao
e77d73e3ce
Add std/adler32 bench comment for the roll back
2021-04-28 22:38:10 +10:00
Nigel Tao
0a6cce5e0e
Tweak some adler32 hasher.up_x86_sse42 var names
2021-04-28 00:32:32 +10:00
Nigel Tao
abd37fa3f8
Roll back 'Add std/adler32 hasher.up_x86_avx2'
...
See the previous commit for the rationale.
2021-04-28 00:26:54 +10:00
Nigel Tao
baec831fc8
Add std/adler32 hasher.up_x86_avx2
...
While the std/adler32 benchmarks got better, the std/zlib and std/png
benchmarks got worse.
This commit will soon be followed by a rollback, but it is committed
anyway so that we can refer to these numbers in the git log.
Binary size, before:
4056 gen/lib/c/clang-9-dynamic/wuffs-std-adler32.lo
4104 gen/lib/c/clang-9-static/wuffs-std-adler32.o
4624 gen/lib/c/gcc-dynamic/wuffs-std-adler32.lo
4680 gen/lib/c/gcc-static/wuffs-std-adler32.o
After:
4952 gen/lib/c/clang-9-dynamic/wuffs-std-adler32.lo
5016 gen/lib/c/clang-9-static/wuffs-std-adler32.o
5512 gen/lib/c/gcc-dynamic/wuffs-std-adler32.lo
5576 gen/lib/c/gcc-static/wuffs-std-adler32.o
name old speed new speed delta
wuffs_adler32_10k/clang9 11.5GB/s ± 1% 15.0GB/s ± 5% +30.73% (p=0.000 n=9+10)
wuffs_adler32_100k/clang9 13.5GB/s ± 1% 15.6GB/s ±14% +16.06% (p=0.001 n=9+10)
wuffs_adler32_10k/gcc10 11.3GB/s ± 2% 15.6GB/s ± 1% +38.27% (p=0.000 n=9+9)
wuffs_adler32_100k/gcc10 11.3GB/s ± 1% 19.4GB/s ± 1% +71.20% (p=0.000 n=7+9)
wuffs_zlib_decode_10k/clang9 223MB/s ± 1% 216MB/s ± 2% -3.45% (p=0.000 n=10+10)
wuffs_zlib_decode_100k/clang9 285MB/s ± 1% 284MB/s ± 1% ~ (p=0.243 n=9+10)
wuffs_zlib_decode_10k/gcc10 232MB/s ± 1% 216MB/s ± 1% -6.70% (p=0.000 n=10+9)
wuffs_zlib_decode_100k/gcc10 291MB/s ± 1% 280MB/s ± 1% -3.70% (p=0.000 n=9+8)
wuffs_png_decode_image_19k_8bpp/clang9 152MB/s ± 1% 143MB/s ± 3% -5.89% (p=0.000 n=8+9)
wuffs_png_decode_image_40k_24bpp/clang9 171MB/s ± 1% 173MB/s ± 1% ~ (p=0.094 n=9+9)
wuffs_png_decode_image_77k_8bpp/clang9 541MB/s ± 1% 509MB/s ± 1% -5.77% (p=0.000 n=8+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/clang9 479MB/s ± 1% 464MB/s ± 3% -3.20% (p=0.000 n=8+10)
wuffs_png_decode_image_552k_32bpp_verify_checksum/clang9 461MB/s ± 1% 452MB/s ± 1% -2.02% (p=0.000 n=8+10)
wuffs_png_decode_image_4002k_24bpp/clang9 177MB/s ± 1% 175MB/s ± 2% -1.14% (p=0.004 n=10+10)
wuffs_png_decode_image_19k_8bpp/gcc10 159MB/s ± 1% 153MB/s ± 1% -3.54% (p=0.000 n=8+10)
wuffs_png_decode_image_40k_24bpp/gcc10 188MB/s ± 1% 187MB/s ± 1% -0.47% (p=0.021 n=10+9)
wuffs_png_decode_image_77k_8bpp/gcc10 557MB/s ± 0% 546MB/s ± 4% -1.94% (p=0.000 n=8+10)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/gcc10 510MB/s ± 0% 493MB/s ± 0% -3.33% (p=0.000 n=10+9)
wuffs_png_decode_image_552k_32bpp_verify_checksum/gcc10 486MB/s ± 1% 478MB/s ± 0% -1.77% (p=0.000 n=8+9)
wuffs_png_decode_image_4002k_24bpp/gcc10 189MB/s ± 1% 187MB/s ± 1% -1.26% (p=0.000 n=10+10)
2021-04-28 00:18:20 +10:00
Nigel Tao
8ccaf81e96
Fix s/bit_BMI2/bit_AVX2/ typo
2021-04-26 22:52:27 +10:00
Nigel Tao
be546c3587
Be able to test and bench the libdeflate library
...
name old speed new speed delta
wuffs_adler32_10k/clang9 11.4GB/s ± 2% 11.6GB/s ± 2% +1.26% (p=0.013 n=9+10)
wuffs_adler32_100k/clang9 13.7GB/s ± 1% 13.6GB/s ± 1% ~ (p=0.277 n=8+9)
wuffs_adler32_10k/gcc10 12.2GB/s ± 0% 11.4GB/s ± 1% -7.01% (p=0.000 n=8+9)
wuffs_adler32_100k/gcc10 12.0GB/s ± 1% 11.7GB/s ± 1% -2.80% (p=0.000 n=9+9)
mimic_adler32_10k 1.91GB/s ± 0% 25.24GB/s ± 1% +1218.88% (p=0.000 n=9+9)
mimic_adler32_100k 1.87GB/s ± 0% 22.94GB/s ± 1% +1126.66% (p=0.000 n=10+10)
wuffs_crc32_ieee_10k/clang9 7.81GB/s ± 0% 7.70GB/s ± 0% -1.41% (p=0.000 n=8+8)
wuffs_crc32_ieee_100k/clang9 10.0GB/s ± 2% 10.6GB/s ± 1% +5.25% (p=0.000 n=7+8)
wuffs_crc32_ieee_10k/gcc10 9.80GB/s ± 1% 10.03GB/s ± 1% +2.35% (p=0.000 n=9+10)
wuffs_crc32_ieee_100k/gcc10 13.1GB/s ± 0% 12.9GB/s ± 0% -1.52% (p=0.000 n=10+9)
mimic_crc32_ieee_10k 842MB/s ± 1% 12952MB/s ± 0% +1437.67% (p=0.000 n=10+9)
mimic_crc32_ieee_100k 838MB/s ± 2% 13363MB/s ± 1% +1493.79% (p=0.000 n=10+9)
wuffs_deflate_decode_1k_full_init/clang9 101MB/s ± 0% 106MB/s ± 1% +4.22% (p=0.000 n=8+10)
wuffs_deflate_decode_1k_part_init/clang9 119MB/s ± 1% 121MB/s ± 1% +1.39% (p=0.000 n=10+10)
wuffs_deflate_decode_10k_full_init/clang9 222MB/s ± 0% 215MB/s ± 0% -3.24% (p=0.000 n=9+9)
wuffs_deflate_decode_10k_part_init/clang9 228MB/s ± 0% 218MB/s ± 3% -4.47% (p=0.000 n=10+9)
wuffs_deflate_decode_100k_just_one_read/clang9 291MB/s ± 0% 286MB/s ± 3% -1.85% (p=0.000 n=10+10)
wuffs_deflate_decode_100k_many_big_reads/clang9 189MB/s ± 1% 178MB/s ± 1% -5.50% (p=0.000 n=10+10)
wuffs_deflate_decode_1k_full_init/gcc10 99.1MB/s ± 2% 102.1MB/s ± 1% +3.12% (p=0.000 n=10+9)
wuffs_deflate_decode_1k_part_init/gcc10 117MB/s ± 1% 121MB/s ± 1% +3.41% (p=0.000 n=10+9)
wuffs_deflate_decode_10k_full_init/gcc10 215MB/s ± 1% 218MB/s ± 1% +1.55% (p=0.000 n=10+10)
wuffs_deflate_decode_10k_part_init/gcc10 220MB/s ± 1% 225MB/s ± 0% +2.08% (p=0.000 n=10+8)
wuffs_deflate_decode_100k_just_one_read/gcc10 281MB/s ± 1% 279MB/s ± 1% ~ (p=0.105 n=10+10)
wuffs_deflate_decode_100k_many_big_reads/gcc10 182MB/s ± 1% 180MB/s ± 0% -1.14% (p=0.000 n=9+7)
mimic_deflate_decode_1k_full_init 138MB/s ± 1% 179MB/s ± 1% +29.56% (p=0.000 n=10+10)
mimic_deflate_decode_10k_full_init 155MB/s ± 2% 268MB/s ± 1% +72.15% (p=0.000 n=9+10)
mimic_deflate_decode_100k_just_one_read 191MB/s ± 0% 269MB/s ± 1% +40.38% (p=0.000 n=10+10)
mimic_deflate_decode_100k_many_big_reads 147MB/s ± 1% skipped
wuffs_gzip_decode_10k/clang9 218MB/s ± 1% 211MB/s ± 1% -3.18% (p=0.000 n=8+9)
wuffs_gzip_decode_100k/clang9 282MB/s ± 0% 282MB/s ± 0% ~ (p=0.113 n=9+9)
wuffs_gzip_decode_10k/gcc10 215MB/s ± 1% 231MB/s ± 1% +7.34% (p=0.000 n=10+10)
wuffs_gzip_decode_100k/gcc10 271MB/s ± 2% 293MB/s ± 0% +7.84% (p=0.000 n=10+9)
mimic_gzip_decode_10k 132MB/s ± 1% 263MB/s ± 0% +99.23% (p=0.000 n=10+9)
mimic_gzip_decode_100k 156MB/s ± 1% 262MB/s ± 3% +67.93% (p=0.000 n=9+10)
wuffs_zlib_decode_10k/clang9 223MB/s ± 0% 212MB/s ± 1% -5.05% (p=0.000 n=7+10)
wuffs_zlib_decode_100k/clang9 280MB/s ± 0% 280MB/s ± 0% ~ (p=0.867 n=8+7)
wuffs_zlib_decode_10k/gcc10 232MB/s ± 2% 220MB/s ± 1% -5.42% (p=0.000 n=10+10)
wuffs_zlib_decode_100k/gcc10 286MB/s ± 5% 277MB/s ± 0% -2.88% (p=0.002 n=10+9)
mimic_zlib_decode_10k 145MB/s ± 0% 266MB/s ± 0% +84.02% (p=0.000 n=10+9)
mimic_zlib_decode_100k 173MB/s ± 1% 265MB/s ± 2% +53.31% (p=0.000 n=10+9)
2021-04-20 23:33:58 +10:00
Nigel Tao
5764f77913
Have std/png produce PIXEL_FORMAT__Y_16LE
...
Updates #46
2021-04-16 14:34:48 +10:00
Nigel Tao
2dddd388bc
Add crc32.ieee_hasher.up_x86_avx2
...
name old speed new speed delta
wuffs_crc32_ieee_10k/clang9 8.42GB/s ± 1% 8.12GB/s ± 1% -3.55% (p=0.000 n=9+8)
wuffs_crc32_ieee_100k/clang9 11.0GB/s ± 1% 10.9GB/s ± 1% ~ (p=0.931 n=9+9)
wuffs_crc32_ieee_10k/gcc10 9.20GB/s ± 0% 9.71GB/s ± 0% +5.54% (p=0.000 n=8+10)
wuffs_crc32_ieee_100k/gcc10 11.9GB/s ± 2% 13.1GB/s ± 1% +10.22% (p=0.000 n=10+8)
wuffs_gzip_decode_10k/clang9 219MB/s ± 1% 218MB/s ± 2% ~ (p=0.497 n=9+10)
wuffs_gzip_decode_100k/clang9 283MB/s ± 2% 281MB/s ± 1% ~ (p=0.063 n=10+10)
wuffs_gzip_decode_10k/gcc10 224MB/s ± 1% 223MB/s ± 1% ~ (p=0.489 n=9+9)
wuffs_gzip_decode_100k/gcc10 285MB/s ± 4% 290MB/s ± 0% +1.68% (p=0.004 n=10+8)
wuffs_png_decode_image_19k_8bpp/clang9 138MB/s ± 2% 138MB/s ± 1% ~ (p=0.156 n=10+9)
wuffs_png_decode_image_40k_24bpp/clang9 171MB/s ± 2% 172MB/s ± 1% ~ (p=0.971 n=10+10)
wuffs_png_decode_image_77k_8bpp/clang9 495MB/s ± 4% 504MB/s ± 1% +1.79% (p=0.000 n=9+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/clang9 457MB/s ± 4% 463MB/s ± 0% +1.35% (p=0.002 n=9+9)
wuffs_png_decode_image_552k_32bpp_verify_checksum/clang9 435MB/s ± 5% 445MB/s ± 1% +2.31% (p=0.000 n=10+9)
wuffs_png_decode_image_4002k_24bpp/clang9 172MB/s ± 2% 174MB/s ± 1% ~ (p=0.053 n=10+9)
wuffs_png_decode_image_19k_8bpp/gcc10 157MB/s ± 1% 157MB/s ± 1% ~ (p=0.549 n=9+10)
wuffs_png_decode_image_40k_24bpp/gcc10 187MB/s ± 1% 186MB/s ± 1% ~ (p=0.182 n=10+9)
wuffs_png_decode_image_77k_8bpp/gcc10 554MB/s ± 1% 559MB/s ± 0% +0.84% (p=0.000 n=9+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/gcc10 502MB/s ± 1% 500MB/s ± 0% -0.38% (p=0.011 n=10+10)
wuffs_png_decode_image_552k_32bpp_verify_checksum/gcc10 481MB/s ± 1% 478MB/s ± 0% -0.46% (p=0.002 n=8+9)
wuffs_png_decode_image_4002k_24bpp/gcc10 189MB/s ± 2% 190MB/s ± 0% +0.62% (p=0.008 n=10+9)
2021-04-09 23:12:32 +10:00
Nigel Tao
1dd7ad4413
Optimize std/deflate decoding for RLE sections
...
name old speed new speed delta
wuffs_deflate_decode_1k_full_init/clang9 104MB/s ± 1% 104MB/s ± 1% ~ (p=0.161 n=9+9)
wuffs_deflate_decode_1k_part_init/clang9 121MB/s ± 1% 119MB/s ± 1% -0.92% (p=0.000 n=9+9)
wuffs_deflate_decode_10k_full_init/clang9 223MB/s ± 1% 223MB/s ± 1% ~ (p=0.796 n=9+9)
wuffs_deflate_decode_10k_part_init/clang9 230MB/s ± 1% 228MB/s ± 2% ~ (p=0.065 n=10+9)
wuffs_deflate_decode_100k_just_one_read/clang9 279MB/s ± 1% 292MB/s ± 0% +4.78% (p=0.000 n=9+8)
wuffs_deflate_decode_100k_many_big_reads/clang9 178MB/s ± 5% 189MB/s ± 2% +6.41% (p=0.000 n=10+10)
wuffs_deflate_decode_1k_full_init/gcc10 103MB/s ± 1% 102MB/s ± 1% -0.57% (p=0.022 n=10+9)
wuffs_deflate_decode_1k_part_init/gcc10 122MB/s ± 1% 121MB/s ± 3% -1.46% (p=0.000 n=10+9)
wuffs_deflate_decode_10k_full_init/gcc10 235MB/s ± 1% 231MB/s ± 1% -1.34% (p=0.000 n=10+8)
wuffs_deflate_decode_10k_part_init/gcc10 242MB/s ± 1% 239MB/s ± 0% -1.40% (p=0.001 n=9+8)
wuffs_deflate_decode_100k_just_one_read/gcc10 300MB/s ± 4% 297MB/s ± 2% ~ (p=0.156 n=10+9)
wuffs_deflate_decode_100k_many_big_reads/gcc10 193MB/s ± 2% 197MB/s ± 1% +2.29% (p=0.000 n=10+9)
wuffs_gzip_decode_10k/clang9 220MB/s ± 1% 219MB/s ± 1% ~ (p=0.605 n=9+9)
wuffs_gzip_decode_100k/clang9 269MB/s ± 2% 283MB/s ± 2% +4.98% (p=0.000 n=9+10)
wuffs_gzip_decode_10k/gcc10 227MB/s ± 1% 224MB/s ± 1% -1.42% (p=0.000 n=10+9)
wuffs_gzip_decode_100k/gcc10 283MB/s ± 1% 285MB/s ± 4% ~ (p=0.182 n=9+10)
wuffs_zlib_decode_10k/clang9 226MB/s ± 1% 220MB/s ± 4% -2.66% (p=0.000 n=9+10)
wuffs_zlib_decode_100k/clang9 272MB/s ± 2% 285MB/s ± 1% +4.77% (p=0.000 n=10+8)
wuffs_zlib_decode_10k/gcc10 227MB/s ± 1% 212MB/s ± 1% -6.80% (p=0.000 n=10+9)
wuffs_zlib_decode_100k/gcc10 282MB/s ± 1% 273MB/s ± 0% -3.32% (p=0.000 n=9+8)
wuffs_png_decode_image_19k_8bpp/clang9 148MB/s ± 1% 138MB/s ± 2% -6.79% (p=0.000 n=9+10)
wuffs_png_decode_image_40k_24bpp/clang9 170MB/s ± 1% 171MB/s ± 2% ~ (p=0.133 n=9+10)
wuffs_png_decode_image_77k_8bpp/clang9 525MB/s ± 1% 495MB/s ± 4% -5.81% (p=0.000 n=8+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/clang9 400MB/s ± 2% 457MB/s ± 4% +14.16% (p=0.000 n=9+9)
wuffs_png_decode_image_552k_32bpp_verify_checksum/clang9 388MB/s ± 1% 435MB/s ± 5% +12.17% (p=0.000 n=9+10)
wuffs_png_decode_image_4002k_24bpp/clang9 175MB/s ± 1% 172MB/s ± 2% -1.78% (p=0.005 n=10+10)
wuffs_png_decode_image_19k_8bpp/gcc10 154MB/s ± 3% 157MB/s ± 1% +1.72% (p=0.001 n=9+9)
wuffs_png_decode_image_40k_24bpp/gcc10 182MB/s ± 1% 187MB/s ± 1% +2.56% (p=0.000 n=9+10)
wuffs_png_decode_image_77k_8bpp/gcc10 552MB/s ± 3% 554MB/s ± 1% ~ (p=0.863 n=9+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/gcc10 426MB/s ± 2% 502MB/s ± 1% +17.85% (p=0.000 n=10+10)
wuffs_png_decode_image_552k_32bpp_verify_checksum/gcc10 410MB/s ± 2% 481MB/s ± 1% +17.17% (p=0.000 n=9+8)
wuffs_png_decode_image_4002k_24bpp/gcc10 186MB/s ± 1% 189MB/s ± 2% +1.33% (p=0.001 n=9+10)
2021-04-09 14:31:52 +10:00
Nigel Tao
a7ef82f7db
Add deflate.decoder.decode_huffman_bmi2
...
Binary size, before:
21864 gen/lib/c/clang-9-dynamic/wuffs-std-deflate.lo
21488 gen/lib/c/clang-9-static/wuffs-std-deflate.o
21136 gen/lib/c/gcc-dynamic/wuffs-std-deflate.lo
21536 gen/lib/c/gcc-static/wuffs-std-deflate.o
After:
24592 gen/lib/c/clang-9-dynamic/wuffs-std-deflate.lo
24368 gen/lib/c/clang-9-static/wuffs-std-deflate.o
23320 gen/lib/c/gcc-dynamic/wuffs-std-deflate.lo
23928 gen/lib/c/gcc-static/wuffs-std-deflate.o
I've upgraded my kernel and compilers recently, so the absolute Wuffs
benchmark numbers below aren't directly comparable to those reported in
previous commits, but the relative changes still seems valid.
On a mid-range x86_64 laptop:
name old speed new speed delta
wuffs_deflate_decode_1k_full_init/clang9 107MB/s ± 1% 104MB/s ± 1% -2.36% (p=0.000 n=8+9)
wuffs_deflate_decode_1k_part_init/clang9 123MB/s ± 1% 121MB/s ± 1% -1.78% (p=0.000 n=10+9)
wuffs_deflate_decode_10k_full_init/clang9 221MB/s ± 2% 223MB/s ± 1% +0.86% (p=0.035 n=10+9)
wuffs_deflate_decode_10k_part_init/clang9 228MB/s ± 0% 230MB/s ± 1% +0.59% (p=0.003 n=8+10)
wuffs_deflate_decode_100k_just_one_read/clang9 276MB/s ± 0% 279MB/s ± 1% +1.12% (p=0.001 n=8+9)
wuffs_deflate_decode_100k_many_big_reads/clang9 174MB/s ± 1% 178MB/s ± 5% +2.38% (p=0.028 n=9+10)
wuffs_deflate_decode_1k_full_init/gcc10 103MB/s ± 3% 103MB/s ± 1% ~ (p=0.105 n=10+10)
wuffs_deflate_decode_1k_part_init/gcc10 123MB/s ± 1% 122MB/s ± 1% -0.94% (p=0.001 n=9+10)
wuffs_deflate_decode_10k_full_init/gcc10 216MB/s ± 2% 235MB/s ± 1% +8.83% (p=0.000 n=10+10)
wuffs_deflate_decode_10k_part_init/gcc10 223MB/s ± 1% 242MB/s ± 1% +8.45% (p=0.000 n=9+9)
wuffs_deflate_decode_100k_just_one_read/gcc10 270MB/s ± 4% 300MB/s ± 4% +11.08% (p=0.000 n=9+10)
wuffs_deflate_decode_100k_many_big_reads/gcc10 179MB/s ± 1% 193MB/s ± 2% +7.97% (p=0.000 n=10+10)
wuffs_gzip_decode_10k/clang9 218MB/s ± 3% 220MB/s ± 1% ~ (p=0.549 n=10+9)
wuffs_gzip_decode_100k/clang9 270MB/s ± 0% 269MB/s ± 2% ~ (p=0.730 n=9+9)
wuffs_gzip_decode_10k/gcc10 208MB/s ± 1% 227MB/s ± 1% +8.87% (p=0.000 n=9+10)
wuffs_gzip_decode_100k/gcc10 267MB/s ± 1% 283MB/s ± 1% +6.05% (p=0.000 n=10+9)
wuffs_zlib_decode_10k/clang9 214MB/s ± 2% 226MB/s ± 1% +5.69% (p=0.000 n=10+9)
wuffs_zlib_decode_100k/clang9 259MB/s ± 6% 272MB/s ± 2% +5.05% (p=0.000 n=9+10)
wuffs_zlib_decode_10k/gcc10 211MB/s ± 1% 227MB/s ± 1% +7.53% (p=0.000 n=10+10)
wuffs_zlib_decode_100k/gcc10 262MB/s ± 1% 282MB/s ± 1% +7.69% (p=0.000 n=10+9)
wuffs_png_decode_image_19k_8bpp/clang9 144MB/s ± 0% 148MB/s ± 1% +2.68% (p=0.000 n=9+9)
wuffs_png_decode_image_40k_24bpp/clang9 166MB/s ± 1% 170MB/s ± 1% +2.38% (p=0.000 n=9+9)
wuffs_png_decode_image_77k_8bpp/clang9 515MB/s ± 1% 525MB/s ± 1% +1.91% (p=0.000 n=9+8)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/clang9 401MB/s ± 1% 400MB/s ± 2% ~ (p=0.913 n=9+9)
wuffs_png_decode_image_552k_32bpp_verify_checksum/clang9 387MB/s ± 1% 388MB/s ± 1% ~ (p=0.546 n=9+9)
wuffs_png_decode_image_4002k_24bpp/clang9 170MB/s ± 3% 175MB/s ± 1% +3.02% (p=0.000 n=9+10)
wuffs_png_decode_image_19k_8bpp/gcc10 143MB/s ± 2% 154MB/s ± 3% +8.32% (p=0.000 n=9+9)
wuffs_png_decode_image_40k_24bpp/gcc10 174MB/s ± 2% 182MB/s ± 1% +4.42% (p=0.000 n=10+9)
wuffs_png_decode_image_77k_8bpp/gcc10 513MB/s ± 2% 552MB/s ± 3% +7.66% (p=0.000 n=10+9)
wuffs_png_decode_image_552k_32bpp_ignore_checksum/gcc10 408MB/s ± 1% 426MB/s ± 2% +4.43% (p=0.000 n=9+10)
wuffs_png_decode_image_552k_32bpp_verify_checksum/gcc10 390MB/s ± 4% 410MB/s ± 2% +5.05% (p=0.000 n=10+9)
wuffs_png_decode_image_4002k_24bpp/gcc10 177MB/s ± 1% 186MB/s ± 1% +5.13% (p=0.000 n=9+9)
2021-04-09 00:06:33 +10:00
Nigel Tao
9b228fab2a
Make deflate.decoder.decode_huffman_fast64 choosy
2021-04-09 00:06:32 +10:00
Nigel Tao
96f097c51f
Fix doc/note/assertions.md typo
2021-04-09 00:06:32 +10:00
Nigel Tao
08f7e3dba4
Merge pull request #45 from landaire/rust-bench-with-iterators
...
Use iterators for converting RGB to BGRA in the Rust PNG benchmark
2021-04-09 00:04:12 +10:00
Nigel Tao
235c9301c3
wuffs gen -version=0.3.0-beta.1
2021-04-05 22:44:12 +10:00
Nigel Tao
c86ac5baef
Add wuffs_base__table__flattened_length
2021-04-03 11:01:46 +11:00
Nigel Tao
314d265fe8
Spin out wuffs_aux Alloc{Pixbuf,Workbuf}Result
2021-04-02 23:57:18 +11:00
Nigel Tao
163bc2626c
Add wuffs_base__pixel_buffer__set_interleaved
2021-04-02 23:15:20 +11:00
Nigel Tao
543ac9af28
Restrict "ignore -Wold-style-cast" to C++
2021-04-02 22:43:55 +11:00
Nigel Tao
c1c8ccbaf2
Add ETC_PIXEL_FORMAT__INDEXED__PALETTE_BYTE_LENGTH
2021-04-02 22:13:33 +11:00
Nigel Tao
a1506ad446
Simplify sdl-imageviewer's SDL pixel format use
2021-04-02 19:40:11 +11:00
Nigel Tao
97e30c29da
Add some more #pragma's for GCC to ignore warnings
2021-04-02 19:21:54 +11:00
Nigel Tao
9b5d9b46ae
Add some virtual destructors
2021-04-02 08:52:49 +11:00
Nigel Tao
38d7548718
Fix WUFFS_BASE__TABLE comment typo
2021-04-01 23:15:18 +11:00
Nigel Tao
3b79564254
Drop redundant DecodeImageCallbacks subclass
2021-04-01 23:12:55 +11:00
Nigel Tao
10850c17bc
Add example/sdl-imageviewer
2021-04-01 23:08:49 +11:00
Nigel Tao
ed67eb86f2
Have release/c/README.md link to the mirror
2021-03-31 16:45:21 +11:00
Nigel Tao
57ad55355b
Have wuffs_aux SelectPixfmt default to BGRA_PREMUL
2021-03-29 22:06:39 +11:00
Nigel Tao
decb64e5ea
Add ast.ExprOperatorEtc constants
2021-03-29 19:54:51 +11:00
Nigel Tao
41e407a774
Add some ast.Expr.IsEtc methods
2021-03-28 23:07:21 +11:00
Nigel Tao
b645180357
Drop pixel_swizzler__bgr__etc d[3] assignment
...
Updates https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=32451
2021-03-26 13:51:27 +11:00
Nigel Tao
77bbe685bf
Update doc/roadmap.md
2021-03-25 23:05:54 +11:00
Nigel Tao
3f262b2121
Drop obsolete etc_8_byte_chunks_fast comment
2021-03-25 22:43:54 +11:00
Nigel Tao
ad40102c5a
Change mimic marker symbol from "!!" to "¿"
2021-03-25 22:22:27 +11:00
Nigel Tao
bb2e9e90b5
Change cgen marker symbol from "!!" to "¡"
2021-03-25 22:17:26 +11:00
Nigel Tao
61635213cd
Add "‼" to "WUFFS C HEADER ENDS HERE" comment
2021-03-25 14:11:23 +11:00
Nigel Tao
5adb0d3c80
Add "WUFFS MULTI-FILE SECTION" comments
2021-03-25 14:02:04 +11:00
Nigel Tao
7a73708a56
Have script/bench-*-png convert to BGRA
...
On a mid-range x86_64 laptop:
Compared to the previous commit:
go_decode_19k_8bpp 39.3MB/s ± 1% 39.4MB/s ± 1% ~ (p=0.548 n=5+5)
go_decode_40k_24bpp 46.5MB/s ± 1% 46.7MB/s ± 1% ~ (p=0.095 n=5+5)
go_decode_77k_8bpp 78.3MB/s ± 0% 78.3MB/s ± 0% ~ (p=0.286 n=4+5)
go_decode_552k_32bpp_verify_checksum 120MB/s ± 1% 118MB/s ± 0% ~ (p=0.056 n=5+5)
go_decode_4002k_24bpp 50.7MB/s ± 0% 50.5MB/s ± 0% -0.58% (p=0.016 n=5+4)
rust_decode_19k_8bpp 88.3MB/s ± 0% 89.8MB/s ± 0% +1.76% (p=0.008 n=5+5)
rust_decode_40k_24bpp 133MB/s ± 0% 122MB/s ± 0% -8.58% (p=0.008 n=5+5)
rust_decode_77k_8bpp 180MB/s ± 0% 158MB/s ± 0% -12.04% (p=0.008 n=5+5)
rust_decode_552k_32bpp_verify_checksum 146MB/s ± 0% 136MB/s ± 0% -6.59% (p=0.016 n=4+5)
rust_decode_4002k_24bpp 134MB/s ± 0% 122MB/s ± 0% -9.02% (p=0.008 n=5+5)
Compared to libpng (the C library):
libpng_decode_19k_8bpp 58.0MB/s ± 0% 1.00x
libpng_decode_40k_24bpp 73.1MB/s ± 0% 1.00x
libpng_decode_77k_8bpp 177MB/s ± 0% 1.00x
libpng_decode_552k_32bpp_verify_checksum 146MB/s ± 0% 1.00x
libpng_decode_4002k_24bpp 104MB/s ± 0% 1.00x
go_decode_19k_8bpp/go1.16 39.4MB/s ± 1% 0.68x
go_decode_40k_24bpp/go1.16 46.7MB/s ± 1% 0.64x
go_decode_77k_8bpp/go1.16 78.3MB/s ± 0% 0.44x
go_decode_552k_32bpp_verify_checksum/go1.16 118MB/s ± 0% 0.81x
go_decode_4002k_24bpp/go1.16 50.5MB/s ± 0% 0.49x
rust_decode_19k_8bpp/rust1.48 89.8MB/s ± 0% 1.55x
rust_decode_40k_24bpp/rust1.48 122MB/s ± 0% 1.67x
rust_decode_77k_8bpp/rust1.48 158MB/s ± 0% 0.89x
rust_decode_552k_32bpp_verify_checksum/rust1.48 136MB/s ± 0% 0.93x
rust_decode_4002k_24bpp/rust1.48 122MB/s ± 0% 1.17x
2021-03-25 12:38:02 +11:00
Nigel Tao
5dd7ede975
Add more png benchmarks for alternative mimic libs
...
On a mid-range x86_64 laptop:
"libpng" (Debian's /usr/lib/x86_64-linux-gnu/libpng16.so) numbers are
used as a 1.00x baseline for the other libraries.
(†): libpng's "simplified API" doesn't provide a way to ignore the
checksum. We copy the "verify_checksum" numbers for a 1.00x baseline.
Some of the other libraries don't have the option to ignore or verify
the checksum, always doing only one or the other.
----
libpng_decode_19k_8bpp 58.0MB/s ± 0% 1.00x
libpng_decode_40k_24bpp 73.1MB/s ± 0% 1.00x
libpng_decode_77k_8bpp 177MB/s ± 0% 1.00x
libpng_decode_552k_32bpp_ignore_checksum 146MB/s ± 0% (†)
libpng_decode_552k_32bpp_verify_checksum 146MB/s ± 0% 1.00x
libpng_decode_4002k_24bpp 104MB/s ± 0% 1.00x
----
wuffs_decode_19k_8bpp/clang9 131MB/s ± 0% 2.26x
wuffs_decode_40k_24bpp/clang9 153MB/s ± 0% 2.09x
wuffs_decode_77k_8bpp/clang9 472MB/s ± 0% 2.67x
wuffs_decode_552k_32bpp_ignore_checksum/clang9 370MB/s ± 0% 2.53x
wuffs_decode_552k_32bpp_verify_checksum/clang9 357MB/s ± 0% 2.45x
wuffs_decode_4002k_24bpp/clang9 156MB/s ± 0% 1.50x
wuffs_decode_19k_8bpp/gcc10 136MB/s ± 1% 2.34x
wuffs_decode_40k_24bpp/gcc10 162MB/s ± 0% 2.22x
wuffs_decode_77k_8bpp/gcc10 486MB/s ± 0% 2.75x
wuffs_decode_552k_32bpp_ignore_checksum/gcc10 388MB/s ± 0% 2.66x
wuffs_decode_552k_32bpp_verify_checksum/gcc10 373MB/s ± 0% 2.55x
wuffs_decode_4002k_24bpp/gcc10 164MB/s ± 0% 1.58x
----
libspng_decode_19k_8bpp/clang9 59.3MB/s ± 0% 1.02x
libspng_decode_40k_24bpp/clang9 78.4MB/s ± 0% 1.07x
libspng_decode_77k_8bpp/clang9 189MB/s ± 0% 1.07x
libspng_decode_552k_32bpp_ignore_checksum/clang9 236MB/s ± 0% 1.62x
libspng_decode_552k_32bpp_verify_checksum/clang9 203MB/s ± 0% 1.39x
libspng_decode_4002k_24bpp/clang9 110MB/s ± 0% 1.06x
libspng_decode_19k_8bpp/gcc10 59.6MB/s ± 0% 1.03x
libspng_decode_40k_24bpp/gcc10 77.5MB/s ± 0% 1.06x
libspng_decode_77k_8bpp/gcc10 189MB/s ± 0% 1.07x
libspng_decode_552k_32bpp_ignore_checksum/gcc10 223MB/s ± 0% 1.53x
libspng_decode_552k_32bpp_verify_checksum/gcc10 194MB/s ± 0% 1.33x
libspng_decode_4002k_24bpp/gcc10 109MB/s ± 0% 1.05x
----
lodepng_decode_19k_8bpp/clang9 65.1MB/s ± 0% 1.12x
lodepng_decode_40k_24bpp/clang9 72.1MB/s ± 0% 0.99x
lodepng_decode_77k_8bpp/clang9 222MB/s ± 0% 1.25x
lodepng_decode_552k_32bpp_ignore_checksum/clang9 skipped
lodepng_decode_552k_32bpp_verify_checksum/clang9 162MB/s ± 0% 1.11x
lodepng_decode_4002k_24bpp/clang9 70.5MB/s ± 0% 0.68x
lodepng_decode_19k_8bpp/gcc10 61.1MB/s ± 0% 1.05x
lodepng_decode_40k_24bpp/gcc10 62.5MB/s ± 1% 0.85x
lodepng_decode_77k_8bpp/gcc10 176MB/s ± 0% 0.99x
lodepng_decode_552k_32bpp_ignore_checksum/gcc10 skipped
lodepng_decode_552k_32bpp_verify_checksum/gcc10 139MB/s ± 0% 0.95x
lodepng_decode_4002k_24bpp/gcc10 62.3MB/s ± 0% 0.60x
----
stbimage_decode_19k_8bpp/clang9 75.1MB/s ± 1% 1.29x
stbimage_decode_40k_24bpp/clang9 84.6MB/s ± 0% 1.16x
stbimage_decode_77k_8bpp/clang9 234MB/s ± 0% 1.32x
stbimage_decode_552k_32bpp_ignore_checksum/clang9 162MB/s ± 0% 1.11x
stbimage_decode_552k_32bpp_verify_checksum/clang9 skipped
stbimage_decode_4002k_24bpp/clang9 80.7MB/s ± 0% 0.78x
stbimage_decode_19k_8bpp/gcc10 73.3MB/s ± 0% 1.26x
stbimage_decode_40k_24bpp/gcc10 81.8MB/s ± 0% 1.12x
stbimage_decode_77k_8bpp/gcc10 214MB/s ± 0% 1.21x
stbimage_decode_552k_32bpp_ignore_checksum/gcc10 145MB/s ± 0% 0.99x
stbimage_decode_552k_32bpp_verify_checksum/gcc10 skipped
stbimage_decode_4002k_24bpp/gcc10 79.7MB/s ± 0% 0.77x
----
go_decode_19k_8bpp/go1.16 39.3MB/s ± 1% 0.68x
go_decode_40k_24bpp/go1.16 46.5MB/s ± 1% 0.64x
go_decode_77k_8bpp/go1.16 78.3MB/s ± 0% 0.44x
go_decode_552k_32bpp_ignore_checksum/go1.16 skipped
go_decode_552k_32bpp_verify_checksum/go1.16 120MB/s ± 1% 0.82x
go_decode_4002k_24bpp/go1.16 50.7MB/s ± 0% 0.49x
----
rust_decode_19k_8bpp/rust1.48 88.3MB/s ± 0% 1.52x
rust_decode_40k_24bpp/rust1.48 133MB/s ± 0% 1.82x
rust_decode_77k_8bpp/rust1.48 180MB/s ± 0% 1.02x
rust_decode_552k_32bpp_ignore_checksum/rust1.48 skipped
rust_decode_552k_32bpp_verify_checksum/rust1.48 146MB/s ± 0% 1.00x
rust_decode_4002k_24bpp/rust1.48 134MB/s ± 0% 1.29x
2021-03-24 23:36:48 +11:00
Nigel Tao
dba914c5bd
Link pixel_swizzler tests to pixel_swizzler_fuzzer
2021-03-22 23:26:52 +11:00
Nigel Tao
13f9ecec68
Have pixel_swizzler_fuzzer use no-r/w guard pages
2021-03-22 23:20:30 +11:00
Nigel Tao
41bfcabd3a
Add fuzz/c/std/pixel_swizzler_fuzzer.c
2021-03-22 14:02:39 +11:00
Nigel Tao
a5de5fc1cd
Link pixel_swizzler tests to aux's SelectPixfmt
2021-03-21 22:22:13 +11:00
Nigel Tao
df5bb599a7
Swizzler support src_pixfmt = BGR_565
...
Binary size, before:
59472 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
62072 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
102936 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
102904 gen/lib/c/gcc-static/wuffs-base-pixconv.o
After:
66064 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
68768 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
109256 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
109208 gen/lib/c/gcc-static/wuffs-base-pixconv.o
2021-03-21 22:15:33 +11:00
Nigel Tao
15b04e65f3
Swizzler support src_pixfmt = RGBA_PREMUL
...
Binary size, before:
55392 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
57880 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
96816 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
96736 gen/lib/c/gcc-static/wuffs-base-pixconv.o
After:
59472 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
62072 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
102936 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
102904 gen/lib/c/gcc-static/wuffs-base-pixconv.o
2021-03-21 21:49:53 +11:00
Nigel Tao
17ae882a96
Swizzler support src_pixfmt = BGRA_PREMUL
...
Binary size, before:
48632 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
50784 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
82936 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
82920 gen/lib/c/gcc-static/wuffs-base-pixconv.o
After:
55392 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
57880 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
96816 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
96736 gen/lib/c/gcc-static/wuffs-base-pixconv.o
2021-03-21 21:27:51 +11:00
Nigel Tao
bdb45036a9
Swizzler support dst_pixfmt BGRA_NONPREMUL_4X16LE
...
Binary size, before:
41496 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
43104 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
72344 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
72328 gen/lib/c/gcc-static/wuffs-base-pixconv.o
After:
48632 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
50784 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
82936 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
82920 gen/lib/c/gcc-static/wuffs-base-pixconv.o
2021-03-20 17:01:41 +11:00
Nigel Tao
3b6b5ad486
Swizzler support dst_pixfmt = RGBA_{NON,}PREMUL
...
Binary size, before:
37856 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
39552 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
64536 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
64488 gen/lib/c/gcc-static/wuffs-base-pixconv.o
After:
41496 gen/lib/c/clang-9-dynamic/wuffs-base-pixconv.lo
43104 gen/lib/c/clang-9-static/wuffs-base-pixconv.o
72344 gen/lib/c/gcc-dynamic/wuffs-base-pixconv.lo
72328 gen/lib/c/gcc-static/wuffs-base-pixconv.o
2021-03-19 18:52:56 +11:00
Nigel Tao
f49c382029
wuffs gen -version=0.3.0-alpha.21
2021-03-18 12:11:20 +11:00
Nigel Tao
8d90971782
Bump "MSVC+X64 needs /arch:AVX" from error to warn
2021-03-18 12:09:22 +11:00
Nigel Tao
cbc072e776
Include <immintrin.h> etc for MSVC+X64
2021-03-18 11:50:05 +11:00
Nigel Tao
b24e046670
Replace SIMD CRC-32 k6' magic constant with Px'
...
This is just a change of name (and a change of comment), not a change of
value.
From my colleague, Eric Biggers:
The number is not k6' = (x^32 mod P(x) << 32)' << 1 = 0x1DB710640, but
rather P(x)' = 0x1DB710641. This value represents the generator
polynomial of CRC-32 as a 33-bit value, using the CRC-32 bit ordering
convention (lowest order bit = coefficient of highest order polynomial
term). The lowest order bit is the coefficient of x^32, which by
definition is 1 for CRC-32. P(x) is used as a multiplicand in Barrett
reduction, which is the step which reduces a 64-bit value to the final
32-bit remainder. See "Algorithm 1" in the Gopal paper.
The reason that last bit doesn't actually matter is because the output
of the Barrett reduction is supposed to be fully reduced mod P(x), so
only 32 bits (the bits that represent the coefficients of x^0..x^31) are
supposed to be able to be nonzero. Therefore, in practice
implementations will just truncate the result to 32 bits. Incorrectly
using 0x1DB710640 rather than P(x) = 0x1DB710641 only causes the result
to be wrong by a factor of x^32, so it doesn't affect those 32 bits.
2021-03-18 11:21:51 +11:00
Nigel Tao
16b4b7554b
Link to SIMD CRC-32 k6' magic constant blog post
2021-03-18 11:06:21 +11:00
Nigel Tao
8d1650117f
wuffs gen -version=0.3.0-alpha.20
2021-03-17 12:08:15 +11:00
Nigel Tao
9914f7314d
Add WUFFS_BASE__MAYBE_ATTRIBUTE_TARGET
2021-03-17 12:03:06 +11:00
Nigel Tao
073d3e0150
wuffs gen -version=0.3.0-alpha.19
2021-03-16 12:22:28 +11:00
Nigel Tao
85bdcd1e1e
Fix script/benchstat-ratio.go when there's no '/'
2021-03-13 22:40:37 +11:00
Nigel Tao
3e5afc3e52
Remove png_fuzzer "smoke alarm test"
...
Updates https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=31984
2021-03-13 13:39:35 +11:00
Nigel Tao
ee62582609
Tweak some mimic bench names for benchstat-ratio
2021-03-13 13:31:41 +11:00
Nigel Tao
9e4c87b6ab
Add script/benchstat-ratio.go
2021-03-13 00:11:50 +11:00
Nigel Tao
cbc1367a0f
Add more pixel_buffer fill_rect cases
2021-03-11 23:57:41 +11:00
Nigel Tao
a04fda42d6
Update doc/std/image-decoders.md
2021-03-11 23:04:53 +11:00
Nigel Tao
385c34930a
Check 8-byte-chunk copy distance precondition
2021-03-11 22:54:06 +11:00
Nigel Tao
5767f030a3
Add DecodeImageCallbacks::SelectPixfmt
2021-03-11 16:25:16 +11:00
Nigel Tao
441e96a8d4
Add pixel_buffer.set_color_u32_fill_rect
2021-03-11 15:53:09 +11:00
Nigel Tao
2e0f2a68be
Add doc/std/README.md "Modules and Dependencies"
2021-03-11 12:38:58 +11:00
Nigel Tao
1daace6342
Add DecodeImageCallbacks::OnImageFormat def impl
2021-03-11 12:04:00 +11:00
Nigel Tao
54175156bd
Add more wuffs_aux::DecodeImage comments
2021-03-11 11:28:50 +11:00
Nigel Tao
49c5692c32
Add png_fuzzer "smoke alarm test"
2021-03-11 11:05:20 +11:00
Nigel Tao
f2ed33375c
Gate wuffs_aux on WUFFS_BASE__HAVE_UNIQUE_PTR
2021-03-11 10:52:49 +11:00