]> gcc.gnu.org Git - 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>
Tue, 10 May 2022 08:14:28 +0000 (10:14 +0200)
commitcf3a927af0c040478280d90559e3e3088256c6fc
treeac8b5cc5f9e696acd38af8afa27a29f7f74e8829
parent536b03642ad1a32100f71d414e6bd6dc54fc208a
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.

(cherry picked from commit 40dd9d839e52f679d8eabc1c5ca0ca17a5ccfd14)
gcc/c-family/c-omp.c
gcc/testsuite/c-c++-common/ubsan/pr64888.c [new file with mode: 0644]
This page took 0.056266 seconds and 5 git commands to generate.