mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-26 01:01:35 +01:00
Roll dst_palette into the pixel_swizzler struct
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. name old speed new speed delta wuffs_gif_decode_1k_bw/clang5 286MB/s ± 1% 251MB/s ± 0% -12.11% (p=0.000 n=10+9) wuffs_gif_decode_1k_color_full_init/clang5 96.0MB/s ± 0% 88.9MB/s ± 0% -7.35% (p=0.000 n=10+10) wuffs_gif_decode_1k_color_part_init/clang5 119MB/s ± 0% 108MB/s ± 0% -9.06% (p=0.000 n=10+8) wuffs_gif_decode_10k_bgra/clang5 469MB/s ± 1% 438MB/s ± 0% -6.50% (p=0.000 n=10+8) wuffs_gif_decode_10k_indexed/clang5 125MB/s ± 1% 117MB/s ± 1% -6.78% (p=0.000 n=9+9) wuffs_gif_decode_20k/clang5 153MB/s ± 0% 139MB/s ± 0% -9.40% (p=0.000 n=9+9) wuffs_gif_decode_100k_artificial/clang5 324MB/s ± 0% 304MB/s ± 0% -6.22% (p=0.000 n=10+9) wuffs_gif_decode_100k_realistic/clang5 139MB/s ± 1% 125MB/s ± 1% -9.69% (p=0.000 n=9+10) wuffs_gif_decode_1000k_full_init/clang5 141MB/s ± 0% 126MB/s ± 0% -10.40% (p=0.000 n=10+10) wuffs_gif_decode_1000k_part_init/clang5 141MB/s ± 1% 126MB/s ± 0% -10.50% (p=0.000 n=10+8) wuffs_gif_decode_anim_screencap/clang5 655MB/s ± 0% 617MB/s ± 1% -5.91% (p=0.000 n=9+9) wuffs_gif_decode_1k_bw/gcc7 299MB/s ± 0% 295MB/s ± 0% -1.18% (p=0.000 n=10+8) wuffs_gif_decode_1k_color_full_init/gcc7 85.2MB/s ± 1% 88.2MB/s ± 0% +3.58% (p=0.000 n=10+10) wuffs_gif_decode_1k_color_part_init/gcc7 104MB/s ± 0% 103MB/s ± 0% -0.39% (p=0.001 n=9+10) wuffs_gif_decode_10k_bgra/gcc7 349MB/s ± 2% 352MB/s ± 0% +0.77% (p=0.000 n=9+10) wuffs_gif_decode_10k_indexed/gcc7 106MB/s ± 0% 106MB/s ± 2% ~ (p=0.762 n=8+10) wuffs_gif_decode_20k/gcc7 133MB/s ± 0% 133MB/s ± 0% ~ (p=0.258 n=9+9) wuffs_gif_decode_100k_artificial/gcc7 302MB/s ± 0% 301MB/s ± 1% -0.41% (p=0.035 n=10+10) wuffs_gif_decode_100k_realistic/gcc7 118MB/s ± 1% 118MB/s ± 1% ~ (p=0.095 n=9+10) wuffs_gif_decode_1000k_full_init/gcc7 120MB/s ± 1% 119MB/s ± 0% -0.34% (p=0.007 n=10+10) wuffs_gif_decode_1000k_part_init/gcc7 119MB/s ± 1% 119MB/s ± 1% ~ (p=0.138 n=10+10) wuffs_gif_decode_anim_screencap/gcc7 640MB/s ± 0% 640MB/s ± 0% ~ (p=0.905 n=9+10)
This commit is contained in:
1 parent
3afdd91acb
commit
2d8ec9ace9
9 files changed
+236
-310
No files matched your search
@@ -1287,16 +1287,16 @@ wuffs_base__pixel_palette__closest_element(
|
||||
// --------
|
||||
|
||||
// TODO: should the func type take restrict pointers?
|
||||
typedef uint64_t (*wuffs_base__pixel_swizzler__func)(
|
||||
wuffs_base__slice_u8 dst,
|
||||
wuffs_base__slice_u8 dst_palette,
|
||||
wuffs_base__slice_u8 src);
|
||||
typedef uint64_t (*wuffs_base__pixel_swizzler__func)(const uint8_t* scratch1024,
|
||||
wuffs_base__slice_u8 dst,
|
||||
wuffs_base__slice_u8 src);
|
||||
|
||||
typedef struct {
|
||||
// Do not access the private_impl's fields directly. There is no API/ABI
|
||||
// compatibility or safety guarantee if you do so.
|
||||
struct {
|
||||
wuffs_base__pixel_swizzler__func func;
|
||||
uint8_t scratch1024[1024];
|
||||
} private_impl;
|
||||
|
||||
#ifdef __cplusplus
|
||||
@@ -1306,7 +1306,6 @@ typedef struct {
|
||||
wuffs_base__slice_u8 src_palette,
|
||||
wuffs_base__pixel_blend blend);
|
||||
inline uint64_t swizzle_interleaved(wuffs_base__slice_u8 dst,
|
||||
wuffs_base__slice_u8 dst_palette,
|
||||
wuffs_base__slice_u8 src) const;
|
||||
#endif // __cplusplus
|
||||
|
||||
@@ -1336,7 +1335,6 @@ WUFFS_BASE__MAYBE_STATIC uint64_t //
|
||||
wuffs_base__pixel_swizzler__swizzle_interleaved(
|
||||
const wuffs_base__pixel_swizzler* p,
|
||||
wuffs_base__slice_u8 dst,
|
||||
wuffs_base__slice_u8 dst_palette,
|
||||
wuffs_base__slice_u8 src);
|
||||
|
||||
#ifdef __cplusplus
|
||||
@@ -1354,10 +1352,8 @@ wuffs_base__pixel_swizzler::prepare(wuffs_base__pixel_format dst_format,
|
||||
uint64_t //
|
||||
wuffs_base__pixel_swizzler::swizzle_interleaved(
|
||||
wuffs_base__slice_u8 dst,
|
||||
wuffs_base__slice_u8 dst_palette,
|
||||
wuffs_base__slice_u8 src) const {
|
||||
return wuffs_base__pixel_swizzler__swizzle_interleaved(this, dst, dst_palette,
|
||||
src);
|
||||
return wuffs_base__pixel_swizzler__swizzle_interleaved(this, dst, src);
|
||||
}
|
||||
|
||||
#endif // __cplusplus
|
||||
Reference in new issue
Block a user