$ cd libgomp/testsuite/libgomp.fortran $ gfortran -g -fopenmp allocatable5.f90 $ valgrind ./a.out shows with 4.5.0 20100329 on a dual-core x86_64-unknown-linux-gnu: ==16553== Conditional jump or move depends on uninitialised value(s) ==16553== at 0x536E12E: gomp_iter_dynamic_next (iter.c:190) ==16553== by 0x5370A19: GOMP_sections_start (sections.c:65) ==16553== by 0x400D65: MAIN__.omp_fn.0 (allocatable5.f90:9) ==16553== by 0x400BD0: MAIN__ (allocatable5.f90:8) ==16553== by 0x400CAC: main (allocatable5.f90:17) ==16553== ==16553== Conditional jump or move depends on uninitialised value(s) ==16553== at 0x536E12E: gomp_iter_dynamic_next (iter.c:190) ==16553== by 0x5370A50: GOMP_sections_next (sections.c:96) ==16553== by 0x400E54: MAIN__.omp_fn.0 (allocatable5.f90:9) ==16553== by 0x400BD0: MAIN__ (allocatable5.f90:8) ==16553== by 0x400CAC: main (allocatable5.f90:17) ==16553== ==16553== Thread 2: ==16553== Conditional jump or move depends on uninitialised value(s) ==16553== at 0x536E12E: gomp_iter_dynamic_next (iter.c:190) ==16553== by 0x5370A19: GOMP_sections_start (sections.c:65) ==16553== by 0x400D65: MAIN__.omp_fn.0 (allocatable5.f90:9) ==16553== by 0x5371721: gomp_thread_start (team.c:115) ==16553== by 0x5793A3E: start_thread (in /lib64/libpthread-2.11.1.so) ==16553== by 0x5A7AC1C: clone (in /lib64/libc-2.11.1.so)
Analogously for omp_parse1.f90, reduction5.f90. Same output for GCC 4.4.4.
Created attachment 20440 [details] gcc46-pr43569.patch Fix.
Subject: Bug 43569 Author: jakub Date: Tue Apr 20 15:36:45 2010 New Revision: 158564 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158564 Log: PR libgomp/43569 * sections.c (gomp_sections_init): Initialize ws->mode. Modified: trunk/libgomp/ChangeLog trunk/libgomp/sections.c
Subject: Bug 43569 Author: jakub Date: Wed Apr 21 13:58:49 2010 New Revision: 158598 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158598 Log: PR libgomp/43569 * sections.c (gomp_sections_init): Initialize ws->mode. Modified: branches/gcc-4_5-branch/libgomp/ChangeLog branches/gcc-4_5-branch/libgomp/sections.c
Subject: Bug 43569 Author: jakub Date: Wed Apr 21 13:58:59 2010 New Revision: 158599 URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=158599 Log: PR libgomp/43569 * sections.c (gomp_sections_init): Initialize ws->mode. Modified: branches/gcc-4_4-branch/libgomp/ChangeLog branches/gcc-4_4-branch/libgomp/sections.c
Fixed for 4.4.4/4.5.1/4.6.