[petsc-dev] invocation of nvcc

Satish Balay balay at mcs.anl.gov
Thu Nov 4 12:40:52 CDT 2021


I think we went through this issue before.

nvc is the 'c' compiler. And for some reason its giving 'cuda' warnings.

I think you might have switched progenv last time [and avoided this compiler]

You can try using this compiler manually - on simple code - and then seek help from the admins on how to avoid these warnings..

Satish

- create test.c with:

#include <stdlib.h>

compile (or preporcess):

cc -E  test.c

- You should get:

stderr:
nvc-Warning-The -gpu option has no effect unless a language-specific option to enable GPU code generation is used (e.g.: -acc, -mp=gpu, -stdpar, -cuda)

Now provide this info to the machine admins [or nvidia folk] - and ask how to get rid of this message.

Satish


On Thu, 4 Nov 2021, Mark Adams wrote:

> Correction it is nvc:
> 
> nvc-Warning-The -gpu option has no effect unless a language-specific option
> to enable GPU code generation is used (e.g.: -acc, -mp=gpu, -stdpar, -cuda)
> 
> And I add  -mp=gpu to CUDAFLAGS
> 
> 
> On Thu, Nov 4, 2021 at 1:09 PM Satish Balay <balay at mcs.anl.gov> wrote:
> 
> >
> > On Thu, 4 Nov 2021, Mark Adams wrote:
> >
> > > Does anyone know if PETSc calls nvcc and hence can add flags to the
> > > invocation? nvcc wants a flag like -mp=gpu but I don't know if we do that
> > > or a compiler wrapper in the environment.
> >
> > $ ./configure --help |grep CUDA
> > <snip>
> >   --CUDAC=<prog>
> >        Specify the CUDA compiler
> >   --CUDAFLAGS=<string>
> >        Specify the CUDA compiler options
> > <snip>
> >
> > Satish
> >
> 



More information about the petsc-dev mailing list