[petsc-dev] PETSc-Cuda with gfortran 4.7

Satish Balay balay at mcs.anl.gov
Fri Mar 15 09:12:51 CDT 2013


On Fri, 15 Mar 2013, Åsmund Ervik wrote:

> Hi Dave,
> 
> The errors occur when compiling these CUDA files:
> mpiaijAssemble.cu, aijcusp.cu, mpicusp.cu and veccusp.cu
> I assume these are compiled with nvcc, but I haven't triple checked that.
> 
> I had not tried your trick with setting the C compiler in nvcc.profile.
> I did, however, try symlinking gcc-4.4 binaries into /usr/local/cuda/bin
> (as was suggested in one stackexchange post I found), but this produced
> an error during configure. Using your nvcc.profile, it gives the same error:
> 
> CUDA version error: PETSC currently requires CUDA version 4.0 or higher
> - when compiling with CUDA

This error message is misleading. Basically the compiler failed to
compile simple cuda [versioncheck] code. Configure couldn't
distinguish this failure from compiler failure vs vesion-check-code
failure. [details in configure.log]

Satish

> 
> Even though I have CUDA 5.0 installed. Just to be sure, are there
> binaries beside gfortran, gcc and g++ which must be found in the
> CUDA-specific gcc-4.6 folder? I have both gcc variants installed through
> the packaging system of my distro, so I cant't tell which belong to the
> 4.6 variant.
> 
> Asmund
> 
> On 13. mars 2013, wdn at lanl.gov wrote:
> > 
> > Asmund,
> > 
> > Do the failures you report below occur in cuda code that is ultimately compiled with nvcc?
> > I have not had problems compiling petsc-dev with cuda support on a Fedora 17 system
> > which uses gcc-4.7.2 and gfortran-4.7.2.  However, I have gcc 4.6.3 installed also and
> > have nvcc pointed at it by using the /usr/local/cuda/bin/nvcc.profile with a couple of lines
> > added.  So, when I build petsc-dev on my Fedora 17 system, it uses gcc-4.7.2 and
> > gfortran-4.7.2 for everything except cuda code located in .cu files.  I would worry about
> > removing some functionality in 4.7.2 with your suggested modification.
> > 
> > Thanks,
> > 
> > Dave
> > 
> > --
> > Dave Nystrom
> > LANL HPC-5
> > Phone: 505-667-7913
> > Email: wdn at lanl.gov
> > Smail: Mail Stop B272
> >        Group HPC-5
> >        Los Alamos National Laboratory
> >        Los Alamos, NM 87545
> > 
> > 
> 


More information about the petsc-dev mailing list