From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22905 invoked by alias); 5 Aug 2010 09:12:17 -0000 Received: (qmail 22815 invoked by uid 48); 5 Aug 2010 09:11:47 -0000 Date: Thu, 05 Aug 2010 09:12:00 -0000 Subject: [Bug libgomp/45192] New: OpenMP fails in DLLs X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "john at quivinco dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-08/txt/msg00293.txt.bz2 I have an OpenMP code segment: #pragma omp parallel for for (i = 0; i < size; i++) Built with mingw gcc 4.4.0. Run on Windows XP SP3, AMD 64 Athlon FX62 dual core. Run in an exe application it works fine, however when invoked as code in a DLL the for loop threads do not increment properly and the loop runs infinitely repeating the same values of i. eg: 19 thread 0 26936 thread 1 20 thread 0 0 thread 1 21 thread 0 19 thread 1 22 thread 0 20 thread 1 21 thread 1 23 thread 0 22 thread 1 0 thread 0 23 thread 1 19 thread 0 24 thread 1 20 thread 0 ... -- Summary: OpenMP fails in DLLs Product: gcc Version: 4.4.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libgomp AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: john at quivinco dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45192