This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/79940] [6/7 Regression] OpenMP pragma - internal compiler error with taskloop
- From: "jakub at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 08 Mar 2017 07:38:16 +0000
- Subject: [Bug c/79940] [6/7 Regression] OpenMP pragma - internal compiler error with taskloop
- Auto-submitted: auto-generated
- References: <bug-79940-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79940
--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
I'll fix this, that said the testcase certainly is not OpenMP compliant, you
have a data race in there, you need to do the taskloop just once, or make sure
that in each thread it will write to different arrays or portions of an array.
So easiest is just add #pragma omp single. But then, there is not really any
benefit in using taskloop in that case, a normal #pragma omp parallel for would
be faster.