Thread (9 messages) 9 messages, 4 authors, 2023-06-20

Re: [PATCH] sunrpc: fix clang-17 warning

From: Dmitry Antipov <hidden>
Date: 2023-06-01 17:06:35

On 6/1/23 19:39, Dan Carpenter wrote:
It's a false positive because the test is obviously intended for 32-bit
longs.
I'm not an expert in compiler development, but I do not understand
"obviously intended" in this context. An input literally compares
<any unsigned 32-bit> > <max unsigned 64-bit> / 8, which is always
false, and so the compiler complains. If "obviously intended" means
"the compiler should silently optimize away this check for LP64",
I would disagree, and that's why I would like to see the confirmation
from LLVM/clang developers.

Dmitry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help