I am compiling camb and want to use the open mp flag (-mp) with pgf90.
However, I get a raft of errors at compile time (gory details appended). Has anyone else seen this - I am working on a cluster, so can't swap compilers that easily.
Some googling suggests that there are issues combining -fast and -mp flags with pgf90 but those seemed to arise at run-time, not compile-time.
Any suggestions??
Richard
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c subroutines.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c inifile.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c power_tilt.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c recfast.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c modules.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c bessels.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c equations.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c halofit.f90
/usr/local/cluster/pgi/linux86-64/6.0/bin/pgf90 -O2 -mp -c lensing.f90
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - p (lensing.f90: 206)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - dp (lensing.f90: 207)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - d_11 (lensing.f90: 216)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - d_m11 (lensing.f90: 217)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - d_22 (lensing.f90: 222)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - d_2m2 (lensing.f90: 225)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - d_20 (lensing.f90: 228)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - corrcontribs (lensing.f90: 305)
PGF90-S-0155-Adjustable/automatic variables must appear in a PRIVATE clause when DEFAULT(PRIVATE) is present - ddcontribs (lensing.f90: 337)
PGF90-S-0038-Symbol, p, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, dp, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, d_11, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, d_m11, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, d_22, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, d_2m2, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, d_20, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, corrcontribs, has not been explicitly declared (lensing.f90)
PGF90-S-0038-Symbol, ddcontribs, has not been explicitly declared (lensing.f90)
0 inform, 0 warnings, 18 severes, 0 fatal for corrfuncfullsky
camb / pgf90 and -mp
-
- Posts: 73
- Joined: January 04 2005
- Affiliation: NAOC
- Contact:
camb / pgf90 and -mp
Hi!
I have encontered similar problems when using PGI compiler. You can change the argument "SHARED" to "PRIVATE" in lensing.f90 to solve the problem if you don't care for lensing effect in your project .
Cheers
Gongbo Zhao
I have encontered similar problems when using PGI compiler. You can change the argument "SHARED" to "PRIVATE" in lensing.f90 to solve the problem if you don't care for lensing effect in your project .
Cheers
Gongbo Zhao
-
- Posts: 16
- Joined: April 14 2005
- Affiliation: Yale
camb / pgf90 and -mp
I played with this a bit more, and added the following line to lensing.f90
lens_contrib=0
!$OMP PARALLEL DO DEFAULT(PRIVATE), &
!$OMP PRIVATE(p,dp,d_11,d_m11,d_22,d_2m2,d_20,corrcontribs,ddcontribs),& <- - - -
!$OMP SHARED(lfacs,lfacs2,lrootfacs,Cphil3,CTT,CTE,CEE,lens_contrib), &
!$OMP SHARED(dtheta,CP,lmax_lensed,roots, npoints,interp_fac,jmax,ls,xl)
(around line 188 of the source). I have yet to really check it thoroughly but it seems to be benign. It seems to imply that the PGF90 interprets "DEFAULT PRIVATE" to mean "you must say explicitly each variable is private"...
I am leery about messing with OPENMP code I did not write myself (I am leery enough when I did do it myself, when it comes to that) so thought I should post it here for comment. If it really is benign, it could be usefully folded into the source-tree.
Richard
lens_contrib=0
!$OMP PARALLEL DO DEFAULT(PRIVATE), &
!$OMP PRIVATE(p,dp,d_11,d_m11,d_22,d_2m2,d_20,corrcontribs,ddcontribs),& <- - - -
!$OMP SHARED(lfacs,lfacs2,lrootfacs,Cphil3,CTT,CTE,CEE,lens_contrib), &
!$OMP SHARED(dtheta,CP,lmax_lensed,roots, npoints,interp_fac,jmax,ls,xl)
(around line 188 of the source). I have yet to really check it thoroughly but it seems to be benign. It seems to imply that the PGF90 interprets "DEFAULT PRIVATE" to mean "you must say explicitly each variable is private"...
I am leery about messing with OPENMP code I did not write myself (I am leery enough when I did do it myself, when it comes to that) so thought I should post it here for comment. If it really is benign, it could be usefully folded into the source-tree.
Richard