re PR sanitizer/79944 (asan: incorrect instrumentation of atomic operations)
authorJakub Jelinek <jakub@redhat.com>
Thu, 9 Mar 2017 09:20:23 +0000 (10:20 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Thu, 9 Mar 2017 09:20:23 +0000 (10:20 +0100)
commit9e463823a8dbedb956fda93af75c206f9ef3acd4
treec218b4135429d12cdd923142e06b51e3a85032ab
parent6b62f323022656906067769236c31c74b9e10f47
re PR sanitizer/79944 (asan: incorrect instrumentation of atomic operations)

PR sanitizer/79944
* asan.c (get_mem_refs_of_builtin_call): For BUILT_IN_ATOMIC* and
BUILT_IN_SYNC*, determine the access type from the size suffix and
always build a MEM_REF with that type.  Handle forgotten
BUILT_IN_SYNC_FETCH_AND_NAND_16 and BUILT_IN_SYNC_NAND_AND_FETCH_16.

* c-c++-common/asan/pr79944.c: New test.

From-SVN: r245991
gcc/ChangeLog
gcc/asan.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/asan/pr79944.c [new file with mode: 0644]