]> git.ipfire.org Git - thirdparty/gcc.git/commit
openmp: For default(none) ignore variables created by ubsan_create_data [PR64888]
authorJakub Jelinek <jakub@redhat.com>
Thu, 21 Oct 2021 08:27:44 +0000 (10:27 +0200)
committerJakub Jelinek <jakub@redhat.com>
Thu, 21 Oct 2021 08:27:44 +0000 (10:27 +0200)
commit40dd9d839e52f679d8eabc1c5ca0ca17a5ccfd14
treecf28a9c3377ca7370842f1475794b2f021d036ca
parent113860301f46d14a255bd947d18d36f917527230
openmp: For default(none) ignore variables created by ubsan_create_data [PR64888]

We weren't ignoring the ubsan variables created by c-ubsan.c before gimplification
(others are added later).  One way to fix this would be to introduce further
UBSAN_ internal functions and lower it later (sanopt pass) like other ifns,
this patch instead recognizes those magic vars by name/name of type and DECL_ARTIFICIAL
and TYPE_ARTIFICIAL.

2021-10-21  Jakub Jelinek  <jakub@redhat.com>

PR middle-end/64888
gcc/c-family/
* c-omp.c (c_omp_predefined_variable): Return true also for
ubsan_create_data created artificial variables.
gcc/testsuite/
* c-c++-common/ubsan/pr64888.c: New test.
gcc/c-family/c-omp.c
gcc/testsuite/c-c++-common/ubsan/pr64888.c [new file with mode: 0644]