This is the mail archive of the
mailing list for the GCC project.
Re: [PATCHv3][PING] Enable -fsanitize-recover for KASan
- From: Alexey Samsonov <samsonov at google dot com>
- To: Jakub Jelinek <jakub at redhat dot com>
- Cc: Yury Gribov <y dot gribov at samsung dot com>, Konstantin Serebryany <konstantin dot s dot serebryany at gmail dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>, Dmitry Vyukov <dvyukov at google dot com>, Andrey Ryabinin <a dot ryabinin at samsung dot com>, Konstantin Khlebnikov <k dot khlebnikov at samsung dot com>
- Date: Wed, 1 Oct 2014 16:21:29 -0700
- Subject: Re: [PATCHv3][PING] Enable -fsanitize-recover for KASan
- Authentication-results: sourceware.org; auth=none
- References: <CAGQ9bdzcCO6CfQ7nG+xeAh63fs-GASiTExTvZfjJtMA67_4feQ at mail dot gmail dot com> <CAGSYnCPwbgZ++2Jt2vE6-ytveSJwSQPZT5umLeKPVWsVjWzwPQ at mail dot gmail dot com> <20140929231720 dot GI17454 at tucnak dot redhat dot com> <CAGSYnCPAN83v+JOyw-jMLUEE2YjaNQykdTCG4rdd=o_ieC4vFA at mail dot gmail dot com> <CAGQ9bdyWWNMt4m9jO2N1nzvVFjVuT1zbyey362WvnMxJZmNkBw at mail dot gmail dot com> <20140930054027 dot GJ17454 at tucnak dot redhat dot com> <542A56C0 dot 2030506 at samsung dot com> <CAGSYnCNTqXyWTHQERJe1t2uiNmOYGTMcU761Zs8N1DxUpZQnYw at mail dot gmail dot com> <20140930173340 dot GI1986 at tucnak dot redhat dot com> <CAGSYnCMCMUPhttwyPMjSmpiim2U26cD6ef7sc9KdP9tRkZu7uQ at mail dot gmail dot com> <20140930173913 dot GJ1986 at tucnak dot redhat dot com>
Speaking of plain -f(no-)sanitize-recover - it would probably be
better to change the semantics of this flag,
so that "-f(no-)?sanitize-recover" means "enable(disable) recovery for
all sanitizers enabled at this point".
That is, it would be pretty much like -Werror flag.
"-fsanitize=undefined -fsanitize=address -fno-sanitize-recover"
would mean "run UBSan and ASan and don't recover from errors".
On Tue, Sep 30, 2014 at 10:39 AM, Jakub Jelinek <email@example.com> wrote:
> On Tue, Sep 30, 2014 at 10:36:34AM -0700, Alexey Samsonov wrote:
>> > Would we accept -fsanitize-recover=undefined -fno-sanitize-recover=signed-integer-overflow
>> > as recovering everything but signed integer overflows, i.e. the decision
>> > whether to recover a particular call would check similar bitmask as
>> > is checked whether to sanitize something at all?
>> Yes, the logic for creating a set of recoverable sanitizers should be
>> the same as the logic for creating a set of enabled sanitizers.
> LGTM, will hack it up soon in GCC then.
Alexey Samsonov, Mountain View, CA