This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: RFC libgomp/testsuite/libgomp.fortran


In article <20090902234241.GA45546@troutmask.apl.washington.edu>,
Steve Kargl<sgk@troutmask.apl.washington.edu> writes:

>> > As a gfortran maintainer and FreeBSD user, I've always considered these
>> > failures to be bogus.  The inclusion of -lgomp and -pthread are tied
>> > to -fopenmp.  If you look at the failures, you'll see an ordering of
>> > '-fopenmp -O -fno-openmp', which correctly disables the inclusion
>> > of -lgomp and -pthread.  The only problem is that 

>> > troutmask:sgk[251] find . -name \*.exp | xargs grep lgomp
>> > ./lib/libgomp.exp:    lappend ALWAYS_CFLAGS "ldflags=-lgomp"

>> > so dejagnu overrides -fno-openmp and adds -lgomp without adding
>> > -pthread.

>> > Your changes look correct to me, but I can't approve patches
>> > in the libgomp hierarchy.

>> What would happen if we removed 'lappend ALWAYS_CFLAGS "ldflags=-lgomp"'
>> from libgomp.exp?  That seems like that would be the 'right' fix.

> I don't know.  Given that Jakub, Diego, and RTH wrote gomp,
> I assume that they had a reason for this to be in libgomp.exp.

For sample size one (port == i386-*-freebsd7*), the proposed removal
of:  lappend ALWAYS_CFLAGS "ldflags=-lgomp"

"works" as well as my proposed patch to port-selectively add -pthread
to the -fno-openmp cases.  I also verfied that every line which had
-lgomp also had (and still has) -fopenmp (which implies -lgomp).

The only remaining concern are those four tests that I patched to add
a port-selective -pthread have -fopenmp followed by -fno-openmp.  Do
those four cases need -lgomp to properly test some run-time aspects?
I don't think so, but I don't really know fortran anymore.

Regards,
Loren


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]