This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: libsanitizer merge from upstream r191666
- From: Konstantin Serebryany <konstantin dot s dot serebryany at gmail dot com>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>, Jakub Jelinek <jakub at redhat dot com>, Dodji Seketeli <dodji at redhat dot com>, Dmitry Vyukov <dvyukov at google dot com>, Diego Novillo <dnovillo at google dot com>, David Li <davidxl at google dot com>
- Date: Mon, 14 Oct 2013 15:38:04 +0400
- Subject: Re: libsanitizer merge from upstream r191666
- Authentication-results: sourceware.org; auth=none
- References: <CAGQ9bdzrx07_OfvCcxm_uFUt3MRhg1gwqdHvmK_9kHDmz1vPVw at mail dot gmail dot com> <CAGQ9bdxj-DmEaoo0mOWfSVXsrhVShWj3onHZRxiwt97Vq6J45w at mail dot gmail dot com>
+dnovillo, davidxl
Any suggestions?
On Wed, Oct 2, 2013 at 12:54 PM, Konstantin Serebryany
<konstantin.s.serebryany@gmail.com> wrote:
> <re-sending with compressed patch attached>
>
>
>
> On Wed, Oct 2, 2013 at 12:51 PM, Konstantin Serebryany
> <konstantin.s.serebryany@gmail.com> wrote:
>> Hi,
>>
>> I'd like to start a review for libsanitizer merge from upstream.
>> This is the first full merge since 2013-02-21 and it contains lots of changes,
>> including two changes in asan API which require a corresponding change
>> in asan.c.
>> The patch to asan.c contains one FIXME which I hope to resolve during
>> the review.
>>
>> The major user-visible change in libsanitizer is the introduction of
>> LeakSanitizer (lsan),
>> a heap leak detector that runs on top of AddressSanitizer.
>> https://code.google.com/p/address-sanitizer/wiki/LeakSanitizer
>>
>> Two more features of AddressSanitizer are supported by this run-time update,
>> but they require corresponding compiler changes which are not
>> implemented yet in asan.c:
>> https://code.google.com/p/address-sanitizer/wiki/UseAfterReturn
>> https://code.google.com/p/address-sanitizer/wiki/InitializationOrderFiasco
>>
>> Other changes include:
>> - various stability, portability, and performance improvements in
>> AddressSanitizer and ThreadSanitizer, code refactoring.
>> - Improved native Windows support.
>> - probably various new bugs too, but the upstream head is heavily
>> tested on Chromium and other large source bases.
>>
>>
>> I tested this change like this on x86_64 Linux Ubuntu 12.04:
>> rm -rf */{*/,}libsanitizer && make -j 50 && make -C gcc
>> check-g{cc,++} RUNTESTFLAGS='--target_board=unix\{-m32,-m64\}
>> asan.exp'
>>
>> Since the change also pulls minor changes in ubsan, please suggest me
>> how to test that too.
>>
>> Expected ChangeLog entries:
>> =========== gcc/testsuite/ChangeLog
>>
>> 2013-10-XX Kostya Serebryany <kcc@google.com>
>>
>> * g++.dg/asan/asan_test.cc: Update the test
>> to match the fresh asan run-time.
>> * c-c++-common/asan/stack-overflow-1.c: Ditto.
>>
>> =========== gcc/ChangeLog
>>
>> 2013-10-XX Kostya Serebryany <kcc@google.com>
>>
>> * asan.c: Update to match the changed asan API.
>> (asan_emit_stack_protection): update the string stored in the
>> stack red zone to match new API. Store the PC of the current
>> function in the red zone.
>> (asan_global_struct): update the __asan_global definition to match
>> the new API.
>> (asan_add_global): Ditto.
>> * sanitizer.def: rename __asan_init_v1 to __asan_init_v3
>>
>> =========== libsanitizer/ChangeLog
>>
>> 2013-10-XX Kostya Serebryany <kcc@google.com>
>>
>> * All source files: Merge from upstream r191666.
>> * merge.sh: Added lsan.
>> * configure.ac: Added lsan.
>> * Makefile.am: Added lsan.
>> * sanitizer_common/Makefile.am: Added lsan.
>> * asan/Makefile.am: Added dependency on lsan.
>> * lsan/Makefile.am: New file.
>> * asan/Makefile.in: Regenerate.
>> * lsan/Makefile.in: Regenerate.
>> * Makefile.in: Regenerate.
>> * configure: Regenerate.
>> * sanitizer_common/Makefile.in: Regenerate.
>>
>> Patch attached.
>>
>> --kcc