https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120737
Tobias Burnus <burnus at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |burnus at gcc dot gnu.org --- Comment #2 from Tobias Burnus <burnus at gcc dot gnu.org> --- (In reply to Benjamin Schulz from comment #0) > #pragma omp target teams distribute shared(tmp) Try adding a 'map(tmp)' clause as otherwise tmp is implicitly mapped as 'firstprivate'. (or 'map(always,tofrom: tmp)' if the value might have changed after target enter data). defaultmap(none) helps finding such issues.