On Fri, Apr 16, 2021 at 2:06 PM Satish Balay via petsc-dev < [email protected]> wrote:
> Sure that might work. Also just commenting out the 3 lines for that check > got the build going for me. > > Or a simple change (but a bit intrusive): > > [balay@pj01 petsc]$ diff -Nru ./arch-linux-c-debug/include/sc.h~ > ./arch-linux-c-debug/include/sc.h > --- ./arch-linux-c-debug/include/sc.h~ 2021-04-16 12:59:20.803995227 -0500 > +++ ./arch-linux-c-debug/include/sc.h 2021-04-16 13:00:06.490993496 -0500 > @@ -83,7 +83,7 @@ > #ifdef SC_ENABLE_MPI > #include <mpi.h> > #else > -#ifdef MPI_SUCCESS > +#if defined(MPI_SUCCESS) && !defined(MPIUNI_H) > #error "mpi.h is included. Use --enable-mpi." > #endif > #endif > > Also getting test suite errors - Matt might have to check on. [attaching > log] > Hmm, this looks like an MPIUNI memory leak with split collectives. I will have to spin up that configuration and track it down. Matt > Satish > > On Fri, 16 Apr 2021, Isaac, Tobin G wrote: > > > Hmm. So if petsc always compiles mpiuni if --with-mpi=0, then it makes > me think it should be possible to drop requires(MPI) from p4est, while > still passing `--enable-mpi` to p4est. > > > > Maybe: if mpiuni doesn't provide some esoteric part of MPI that p4est > uses, it will break. > > > > Toby Isaac, Assistant Professor, GTCSE > > > > ________________________________ > > From: Satish Balay <[email protected]> > > Sent: Friday, April 16, 2021 1:03:55 PM > > To: Isaac, Tobin G <[email protected]> > > Cc: petsc-dev <[email protected]> > > Subject: Re: [petsc-dev] p4est w/o MPI > > > > Thanks! Another issue: > > > > mpiuni provides mpi.h. And I get the following errors when building > PETSc. > > > > /home/balay/petsc/arch-linux-c-debug/include/sc.h:87:2: error: #error > "mpi.h is included. Use --enable-mpi." > > 87 | #error "mpi.h is included. Use --enable-mpi." > > | ^~~~~ > > > > etc.. > > > > Satish > > > > > > On Fri, 16 Apr 2021, Isaac, Tobin G wrote: > > > > > Yes, `--disable-mpi` should be accepted by p4est. > > > > > > ________________________________________ > > > From: Satish Balay <[email protected]> > > > Sent: Friday, April 16, 2021 11:47 > > > To: Satish Balay via petsc-dev > > > Cc: Isaac, Tobin G > > > Subject: Re: [petsc-dev] p4est w/o MPI > > > > > > BTW: Is there no --disable-mpi option? > > > > > > Satish > > > > > > On Fri, 16 Apr 2021, Satish Balay via petsc-dev wrote: > > > > > > > MPI pacakge is a bit weird compared to others [as it does this funny > thing with MPIUNI]. > > > > > > > > For regular packages - I guess I would use 'if package.found' > > > > > > > > I guess I should create an MR with this diff. > > > > > > > > Satish > > > > > > > > ---- > > > > > > > > diff --git a/config/BuildSystem/config/packages/p4est.py > b/config/BuildSystem/config/packages/p4est.py > > > > index e7108b0ab8..40d6797f02 100644 > > > > --- a/config/BuildSystem/config/packages/p4est.py > > > > +++ b/config/BuildSystem/config/packages/p4est.py > > > > @@ -24,14 +24,16 @@ class Configure(config.package.GNUPackage): > > > > self.blasLapack = > framework.require('config.packages.BlasLapack',self) > > > > self.zlib = framework.require('config.packages.zlib',self) > > > > self.memalign = framework.argDB['with-memalign'] > > > > - self.deps = [self.mpi,self.blasLapack,self.zlib] > > > > + self.deps = [self.blasLapack,self.zlib] > > > > + self.odeps = [self.mpi] > > > > return > > > > > > > > def formGNUConfigureArgs(self): > > > > args = config.package.GNUPackage.formGNUConfigureArgs(self) > > > > if self.argDB['with-p4est-debugging']: > > > > args.append('--enable-debug') > > > > - args.append('--enable-mpi') > > > > + if not self.mpi.usingMPIUni: > > > > + args.append('--enable-mpi') > > > > > args.append('CPPFLAGS="'+self.headers.toStringNoDupes(self.dinclude)+'"') > > > > args.append('LIBS="'+self.libraries.toString(self.dlib)+'"') > > > > args.append('--enable-memalign='+self.memalign) > > > > > > > > On Fri, 16 Apr 2021, Isaac, Tobin G wrote: > > > > > > > > > Matt, this is the configure logic I would like, but I don't know > how to do it: > > > > > - configure p4est after MPI, but do not require MPI > > > > > - if MPI is present, add the '--enable-mpi' flack in > formGNUConfigureArgs(), otherwise omit it. > > > > > > > > > > ________________________________________ > > > > > From: Isaac, Tobin G <[email protected]> > > > > > Sent: Friday, April 16, 2021 11:03 > > > > > To: Mark Adams; For users of the development version of PETSc > > > > > Subject: Re: [petsc-dev] p4est w/o MPI > > > > > > > > > > p4est has a mode where it can compile without MPI, I don't know if > PETSc is using it, will check. > > > > > > > > > > ________________________________________ > > > > > From: petsc-dev <[email protected]> on behalf of Mark > Adams <[email protected]> > > > > > Sent: Friday, April 16, 2021 10:23 > > > > > To: For users of the development version of PETSc > > > > > Subject: [petsc-dev] p4est w/o MPI > > > > > > > > > > I don't have MPI (Fugaku w/ gcc) and p4est seems to need it. Is > there a work around? > > > > > Thanks, > > > > > Mark > > > > > > > > > > > > > > > > > -- What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead. -- Norbert Wiener https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
