On Tue, Nov 20, 2012 at 9:16 AM, Xinliang David Li <davi...@google.com> wrote:
> If that is a limitation, the compiler should give a warning about it
> instead of making them silently suppress each other. Think about some
> other sanitizer options that can co-exist with asan or tsan in the
> future.

Yes, that's what we are moving to in clang (e.g. "ubsan" can co-exist
with tsan/tsan/msan).


>
> David
>
> On Mon, Nov 19, 2012 at 9:07 PM, Konstantin Serebryany
> <konstantin.s.serebry...@gmail.com> wrote:
>> On Mon, Nov 19, 2012 at 10:31 PM, Xinliang David Li <davi...@google.com> 
>> wrote:
>>> Questions: are -fsanitize=thread -fsanitize=address mutually exclusive
>>> here? If yes, that will be wrong.
>>>
>>> How about -fsanitize=all option?
>>
>> asan and tsan can not coexist in the same process.
>> Until recently, using both flags with clang was causing a failure at
>> program startup, now it produces a build failure.
>>
>> --kcc
>>
>>
>>>
>>> As kcc mentioned, the -fno-.. form is not handled.
>>>
>>> David
>>>
>>>
>>> On Mon, Nov 19, 2012 at 10:14 AM, Wei Mi <w...@google.com> wrote:
>>>> Hi,
>>>>
>>>> This patch is to change -faddress-sanitizer to -fsanitize=address. Ok for 
>>>> trunk?
>>>>
>>>> 2012-11-19  Wei Mi  <w...@google.com>
>>>>
>>>>         * cfgexpand.c (partition_stack_vars): Change flag_asan to
>>>>         flag_sanitize.
>>>>         (expand_stack_vars): Likewise.
>>>>         (defer_stack_allocation): Likewise.
>>>>         (expand_used_vars): Likewise.
>>>>         * varasm.c (assemble_noswitch_variable): Likewise.
>>>>         (assemble_variable): Likewise.
>>>>         (place_block_symbol): Likewise.
>>>>         * asan.c (gate_asan): Likewise.
>>>>         (gate_asan_O0): Likewise.
>>>>         * toplev.c (compile_file): Likewise.
>>>>         (process_options): Likewise.
>>>>         * common.opt: Change faddress-sanitizer to fsanitize=address.
>>>>         * gcc.c (LINK_COMMAND_SPEC): Likewise.
>>>>         * testsuite/lib/asan-dg.exp
>>>>         (check_effective_target_faddress_sanitizer): Likewise.
>>>>         (asan_init): Likewise.
>>>>         * flag-types.h (sanitize_type): New enum type.
>>>>         * doc/invoke.texi (-fsanitize=[address|thread]): Document.
>>>>
>>>> Thanks,
>>>> Wei.

Reply via email to