[PATCH][compiler-rt] Fix global constructor warning in sanitizer.

Kostya Serebryany kcc at google.com
Tue Sep 16 14:00:06 PDT 2014


On Tue, Sep 16, 2014 at 12:51 PM, Samuel F Antao <sfantao at us.ibm.com> wrote:

> Hi Kostya,
>
> Thanks for reviewing the patch. I currently do not have commit privileges,
> do I need to take any action for the patch to be committed?
>
Ok. committed as r217904.
Thanks!

--kcc


>
>
> Thanks,
> Sam
>
> [image: Inactive hide details for Kostya Serebryany ---09/15/2014 04:51:12
> PM---LGTM On Wed, Sep 10, 2014 at 4:32 PM, Samuel F Antao <s]Kostya
> Serebryany ---09/15/2014 04:51:12 PM---LGTM On Wed, Sep 10, 2014 at 4:32
> PM, Samuel F Antao <sfantao at us.ibm.com> wrote:
>
> From: Kostya Serebryany <kcc at google.com>
> To: Samuel F Antao/Watson/IBM at IBMUS
> Cc: Commit Messages and Patches for LLVM <llvm-commits at cs.uiuc.edu>
> Date: 09/15/2014 04:51 PM
> Subject: Re: [PATCH][compiler-rt] Fix global constructor warning in
> sanitizer.
> ------------------------------
>
>
>
> LGTM
>
> On Wed, Sep 10, 2014 at 4:32 PM, Samuel F Antao <*sfantao at us.ibm.com*
> <sfantao at us.ibm.com>> wrote:
>
>    Hi all,
>
>    If EV_VERSION > 0x010000 is not true, the compilation of
>    sanitizer_platform_limits_posix.cc returns the warnings:
>
>    .../projects/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc:757:12:
>    warning: declaration requires a global constructor [-Wglobal-constructors]
>      unsigned IOCTL_EVIOCGKEYCODE_V2 = IOCTL_NOT_PRESENT;
>               ^                        ~~~~~~~~~~~~~~~~~
>    .../projects/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc:758:12:
>    warning: declaration requires a global constructor [-Wglobal-constructors]
>      unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
>               ^                  ~~~~~~~~~~~~~~~~~
>    .../projects/compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cc:759:12:
>    warning: declaration requires a global constructor [-Wglobal-constructors]
>      unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
>               ^                        ~~~~~~~~~~~~~~~~~
>    3 warnings generated.
>
>    This patch fixes the issue by adding the const attribute to
>    IOCTL_NOT_PRESENT.
>
>    The modified files are the following:
>    sanitizer_platform_limits_posix.cc
>    sanitizer_platform_limits_posix.h
>
>
>    Thanks,
>    Sam
>
> * (See attached file: crt_ioctl_not_present_fix.patch)*
>
>    _______________________________________________
>    llvm-commits mailing list
> *llvm-commits at cs.uiuc.edu* <llvm-commits at cs.uiuc.edu>
> *http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits*
>    <http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140916/f6d3fa34/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: graycol.gif
Type: image/gif
Size: 105 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140916/f6d3fa34/attachment.gif>


More information about the llvm-commits mailing list