diff options
author | Kees Cook <[email protected]> | 2023-11-04 13:43:37 -0700 |
---|---|---|
committer | Kees Cook <[email protected]> | 2023-11-08 14:18:57 -0800 |
commit | 1ee60356c2dca938362528404af95b8ef3e49b6a (patch) | |
tree | 8935decb627a6ab44146fd874147dd8240e82ccb /tools/perf/scripts/python/Perf-Trace-Util/lib | |
parent | 65120498aaf8d7320647a8b6d6de7db42e74ea52 (diff) |
gcc-plugins: randstruct: Only warn about true flexible arrays
The randstruct GCC plugin tried to discover "fake" flexible arrays
to issue warnings about them in randomized structs. In the future
LSM overhead reduction series, it would be legal to have a randomized
struct with a 1-element array, and this should _not_ be treated as a
flexible array, especially since commit df8fc4e934c1 ("kbuild: Enable
-fstrict-flex-arrays=3"). Disable the 0-sized and 1-element array
discovery logic in the plugin, but keep the "true" flexible array check.
Cc: KP Singh <[email protected]>
Cc: [email protected]
Reported-by: kernel test robot <[email protected]>
Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
Fixes: df8fc4e934c1 ("kbuild: Enable -fstrict-flex-arrays=3")
Reviewed-by: Bill Wendling <[email protected]>
Acked-by: "Gustavo A. R. Silva" <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Kees Cook <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/Perf-Trace-Util/lib')
0 files changed, 0 insertions, 0 deletions