[llvm-bugs] [Bug 52385] New: UBSAN in ./compiler-rt/lib/asan/asan_allocator.cpp
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Nov 3 05:47:45 PDT 2021
https://bugs.llvm.org/show_bug.cgi?id=52385
Bug ID: 52385
Summary: UBSAN in ./compiler-rt/lib/asan/asan_allocator.cpp
Product: compiler-rt
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: asan
Assignee: unassignedbugs at nondot.org
Reporter: mliska at suse.cz
CC: llvm-bugs at lists.llvm.org
I noticed the 2 following warnings on i686:
/home/marxin/Programming/gcc/libsanitizer/asan/asan_allocator.cpp: In member
function ‘__sanitizer::uptr __asan::ChunkHeader::UsedSize() const’:
/home/marxin/Programming/gcc/libsanitizer/asan/asan_allocator.cpp:107:41:
warning: left shift count >= width of type [-Wshift-count-overflow]
107 | R += (uptr)user_requested_size_hi << (8 *
sizeof(user_requested_size_lo));
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/marxin/Programming/gcc/libsanitizer/asan/asan_allocator.cpp: In member
function ‘void __asan::ChunkHeader::SetUsedSize(__sanitizer::uptr)’:
/home/marxin/Programming/gcc/libsanitizer/asan/asan_allocator.cpp:114:12:
warning: right shift count >= width of type [-Wshift-count-overflow]
114 | size >>= (8 * sizeof(user_requested_size_lo));
| ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20211103/19c31b59/attachment.html>
More information about the llvm-bugs
mailing list