https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79247
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |RESOLVED CC| |jakub at gcc dot gnu.org Resolution|--- |INVALID --- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> --- This is invalid testcase, please read e.g. OpenMP 4.5, 2.15.3.3 (reduction clause is a privatization clause): "Inside the construct, all references to the original list item are replaced by references to the new list item. In the rest of the region, it is unspecified whether references are to the new list item or the original list item." You have no references to x in the construct, only in the region, therefore it is unspecified if it accesses the original list item (therefore a race) or the privatized variable.