diff options
author | Alexander Potapenko <[email protected]> | 2022-12-05 15:57:40 +0100 |
---|---|---|
committer | Andrew Morton <[email protected]> | 2022-12-11 18:12:21 -0800 |
commit | 5478afc55a2104caaef5b78c7c1f9acb9ec1f92a (patch) | |
tree | d69444d2dd641b8f0006f7030c257a024e44deef /lib/mpi/mpi-sub-ui.c | |
parent | de2e5171433126d340573cb7d0d4fcac084ab2a0 (diff) |
kmsan: fix memcpy tests
Recent Clang changes may cause it to delete calls of memcpy(), if the
source is an uninitialized volatile local. This happens because passing a
pointer to a volatile local into memcpy() discards the volatile qualifier,
giving the compiler a free hand to optimize the memcpy() call away.
Use OPTIMIZER_HIDE_VAR() to hide the uninitialized var from the too-smart
compiler.
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Alexander Potapenko <[email protected]>
Suggested-by: Marco Elver <[email protected]>
Reviewed-by: Marco Elver <[email protected]>
Cc: Dmitry Vyukov <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Diffstat (limited to 'lib/mpi/mpi-sub-ui.c')
0 files changed, 0 insertions, 0 deletions