gcc 11 warns: ../src/util/format/u_format_fxt1.c:940:22: warning: ‘fxt1_variance.constprop’ accessing 128 bytes in a region of size 64 [-Wstringop-overflow=] 940 | int32_t maxVarR = fxt1_variance(NULL, &input[N_TEXELS / 2], n_comp); But, suspiciously, if you inline fxt1_variance the warning goes away. What's happening is that the 2nd arg is uint8_t[N_TEXELS][MAX_COMP], so it looks like we're passing too small of an array in since gcc knows that `input` is also [N_TEXELS][MAX_COMP]. Fair enough. Fix the signature to reflect what's actually going on, and remove some unused arguments while we're at it. Reviewed-by: Matt Turner <mattst88@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10671> |
||
|---|---|---|
| .. | ||
| format_utils.h | ||
| meson.build | ||
| u_format.c | ||
| u_format.csv | ||
| u_format.h | ||
| u_format_bptc.c | ||
| u_format_bptc.h | ||
| u_format_etc.c | ||
| u_format_etc.h | ||
| u_format_fxt1.c | ||
| u_format_fxt1.h | ||
| u_format_latc.c | ||
| u_format_latc.h | ||
| u_format_other.c | ||
| u_format_other.h | ||
| u_format_pack.py | ||
| u_format_parse.py | ||
| u_format_rgtc.c | ||
| u_format_rgtc.h | ||
| u_format_s3tc.c | ||
| u_format_s3tc.h | ||
| u_format_table.py | ||
| u_format_tests.c | ||
| u_format_tests.h | ||
| u_format_unpack_neon.c | ||
| u_format_yuv.c | ||
| u_format_yuv.h | ||
| u_format_zs.c | ||
| u_format_zs.h | ||