mingw-cross-env-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Mingw-cross-env-list] OpenMP support


From: Volker Grabsch
Subject: Re: [Mingw-cross-env-list] OpenMP support
Date: Sat, 19 Sep 2009 06:28:54 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

Aleksandr' Tiŝin <address@hidden> schrieb:
> Yes, there is support of OpenMP technology in the GCC but mingw-cross-env
> compiles GCC without it.
> 
> There is short test program that compiles fine on a native GCC (with
> -fopenmp parameter):
> [...]

I did some analysis and here's my result.

OpenMP is disabled for the win32 target because the OpenMP
runtime library libgomp doesn't build there. However, the
only reason for that is the missing pthread support.

So I interweaved the pthread package with the gcc package
such that gcc is first build without libgomp, then pthread
is build, and finally the gcc build is completed by compiling
libgomp:

    http://hg.savannah.gnu.org/hgweb/mingw-cross-env/rev/ded943cd5981

It was hard to get all the configure parameters right, but
now it seems to work. It would be great if you could validate
that. You may want to compile your program with:

    -fopenmp

or with:

    -lgomp -lpthread -lws2_32

I couldn't figure out the exact difference between them,
but '-fopenmp' creates a 4k bigger binary that depends
on mingwm10.dll, while the other variant creates a smaller
binary that doesn't depend on mingwm10.dll.

Anyway, at least one of these two variants should work
for you. Please check the current development version:

    hg pull -u
    make gcc


Greets,

    Volker

-- 
Volker Grabsch
---<<(())>>---
Administrator
NotJustHosting GbR




reply via email to

[Prev in Thread] Current Thread [Next in Thread]