[llvm-bugs] [Bug 28115] New: Sanitizer_common_interceptors_ioctl.inc:586 taking address of packed member

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jun 13 14:24:44 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=28115

            Bug ID: 28115
           Summary: Sanitizer_common_interceptors_ioctl.inc:586 taking
                    address of packed member
           Product: compiler-rt
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: compiler-rt
          Assignee: unassignedbugs at nondot.org
          Reporter: aprantl at apple.com
                CC: llvm-bugs at lists.llvm.org
    Classification: Unclassified

CFE r272552 added a new warning on taking the address of a packed member.
This warning triggers on the address sanitizer code in compiler-rt:

[2689/2718] Building CXX object
lib/tsan/CMakeFiles/clang_rt.tsan_osx_dynamic.dir/rtl/tsan_interface_atomic.cc.o
/Users/buildslave/jenkins/sharedspace/clang-stage1 at 2/clang/src/projects/compiler-rt/lib/tsan/../sanitizer_common/sanitizer_common_interceptors_ioctl.inc:586:40:
warning: taking address of packed member 'ifc_len' of class or structure
'__sanitizer::__sanitizer_ifconf' may result in an unaligned pointer value
[-Waddress-of-packed-member]
    COMMON_INTERCEPTOR_READ_RANGE(ctx, &ifc->ifc_len, sizeof(ifc->ifc_len));
                                       ^~~~~~~~~~~~~
/Users/buildslave/jenkins/sharedspace/clang-stage1 at 2/clang/src/projects/compiler-rt/lib/tsan/rtl/tsan_interceptors.cc:2189:66:
note: expanded from macro 'COMMON_INTERCEPTOR_READ_RANGE'
                    ((TsanInterceptorContext *) ctx)->pc, (uptr) ptr, size, \
                                                                 ^~~
1 warning generated.

-- 
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/20160613/c2654343/attachment.html>


More information about the llvm-bugs mailing list