Re: [petsc-dev] PETSc release soon, request for input on needed fixes or enhancements

2016-03-09 Thread Éric Chamberland

Hi,

the make install error occurred again last night, but with a different 
error:


  CC arch-linux2-c-debug/obj/src/tao/leastsquares/impls/pounders/gqt.o
 CLINKER 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/libpetsc.so.3.06.3
gmake[2]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
=
gmake[1]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
Now to install the libraries do:
make 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug install
=
*** Using 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug ***
No cached configure in RDict at 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/petsc/conf/RDict.db
Traceback (most recent call last):
  File "./config/install.py", line 380, in 
Installer(sys.argv[1:]).run()
  File "./config/install.py", line 373, in run
self.runsetup()
  File "./config/install.py", line 334, in runsetup
self.setup()
  File "./config/install.py", line 60, in setup
self.setupModules()
  File "./config/install.py", line 51, in setupModules
self.setCompilers  = self.framework.require('config.setCompilers', 
None)
AttributeError: 'NoneType' object has no attribute 'require'
make: *** [install] Error 1


Here are the logs:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s_default.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s_RDict.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s_make.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s_CMakeLists.txt

And the log from our scripts, with "env" output at the beginning:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.09.02h00m02s.script.log


May I launch a the make install with some debugging variables activated to see 
more output that might help?

I can also launch the scripts in a while loop until it bug again to help dig 
this problem...

Thanks,

Eric


Le 16-03-03 20:35, Éric Chamberland a écrit :
Hi, it's weird.  I launched my compilation script on another computer, 
and everything was fine with the petsc-master.tar.gz... So I launched 
it on the faulty computer, but it installed with succes... however, 
there is no "default.log" file after the make procedure...?? Here are 
the non-problematic logs: 
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.18h22m37s_configure.log 
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.18h22m37s_RDict.log 
What can I say? Some thoughts: - All this is completely automated by a 
crontab... so the environment variables shall be the same each 
night... - configure+make+make install are launched by the script 
without any "human pause" in between the end of each command:  if 
there is anything launched in the background by make, maybe it is not 
ended before the beginning of make install? I saw that there are also 
"make.log", "build.log" ".nagged", CMakeLists.txt files generated: do 
they should be inspected? Unfortunately, be runing the script again, I 
erased the faulty petsc directory... so I am only left with the 
configure.log+RDict.log+default.log I put on the web page... :/ 
Thanks, Eric Le 16-03-03 17:29, Satish Balay a écrit :
I tried a few builds - but I can't reproduce. So I do not know whats 
going on here [and what the trigger is].. Tried a configure command 
as close as possible to this one.. [and used the nightlytarball 
aswell] balay@es^/scratch/balay/petsc-master $ ./configure 
--prefix=/scratch/balay/petsc-install --with-mpi-compilers=1 
--with-make-np=12 --with-shared-libraries=1 --download-openmpi 
--with-debugging=yes --with-mkl_pardiso=1 --with-mkl_pardiso-dir=$MKL 
--download-ml=yes --download-mumps=yes --download-superlu=yes 
--download-superlu_dist=yes --download-parmetis=yes 
--download-ptscotch=yes --download-metis=yes 
--download-suitesparse=yes --download-hypre=yes --with-scalapack=1 
--with-scalapack-include=$MKL/include 
--with-scalapack-lib="-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64" 
--with-blas-lapack-dir=$MKL --download-cmake Satish On Thu, 3 Mar 
2016, Matthew Knepley wrote:
On Thu, Mar 3, 2016 at 5:42 AM, Éric Chamberland < 
eric.chamberl...@giref.ulaval.ca> wrote:
Hi, since last night, with petsc-master.tar.gz, it seems t

Re: [petsc-dev] PETSc release soon, request for input on needed fixes or enhancements

2016-03-03 Thread Éric Chamberland

Hi,

it's weird.  I launched my compilation script on another computer, and 
everything was fine with the petsc-master.tar.gz...


So I launched it on the faulty computer, but it installed with succes... 
however, there is no "default.log" file after the make procedure...??


Here are the non-problematic logs:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.18h22m37s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.18h22m37s_RDict.log

What can I say?

Some thoughts:

- All this is completely automated by a crontab... so the environment 
variables shall be the same each night...
- configure+make+make install are launched by the script without any 
"human pause" in between the end of each command:  if there is anything 
launched in the background by make, maybe it is not ended before the 
beginning of make install?


I saw that there are also "make.log", "build.log" ".nagged", 
CMakeLists.txt files generated: do they should be inspected?


Unfortunately, be runing the script again, I erased the faulty petsc 
directory... so I am only left with the 
configure.log+RDict.log+default.log I put on the web page... :/


Thanks,

Eric


Le 16-03-03 17:29, Satish Balay a écrit :

I tried a few builds - but I can't reproduce. So I do not know whats
going on here [and what the trigger is]..

Tried a configure command as close as possible to this one.. [and used
the nightlytarball aswell]


balay@es^/scratch/balay/petsc-master $ ./configure --prefix=/scratch/balay/petsc-install 
--with-mpi-compilers=1 --with-make-np=12 --with-shared-libraries=1 --download-openmpi 
--with-debugging=yes --with-mkl_pardiso=1 --with-mkl_pardiso-dir=$MKL --download-ml=yes 
--download-mumps=yes --download-superlu=yes --download-superlu_dist=yes 
--download-parmetis=yes --download-ptscotch=yes --download-metis=yes 
--download-suitesparse=yes --download-hypre=yes --with-scalapack=1 
--with-scalapack-include=$MKL/include --with-scalapack-lib="-lmkl_scalapack_lp64 
-lmkl_blacs_openmpi_lp64" --with-blas-lapack-dir=$MKL --download-cmake

Satish

On Thu, 3 Mar 2016, Matthew Knepley wrote:


On Thu, Mar 3, 2016 at 5:42 AM, Éric Chamberland <
eric.chamberl...@giref.ulaval.ca> wrote:


Hi,

since last night, with petsc-master.tar.gz, it seems that "make install"
is broken.

Please have a look at these errors:


Satish, do you see this?

We had something like this before, but it was fixed.

   Matt




...

  CC arch-linux2-c-debug/obj/src/tao/leastsquares/impls/pounders/gqt.o
  CLINKER 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/libpetsc.so.3.06.3
gmake[2]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
=
gmake[1]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
Now to install the libraries do:
make 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug install
=
*** Using 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug ***
 No cached configure in RDict at 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/petsc/conf/RDict.db
Traceback (most recent call last):
   File "./config/install.py", line 380, in 
 Installer(sys.argv[1:]).run()
   File "./config/install.py", line 373, in run
 self.runsetup()
   File "./config/install.py", line 334, in runsetup
 self.setup()
   File "./config/install.py", line 60, in setup
 self.setupModules()
   File "./config/install.py", line 51, in setupModules
 self.setCompilers  = self.framework.require('config.setCompilers', 
None)
AttributeError: 'NoneType' object has no attribute 'require'
make: *** [install] Error 1

=

Some useful logs:
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/configure_2016.03.03.02h00m01s.loghttp://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.02h00m01s_RDict.loghttp://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.02h00m01s_default.log

Thanks!

Eric






Le 16-02-27 15:36, Barry Smith a écrit :

PETSc Users,

 We are planning the PETSc release 3.7 shortly. If you know of any bugs 
that need to be fixed or enhancements added before the release please let us 
know.

 You can think of the master branch of the PETSc repository obtainable with

git clone https://bitbucket.org/petsc/petsc petsc

as a release candidate for 3.7. Changes for the release are listed at 
http://www.mcs.anl.gov/petsc/documentation/changes/dev.html

Thanks

Barry










Re: [petsc-dev] PETSc release soon, request for input on needed fixes or enhancements

2016-03-03 Thread Éric Chamberland

Hi,

since last night, with petsc-master.tar.gz, it seems that "make install" 
is broken.


Please have a look at these errors:


...

 CC arch-linux2-c-debug/obj/src/tao/leastsquares/impls/pounders/gqt.o
 CLINKER 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/libpetsc.so.3.06.3
gmake[2]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
=
gmake[1]: Leaving directory 
`/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug'
Now to install the libraries do:
make 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug install
=
*** Using 
PETSC_DIR=/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug
 PETSC_ARCH=arch-linux2-c-debug ***
No cached configure in RDict at 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/arch-linux2-c-debug/lib/petsc/conf/RDict.db
Traceback (most recent call last):
  File "./config/install.py", line 380, in 
Installer(sys.argv[1:]).run()
  File "./config/install.py", line 373, in run
self.runsetup()
  File "./config/install.py", line 334, in runsetup
self.setup()
  File "./config/install.py", line 60, in setup
self.setupModules()
  File "./config/install.py", line 51, in setupModules
self.setCompilers  = self.framework.require('config.setCompilers', 
None)
AttributeError: 'NoneType' object has no attribute 'require'
make: *** [install] Error 1

=

Some useful logs:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/configure_2016.03.03.02h00m01s.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.02h00m01s_RDict.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2016.03.03.02h00m01s_default.log

Thanks!

Eric





Le 16-02-27 15:36, Barry Smith a écrit :

PETSc Users,

 We are planning the PETSc release 3.7 shortly. If you know of any bugs 
that need to be fixed or enhancements added before the release please let us 
know.

 You can think of the master branch of the PETSc repository obtainable with

git clone https://bitbucket.org/petsc/petsc petsc

as a release candidate for 3.7. Changes for the release are listed at 
http://www.mcs.anl.gov/petsc/documentation/changes/dev.html

Thanks

Barry





Re: [petsc-dev] Valgrind report a bug in PetscOptionsFindPair_Private

2018-07-02 Thread Éric Chamberland

Barry,

sorry for the delay... but your patch solved the problem!

thanks!

Eric

Le 18-06-21 à 16:12, Smith, Barry F. a écrit :

Fixed in barry/fix-petscstrlcat/maint

I also doubled the length of the work strings used in processing options so 
your options won't get truncated and hence not get processed properly.

 Barry



On Jun 20, 2018, at 8:48 AM, Eric Chamberland 
 wrote:

Hi,

since we recently upgraded our nighlty valgrind validations to PETSc 3.9.2, 
valgrind found a bug in PetscOptionsFindPair_Private, called from:

PetscOptionsHasName("M_AssembleurGD_H_/pmi/cmpbib/compilation_BIB_gcc_valgrind/COMPILE_AUTO/BIBTestValidation/Ressources/opt/Test.assemblageDynamique/Ressources.Lettre_C_2016_gsf_P2B5_Z450_mp/Lettre_C_2016_gsf_P2B5_Z450_mp_A_SolveurLin_pour_solveur_","-::GIREF_NOM_PREFIXE_OPTIONS_PETSC");

valgrind complains with:

==253393== Source and destination overlap in strncat(0x1ffeff62e0, 
0x1ffeff6299, 108)
==253393==at 0x4C2C976: strncat (vg_replace_strmem.c:348)
==253393==by 0x1522912F: PetscStrlcat (str.c:460)
==253393==by 0x151DE08A: PetscOptionsFindPair_Private (options.c:1361)
==253393==by 0x151DF153: PetscOptionsHasName (options.c:1502)
...

We noticed that the PETSc code has changed close from there, so maybe it is 
related?

We do not have the bug with Petsc versions: {3.5.3,3.8.3} that we used to tests 
with valgrind.

Thanks,

Eric




Re: [petsc-dev] petsc/master: mkl_cpardiso.c broken

2018-02-03 Thread Éric Chamberland

Thanks Barry,

It is compiling now! :)

I didn't installed MKL myself, but our IT guy told me that you have to 
select something like "cluster" or "hpc" when installing it, then you 
will have cluster pardiso within the installed MKL libs.


Anyway, thanks again!

Eric


Le 18-02-02 à 20:42, Smith, Barry F. a écrit :

  Eric,

Thanks for the report. I believe I have fixed the problem in master.

Unfortunately we do not have a copy of mkl_cpardiso so maintaining the 
interface is not trivial.

Barry



On Jan 31, 2018, at 2:39 PM, Eric Chamberland 
 wrote:

Hi,

just to let know that since yesterday or before yesterday, I have errors in 
mkl_cpardiso.c on petsc/master:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.01.31.02h00m01s_make.log

other logs:

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.01.31.02h00m01s_configure.log

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.01.31.02h00m01s_RDict.log

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.01.31.02h00m01s_CMakeLists.txt

Thanks,

Eric




Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

Le 18-02-10 à 16:49, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:


oh my, looks like "-lpetsc -lmpi" works for us!!!

(sounds of head banging on desk)

This should work any time libpetsc is a shared library.  You'll need the
whole grotesque link line if you need to link statically.
Doh!  ok, thanks for the specification because we need also a static 
link for the code coverage to work...


and for my peaceful sleep:

Since when it is possible to link with PETSC with just "-lpetsc -lmpi"?

We linked with our own "complicated" line since... about 1998 

Thanks,

Eric



Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

oh my, looks like "-lpetsc -lmpi" works for us!!!

(sounds of head banging on desk)

;)

thanks!!!

Eric



Le 18-02-10 à 15:29, Éric Chamberland a écrit :

oh my god, if

-lpetsc -lmpi

works for me you make my day!!! :) really!

I will try it for sure!!!
I tried to maintain a very long linking line since sooo many years, if 
I can get ride of it, I will be happy!


Thanks,

Eric


Le 18-02-10 à 13:44, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:


Le 18-02-10 à 12:38, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:


and into this block there was the "-lmpi_cxx" that we need...

The point is that if you are linking C++ code that calls the MPI C++
interface, then *you* should link with mpicxx or equivalent.

The funny thing, is that we are hopefully *not* using the C++ API of
MPI.  We do use the C API since MPI 1.0.
Then, I am asking myself why this link error shows up now...since
nothing calls it... hmmm, let me dig into this...

Is StatistiqueMemoire not your code?

| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Op::Init(void (*)(void const*, void*, int,
| MPI::Datatype const&), bool)':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/op_inln.h:122: 
undefined reference to `ompi_mpi_cxx_op_intercept'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Intracomm::Create_graph(int, int const*, int const*,
| bool) const':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm.h:25: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Intercomm::Merge(bool) const':
| 
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Intracomm::Split(int, int) const':
| 
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Intracomm::Create(MPI::Group const&) const':
| 
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:

| In function `MPI::Intracomm::Clone() const':


You should not depend on PETSc to provide anything but PETSc to your
application (so if you call other libraries that your configuration of
PETSc uses, you should take responsibility to link them explicitly; 
this

Wait: you mean for example if I configure MUMPS (or not) with PETSc, I
have to build my link line with all MUMPS dependencies or not myself?

Do you call MUMPS directly or through the PETSc interface?

Think about this from the perspective of packaging with shared
libraries, where we ask what needs to be updated when interfaces change.
Suppose we have these interface dependencies:

   libpetsc : libmumps libmpi
   app : libpetsc libmpi

Since MUMPS makes no guarantee of binary compatibility between releases,
updating MUMPS 5.1.2 to 5.1.3 requires rebuilding everything that link
to it.  Since PETSc calls MUMPS directly, libpetsc must be rebuilt.  If
your App does not call MUMPS directly, then you should link it with

   -lpetsc -lmpi

Now your binaries continue to work after libpetsc has been updated to
link the newer libmumps.  If you needlessly linked libmumps without
calling it directly, then you would also need to rebuild your App.  That
is called overlinking and is prohibited by most packaging guidelines
because it wastes lots of time and bandwidth for maintainers and users.

If you use pkg-config with PETSc, you get only -lpetsc when linking with
shared libraries.  (Pkg-config will give you everything for static
linking because it is needed and the concept of overlinking doesn't
exist in the same sense, though removing excess from the link line is
still desirable to make it easier to read and faster to link.)

Note that PETSc's own dependency management is messy because someone in
the early days of BuildSystem thought that concatenating strings was
sufficient, instead of maintaining a structured dependency graph to be
topologically sorted at the final stage (pkg-config does this).


I wanted to be "lazy" and to use the same line *you* are using for
passing libs (and in the good *order* which is not easy to 
manage)... as

I can rely on this line to link "pure" petsc examples... ;)

is important when using shared libraries).  But you should definitely
not depend on PETSc to pro

Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

oh my god, if

-lpetsc -lmpi

works for me you make my day!!! :) really!

I will try it for sure!!!
I tried to maintain a very long linking line since sooo many years, if I 
can get ride of it, I will be happy!


Thanks,

Eric


Le 18-02-10 à 13:44, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:


Le 18-02-10 à 12:38, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:


and into this block there was the "-lmpi_cxx" that we need...

The point is that if you are linking C++ code that calls the MPI C++
interface, then *you* should link with mpicxx or equivalent.

The funny thing, is that we are hopefully *not* using the C++ API of
MPI.  We do use the C API since MPI 1.0.
Then, I am asking myself why this link error shows up now...since
nothing calls it... hmmm, let me dig into this...

Is StatistiqueMemoire not your code?

| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Op::Init(void (*)(void const*, void*, int,
| MPI::Datatype const&), bool)':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/op_inln.h:122: undefined 
reference to `ompi_mpi_cxx_op_intercept'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Intracomm::Create_graph(int, int const*, int const*,
| bool) const':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm.h:25: undefined 
reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Intercomm::Merge(bool) const':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Intracomm::Split(int, int) const':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Intracomm::Create(MPI::Group const&) const':
| /opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'
| 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
| In function `MPI::Intracomm::Clone() const':


You should not depend on PETSc to provide anything but PETSc to your
application (so if you call other libraries that your configuration of
PETSc uses, you should take responsibility to link them explicitly; this

Wait: you mean for example if I configure MUMPS (or not) with PETSc, I
have to build my link line with all MUMPS dependencies or not myself?

Do you call MUMPS directly or through the PETSc interface?

Think about this from the perspective of packaging with shared
libraries, where we ask what needs to be updated when interfaces change.
Suppose we have these interface dependencies:

   libpetsc : libmumps libmpi
   app : libpetsc libmpi

Since MUMPS makes no guarantee of binary compatibility between releases,
updating MUMPS 5.1.2 to 5.1.3 requires rebuilding everything that link
to it.  Since PETSc calls MUMPS directly, libpetsc must be rebuilt.  If
your App does not call MUMPS directly, then you should link it with

   -lpetsc -lmpi

Now your binaries continue to work after libpetsc has been updated to
link the newer libmumps.  If you needlessly linked libmumps without
calling it directly, then you would also need to rebuild your App.  That
is called overlinking and is prohibited by most packaging guidelines
because it wastes lots of time and bandwidth for maintainers and users.

If you use pkg-config with PETSc, you get only -lpetsc when linking with
shared libraries.  (Pkg-config will give you everything for static
linking because it is needed and the concept of overlinking doesn't
exist in the same sense, though removing excess from the link line is
still desirable to make it easier to read and faster to link.)

Note that PETSc's own dependency management is messy because someone in
the early days of BuildSystem thought that concatenating strings was
sufficient, instead of maintaining a structured dependency graph to be
topologically sorted at the final stage (pkg-config does this).


I wanted to be "lazy" and to use the same line *you* are using for
passing libs (and in the good *order* which is not easy to manage)... as
I can rely on this line to link "pure" petsc examples... ;)

is important when using shared libraries).  But you should definitely
not depend on PETSc to provide your application with stuff that has been
REMOVED from MPI (more than five years ago) and that PETSc does not use.

I agree, this C++ MPI API is not a very good excuse 

Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

ok, let put our in-house code away, simply try this simple example:

--

#include 

int main() {
/*empty!! let's see the .o */

return 1;

}
-

then:

g++ -c test.cc -I/opt/openmpi-1.10.2/include -o test.o

nm -C test.o | grep "MPI::" | grep " U "

 U MPI::Win::Free()
 U MPI::Comm::Comm()
 U MPI::Datatype::Free()

so: as soon you are compiling a c++ file with this openmpi 1.10.2 (even 
if you use gcc -c test.cc -I/opt/openmpi-1.10.2/include -o test.o in my 
example) it *requires* you to link with mpi_cxx lib...


That's the "problem", that's *my* fault to have relied on a PETSC 
variable to link with an mpi c++ lib


So I will add the mpi_cxx lib to our makefiles for these older versions 
of mpi...


Sorry for the annoyance...

But, as usual, thanks for your fast responses guys, you all deserve a 
gold medal!!! :)


Eric


Le 18-02-10 à 14:37, Jed Brown a écrit :

"Smith, Barry F."  writes:


Then the testing is more involved, need to first check if C++ bindings 
exist and then check if supplied automatically by compilers (like on Cray). 
Annoying, I'd prefer to avoid but I still don't have the definitive word if C++ 
bindings are the issue from Eric.

The undefined symbols are C++ bindings and they are referenced from a
source file named StatistiqueMemoire.* which is not part of PETSc or a
PETSc dependency.  We don't reference them so we shouldn't try to link
them.




Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland



Le 18-02-10 à 17:44, Jeff Hammond a écrit :


Indeed, everybody should compiler MPI codes with 
"-DMPICH_SKIP_MPICXX=1 -DOMPI_SKIP_MPICXX=1" now.


I'll ask MPICH and Open-MPI to switch the default to exclude C++ bindings.


Will definitely switch my default compiling options right now.

And I agree that it is relevant to switch that by default for all MPI 
distributions.  Thanks for forwarding!


Eric


Jeff

--
Jeff Hammond
jeff.scie...@gmail.com 
http://jeffhammond.github.io/




Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland



Le 18-02-10 à 16:48, Jed Brown a écrit :

That's sad, but is this not avoided by defining OMPI_SKIP_MPICXX before
including mpi.h?  (There is also MPICH_SKIP_MPICXX if you want.)  This
is done by default in petscsys.h, but you might not include it in that
file or don't include it before mpi.h is included.
Ok, didn't knew about this...  I think this is definitely a good 
solution!!! :)


Thanks again!

Eric



[petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

Hi,

we used to link our c++ code with PETSc using PETSC_WITH_EXTERNAL_LIB 
variable defined in $PETSC_DIR/lib/petsc/conf/petscvariables and 
everything was fine until this night.


It seems some libs have vanished from this variable, see the diff here:

 -lptscotcherr
 -lesmumps
 -lscotch
 -lscotcherr
 -lm
 -lX11
+-lstdc++
 -ldl
 -lmpi_usempi
 -lmpi_mpifh
 -lmpi
 -lgfortran
 -lm
 -lgfortran
 -lm
 -lgcc_s
 -lquadmath
 -lpthread
--ldl
--lmpi_cxx
--lmpi
--lstdc++
--lm
--lgcc_s
--lpthread
 -lrt
 -lm
 -lpthread
 -lz
+-lstdc++
 -ldl


causing these errors at link phase for us:

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Op::Init(void (*)(void const*, void*, int, 
MPI::Datatype const&), bool)':

/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/op_inln.h:122: undefined 
reference to `ompi_mpi_cxx_op_intercept'
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Intracomm::Create_graph(int, int const*, int const*, 
bool) const':

/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm.h:25: undefined 
reference to `MPI::Comm::Comm()'
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Intercomm::Merge(bool) const':

/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: undefined 
reference to `MPI::Comm::Comm()'
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Intracomm::Split(int, int) const':

/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: undefined 
reference to `MPI::Comm::Comm()'
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Intracomm::Create(MPI::Group const&) const':

/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: undefined 
reference to `MPI::Comm::Comm()'
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o: 
In function `MPI::Intracomm::Clone() const':


Is this a normal and definitive change or an unwanted/unobserved bug?

Thanks,

Eric

ps: here are the logs:

this night:

-

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.10.02h00m01s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.10.02h00m01s_make.log


a day before:


http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.09.02h00m02s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.09.02h00m02s_make.log




Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

Hi Matthew,

Yes, I heard that the MPI C++ API has been deprecated.

Yes, the mpi_cxx is now missing.  Our link line is formed mainly with 
PETSC_WITH_EXTERNAL_LIB variable that is now:


PETSC_WITH_EXTERNAL_LIB = -L/opt/petsc-master_debug/lib 
-Wl,-rpath,/opt/petsc-master_debug/lib -L/opt/petsc-master_debug/lib 
-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-Wl,-rpath,/opt/openmpi-1.10.2/lib -L/opt/openmpi-1.10.2/lib 
-Wl,-rpath,/usr/lib/gcc/x86_64-redhat-linux/4.8.5 
-L/usr/lib/gcc/x86_64-redhat-linux/4.8.5 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/compiler/lib/intel64 
-L/opt/intel/composer_xe_2015.2.164/compiler/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/ipp/lib/intel64 
-L/opt/intel/composer_xe_2015.2.164/ipp/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/tbb/lib/intel64/gcc4.4 
-L/opt/intel/composer_xe_2015.2.164/tbb/lib/intel64/gcc4.4 -lpetsc 
-lsuperlu -lsuperlu_dist -lHYPRE -lcmumps -ldmumps -lsmumps -lzmumps 
-lmumps_common -lpord -lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64 -lml 
-lumfpack -lklu -lcholmod -lbtf -lccolamd -lcolamd -lcamd -lamd 
-lsuitesparseconfig -lmkl_intel_lp64 -lmkl_core -lmkl_intel_thread 
-lmkl_blacs_intelmpi_lp64 -liomp5 -ldl -lpthread -lparmetis -lmetis 
-lptesmumps -lptscotch -lptscotcherr -lesmumps -lscotch -lscotcherr -lm 
-lX11 -lstdc++ -ldl -lmpi_usempi -lmpi_mpifh -lmpi -lgfortran -lm 
-lgfortran -lm -lgcc_s -lquadmath -lpthread -lrt -lm -lpthread -lz 
-lstdc++ -ldl


We add some stuff to this (our own compiled libs), but nothing related 
to MPI or PETSc since we used to rely on PETSC_WITH_EXTERNAL_LIB for all 
our diffrement environments (think about different petsc version, MPI 
libs and compilers: clang, icc, g++) and it used to work until yesterday 
changes...


As you can see in the diff, this "block" of libraries have been removed 
from PETSC_WITH_EXTERNAL_LIB: (the -- is part of the diff output):


--ldl
--lmpi_cxx
--lmpi
--lstdc++
--lm
--lgcc_s
--lpthread

and into this block there was the "-lmpi_cxx" that we need...

I could send you our whole line of link, but the error is into this 
small change introduced yesterday into master...


Thanks a lot!

Eric

Le 18-02-10 à 10:34, Matthew Knepley a écrit :
On Sat, Feb 10, 2018 at 9:42 AM, Éric Chamberland 
<eric.chamberl...@giref.ulaval.ca 
<mailto:eric.chamberl...@giref.ulaval.ca>> wrote:


Hi,

we used to link our c++ code with PETSc using
PETSC_WITH_EXTERNAL_LIB variable defined in
$PETSC_DIR/lib/petsc/conf/petscvariables and everything was fine
until this night.

It seems some libs have vanished from this variable, see the diff
here:

  -lptscotcherr
  -lesmumps
  -lscotch
  -lscotcherr
  -lm
  -lX11
+-lstdc++
  -ldl
  -lmpi_usempi
  -lmpi_mpifh
  -lmpi
  -lgfortran
  -lm
  -lgfortran
  -lm
  -lgcc_s
  -lquadmath
  -lpthread
--ldl
--lmpi_cxx
--lmpi
--lstdc++
--lm
--lgcc_s
--lpthread
  -lrt
  -lm
  -lpthread
  -lz
+-lstdc++
  -ldl


causing these errors at link phase for us:


/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Op::Init(void (*)(void const*, void*, int,
MPI::Datatype const&), bool)':
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/op_inln.h:122: undefined 
reference to `ompi_mpi_cxx_op_intercept'

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Intracomm::Create_graph(int, int const*, int
const*, bool) const':
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm.h:25: undefined 
reference to `MPI::Comm::Comm()'

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Intercomm::Merge(bool) const':
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Intracomm::Split(int, int) const':
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Intracomm::Create(MPI::Group const&) const':
/opt/openmpi-1.10.2/include/openmpi/ompi/mpi/cxx/intracomm_inln.h:23: 
undefined reference to `MPI::Comm::Comm()'

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
In function `MPI::Intracomm::Clone() const':

Hi Eric,

These symbols are all coming from -lmpi_cxx. I would note that I 
believe the MPI Fo

Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

Ok guys!

You found it (again...).  We are no using mpic++ to link!!!

We are not always using the same compiler that we used to compile 
petsc+mpi, so we do not use mpic++ to compile (excepted for intelmpi).


For example, I compile MPI+Petsc with g++, but I am working with clang++ 
and may switch to g++ for my day to day work.  This is perfectly working 
since... long long time ago (I won't reveal my age... ;) )


I understand you choice, but your PETSC_WITH_EXTERNAL_LIB variable was 
helping me to painlessly find the good linking options.


I can work to manually add it when it is relevant into our compilation 
flags...


How did you managed to extract the libs from all the different flavors 
of MPI (mpich, openmpi, intelmpi) so I can now reproduce what you did 
before?


(maybe this should have been my question... )

Thanks again,

Eric

Le 18-02-10 à 12:37, Smith, Barry F. a écrit :

   Eric,

We need the entire link line.

What linker are you using C, or C++?  This is important.

Do you have dependencies on MPI C++ symbols? In other words, are you using 
C++ MPI bindings?

 I cannot explain why all the libraries you listed would disappear from 
PETSC_WITH_EXTERNAL_LIB but we did recently make a change to manual pass under 
some circumstances less system (including MPI libraries) explicitly since they 
are already usually passed by the linker. This may be causing your difficulties.

 Eagerly awaiting your reply.

  Barry



On Feb 10, 2018, at 11:29 AM, Éric Chamberland 
<eric.chamberl...@giref.ulaval.ca> wrote:

Hi Matthew,

Yes, I heard that the MPI C++ API has been deprecated.

Yes, the mpi_cxx is now missing.  Our link line is formed mainly with 
PETSC_WITH_EXTERNAL_LIB variable that is now:

PETSC_WITH_EXTERNAL_LIB = -L/opt/petsc-master_debug/lib 
-Wl,-rpath,/opt/petsc-master_debug/lib -L/opt/petsc-master_debug/lib 
-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-Wl,-rpath,/opt/openmpi-1.10.2/lib -L/opt/openmpi-1.10.2/lib 
-Wl,-rpath,/usr/lib/gcc/x86_64-redhat-linux/4.8.5 
-L/usr/lib/gcc/x86_64-redhat-linux/4.8.5 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/compiler/lib/intel64 
-L/opt/intel/composer_xe_2015.2.164/compiler/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/ipp/lib/intel64 
-L/opt/intel/composer_xe_2015.2.164/ipp/lib/intel64 
-Wl,-rpath,/opt/intel/composer_xe_2015.2.164/tbb/lib/intel64/gcc4.4 
-L/opt/intel/composer_xe_2015.2.164/tbb/lib/intel64/gcc4.4 -lpetsc -lsuperlu 
-lsuperlu_dist -lHYPRE -lcmumps -ldmumps -lsmumps -lzmumps -lmumps_common 
-lpord -lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64 -lml -lumfpack -lklu 
-lcholmod -lbtf -lccolamd -lcolamd -lcamd -lamd -lsuitesparseconfig 
-lmkl_intel_lp64 -lmkl_core -lmkl_intel_thread -lmkl_blacs_intelmpi_lp64 
-liomp5 -ldl -lpthread -lparmetis -lmetis -lptesmumps -lptscotch -lptscotcherr 
-lesmumps -lscotch -lscotcherr -lm -lX11 -lstdc++ -ldl -lmpi_usempi -lmpi_mpifh 
-lmpi -lgfortran -lm -lgfortran -lm -lgcc_s -lquadmath -lpthread -lrt -lm 
-lpthread -lz -lstdc++ -ldl
We add some stuff to this (our own compiled libs), but nothing related to MPI 
or PETSc since we used to rely on PETSC_WITH_EXTERNAL_LIB for all our 
diffrement environments (think about different petsc version, MPI libs and 
compilers: clang, icc, g++) and it used to work until yesterday changes...

As you can see in the diff, this "block" of libraries have been removed from 
PETSC_WITH_EXTERNAL_LIB: (the -- is part of the diff output):
--ldl
--lmpi_cxx
--lmpi
--lstdc++
--lm
--lgcc_s
--lpthread

and into this block there was the "-lmpi_cxx" that we need...

I could send you our whole line of link, but the error is into this small 
change introduced yesterday into master...

Thanks a lot!

Eric

Le 18-02-10 à 10:34, Matthew Knepley a écrit :

On Sat, Feb 10, 2018 at 9:42 AM, Éric Chamberland 
<eric.chamberl...@giref.ulaval.ca> wrote:
Hi,

we used to link our c++ code with PETSc using PETSC_WITH_EXTERNAL_LIB variable 
defined in $PETSC_DIR/lib/petsc/conf/petscvariables and everything was fine 
until this night.

It seems some libs have vanished from this variable, see the diff here:

  -lptscotcherr
  -lesmumps
  -lscotch
  -lscotcherr
  -lm
  -lX11
+-lstdc++
  -ldl
  -lmpi_usempi
  -lmpi_mpifh
  -lmpi
  -lgfortran
  -lm
  -lgfortran
  -lm
  -lgcc_s
  -lquadmath
  -lpthread
--ldl
--lmpi_cxx
--lmpi
--lstdc++
--lm
--lgcc_s
--lpthread
  -lrt
  -lm
  -lpthread
  -lz
+-lstdc++
  -ldl


causing these errors at link phase for us:


  
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/StatistiqueMemoire.o:
 In function `MPI::Op::Init(void (*)(void const*, void*, int, MPI::Datatype 
const&), bool)':

/opt/openmpi-1.10.2/include/
openmpi/ompi/mpi/cxx/op_inln.
h:122: undefined reference to `ompi_mpi_cxx_op_intercept'

  
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/GIREF/obj/dev/Sta

Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland

ok, here are the logs from this night and yesterday:

this night:

-

http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.10.02h00m01s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.10.02h00m01s_make.log


a day before:


http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.09.02h00m02s_configure.log
http://www.giref.ulaval.ca/~cmpgiref/petsc-master-debug/2018.02.09.02h00m02s_make.log


Eric


Le 18-02-10 à 12:51, Smith, Barry F. a écrit :

Eric,

  Please send configure.log





Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland



Le 18-02-10 à 12:38, Jed Brown a écrit :

Éric Chamberland <eric.chamberl...@giref.ulaval.ca> writes:



and into this block there was the "-lmpi_cxx" that we need...

The point is that if you are linking C++ code that calls the MPI C++
interface, then *you* should link with mpicxx or equivalent.
The funny thing, is that we are hopefully *not* using the C++ API of 
MPI.  We do use the C API since MPI 1.0.
Then, I am asking myself why this link error shows up now...since 
nothing calls it... hmmm, let me dig into this...

You should not depend on PETSc to provide anything but PETSc to your
application (so if you call other libraries that your configuration of
PETSc uses, you should take responsibility to link them explicitly; this
Wait: you mean for example if I configure MUMPS (or not) with PETSc, I 
have to build my link line with all MUMPS dependencies or not myself?
I wanted to be "lazy" and to use the same line *you* are using for 
passing libs (and in the good *order* which is not easy to manage)... as 
I can rely on this line to link "pure" petsc examples... ;)

is important when using shared libraries).  But you should definitely
not depend on PETSc to provide your application with stuff that has been
REMOVED from MPI (more than five years ago) and that PETSc does not use.
I agree, this C++ MPI API is not a very good excuse to add boring work 
into any software configuration and maintenance.


Thanks,

Eric



Re: [petsc-dev] petsc/master: unable to link in C++ with last night PETSC_WITH_EXTERNAL_LIB variable changes

2018-02-10 Thread Éric Chamberland



Le 18-02-10 à 12:58, Smith, Barry F. a écrit :



On Feb 10, 2018, at 11:51 AM, Éric Chamberland 
<eric.chamberl...@giref.ulaval.ca> wrote:

Ok guys!

You found it (again...).  We are no using mpic++ to link!!!

We are not always using the same compiler that we used to compile petsc+mpi, so 
we do not use mpic++ to compile (excepted for intelmpi).

For example, I compile MPI+Petsc with g++, but I am working with clang++ and 
may switch to g++ for my day to day work.  This is perfectly working since... 
long long time ago (I won't reveal my age... ;) )

WOW. You are lucky this worked for you. I don't think missing C++ 
compilers/linkers is ever safe?
Honestly, I think yes it is safe under some constraints (not too 
different compilers).


To be sure of it we are constantly verifying our code under more than 30 
different mixes of compiler/petsc/mpi/Os each night since 17 years... 
mixing (or not) compiler used for compiling petsc vs our code with 100% 
reproducible results of our more than 2400 different validation tests 
(finite element code).





   Eric,

Your problem is a result of Jed's constant bitching that we always list many 
libraries either redundantly or unnecessarily when we create our massive link line that 
allowed you this flexibility of linking with the "wrong" compiler. I changed 
the tests to not generate some redundant and unnecessary libraries to make Jed slightly 
less bitchy but missed the C++ one because no one uses it (except you). It would not be 
trivial for me to add the test because it would fail on any newer MPI that does not 
provide C++ bindings.

Ok, but have you tested with openmpi 1.10.x?

Maybe this is the offending library, since we do not use the MPI C++ 
API...???


Maybe I can just dump support for this "old" mpi version and it will be 
fine...


Eric



[petsc-dev] Something changed with SBAIJ on april 17?

2019-04-19 Thread Éric Chamberland via petsc-dev

Hi,

Looks like something pushed on master change or broke some sbaij 
usages.  I have two kind off errors with MatCopy:


1) MatCopy error saying: No support for this operation for this object type

[0]PETSC ERROR: - Error Message 
--
[0]PETSC ERROR: No support for this operation for this object type
[0]PETSC ERROR: MatGetRow is not supported for SBAIJ matrix format. Getting the 
upper triangular part of row, run with -mat_getrow_uppertriangular, call 
MatSetOption(mat,MAT_GETROW_UPPERTRIANGULAR,PETSC_TRUE) or 
MatGetRowUpperTriangular()
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for 
trouble shooting.
[0]PETSC ERROR: Petsc Development GIT revision: v3.11.1-277-g63b3610  GIT Date: 
2019-04-18 08:33:56 -0500
[0]PETSC ERROR: 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
 on a  named compile by Unknown Fri Apr 19 03:19:09 2019
[0]PETSC ERROR: Configure options --prefix=/opt/petsc-master_debug --with-mpi-compilers=1 
--with-mpi-dir=/opt/openmpi-1.10.2 --with-cxx-dialect=C++11 --with-make-np=12 
--with-shared-libraries=1 --with-debugging=yes --with-memalign=64 --with-visibility=0 
--with-64-bit-indices=0 --download-ml=yes --download-mumps=yes --download-superlu=yes 
--download-superlu_dist=yes --download-parmetis=yes --download-ptscotch=yes 
--download-metis=yes --download-suitesparse=yes --download-hypre=yes 
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl 
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl --with-scalapack=1 
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include 
--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
[0]PETSC ERROR: #1 MatGetRow_SeqSBAIJ() line 281 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
[0]PETSC ERROR: #2 MatGetRow() line 574 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #3 MatAXPY_Basic_Preallocate() line 138 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #4 MatAXPY() line 95 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #5 MatAYPX() line 384 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #6 MatCopy_Basic() line 4056 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #7 MatCopy_SeqAIJ() line 2844 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/aij/seq/aij.c
[0]PETSC ERROR: #8 MatCopy() line 4110 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c

2) MatCopy error saying:

Argument out of range: New nonzero at (6,7) caused a malloc

[0]PETSC ERROR: - Error Message 
--
[0]PETSC ERROR: Argument out of range
[0]PETSC ERROR: New nonzero at (6,7) caused a malloc
Use MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE) to turn off 
this check
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for 
trouble shooting.
[0]PETSC ERROR: Petsc Development GIT revision: v3.11.1-277-g63b3610  GIT Date: 
2019-04-18 08:33:56 -0500
[0]PETSC ERROR: 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.BIBProblemeGD.dev
 on a  named compile by Unknown Fri Apr 19 03:22:25 2019
[0]PETSC ERROR: Configure options --prefix=/opt/petsc-master_debug --with-mpi-compilers=1 
--with-mpi-dir=/opt/openmpi-1.10.2 --with-cxx-dialect=C++11 --with-make-np=12 
--with-shared-libraries=1 --with-debugging=yes --with-memalign=64 --with-visibility=0 
--with-64-bit-indices=0 --download-ml=yes --download-mumps=yes --download-superlu=yes 
--download-superlu_dist=yes --download-parmetis=yes --download-ptscotch=yes 
--download-metis=yes --download-suitesparse=yes --download-hypre=yes 
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl 
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl --with-scalapack=1 
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include 
--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
[0]PETSC ERROR: #1 MatSetValues_SeqSBAIJ() line 990 in 

Re: [petsc-dev] Something changed with SBAIJ on april 17?

2019-04-19 Thread Éric Chamberland via petsc-dev

Hi,

ok, I will try do to one, but since I am on vacation right now, I will 
try to do it at my return in a week.


I wanted to report the bug asap, so you may figure out the problem quickly.

Thanks,

Eric


Le 19-04-19 à 19:10, Stefano Zampini via petsc-dev a écrit :
Can you please send a MWE to reproduce the errors so that I can 
provide a fix?


Il Ven 19 Apr 2019, 17:00 Matthew Knepley via petsc-dev 
mailto:petsc-dev@mcs.anl.gov>> ha scritto:


On Fri, Apr 19, 2019 at 9:40 AM Balay, Satish via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> wrote:

There were a few merges in the the past few days.

For ex:

https://bitbucket.org/petsc/petsc/pull-requests/1547/add-support-for-zeroing-rows-and-columns/diff

Perhaps you can narrow down to the commit that triggered this
change with git bisect.


I think its this commit:


https://bitbucket.org/petsc/petsc/commits/2b4bbc58b197e97e85869bd03594884bbca73c67

    Matt

cc: Stefano

Satish

On Fri, 19 Apr 2019, Éric Chamberland via petsc-dev wrote:

> Hi,
>
> Looks like something pushed on master change or broke some
sbaij usages.  I
> have two kind off errors with MatCopy:
>
> 1) MatCopy error saying: No support for this operation for
this object type
>
> [0]PETSC ERROR: - Error Message
> --
> [0]PETSC ERROR: No support for this operation for this
object type
> [0]PETSC ERROR: MatGetRow is not supported for SBAIJ matrix
format. Getting
> the upper triangular part of row, run with
-mat_getrow_uppertriangular, call
> MatSetOption(mat,MAT_GETROW_UPPERTRIANGULAR,PETSC_TRUE) or
> MatGetRowUpperTriangular()
> [0]PETSC ERROR: See
http://www.mcs.anl.gov/petsc/documentation/faq.html for
> trouble shooting.
> [0]PETSC ERROR: Petsc Development GIT revision:
v3.11.1-277-g63b3610  GIT
> Date: 2019-04-18 08:33:56 -0500
> [0]PETSC ERROR:
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
<http://Test.deliMEFPP.dev>
> on a  named compile by Unknown Fri Apr 19 03:19:09 2019
> [0]PETSC ERROR: Configure options
--prefix=/opt/petsc-master_debug
> --with-mpi-compilers=1 --with-mpi-dir=/opt/openmpi-1.10.2
> --with-cxx-dialect=C++11 --with-make-np=12
--with-shared-libraries=1
> --with-debugging=yes --with-memalign=64 --with-visibility=0
> --with-64-bit-indices=0 --download-ml=yes --download-mumps=yes
> --download-superlu=yes --download-superlu_dist=yes
--download-parmetis=yes
> --download-ptscotch=yes --download-metis=yes
--download-suitesparse=yes
> --download-hypre=yes
>
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64
> --with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl
> --with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl
> --with-scalapack=1
>
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include
>

--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64
> -lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
> [0]PETSC ERROR: #1 MatGetRow_SeqSBAIJ() line 281 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
> [0]PETSC ERROR: #2 MatGetRow() line 574 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
> [0]PETSC ERROR: #3 MatAXPY_Basic_Preallocate() line 138 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
> [0]PETSC ERROR: #4 MatAXPY() line 95 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
> [0]PETSC ERROR: #5 MatAYPX() line 384 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
> [0]PETSC ERROR: #6 MatCopy_Basic() line 4056 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
> [0]PETSC ERROR: #7 MatCopy_SeqAIJ() line 2844 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/aij/

Re: [petsc-dev] Something changed with SBAIJ on april 17?

2019-04-21 Thread Éric Chamberland via petsc-dev

Hi Stefano,

sure!

configuration is running with your branch and tests will begin later.  I 
will see and share the results tomorrow.


thanks! :)

Eric


Le 19-04-21 à 17:21, Stefano Zampini a écrit :

Eric

I have opened a PRmay fix the issues you reported 
https://bitbucket.org/petsc/petsc/pull-requests/1571/fix-sbaij/diff
Could you please try 
https://bitbucket.org/petsc/petsc/branch/stefano_zampini/fix-matcopy-sbaij? 
(off maint)


Thanks

Il giorno ven 19 apr 2019 alle ore 23:26 Éric Chamberland via 
petsc-dev mailto:petsc-dev@mcs.anl.gov>> ha 
scritto:


Hi,

ok, I will try do to one, but since I am on vacation right now, I
will try to do it at my return in a week.

I wanted to report the bug asap, so you may figure out the problem
quickly.

Thanks,

Eric


Le 19-04-19 à 19:10, Stefano Zampini via petsc-dev a écrit :

Can you please send a MWE to reproduce the errors so that I can
provide a fix?

Il Ven 19 Apr 2019, 17:00 Matthew Knepley via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> ha scritto:

On Fri, Apr 19, 2019 at 9:40 AM Balay, Satish via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> wrote:

There were a few merges in the the past few days.

For ex:

https://bitbucket.org/petsc/petsc/pull-requests/1547/add-support-for-zeroing-rows-and-columns/diff

Perhaps you can narrow down to the commit that triggered
this change with git bisect.


I think its this commit:


https://bitbucket.org/petsc/petsc/commits/2b4bbc58b197e97e85869bd03594884bbca73c67

    Matt

cc: Stefano

Satish

On Fri, 19 Apr 2019, Éric Chamberland via petsc-dev wrote:

> Hi,
>
> Looks like something pushed on master change or broke
some sbaij usages.  I
> have two kind off errors with MatCopy:
>
> 1) MatCopy error saying: No support for this operation
for this object type
>
> [0]PETSC ERROR: - Error Message
>
--
> [0]PETSC ERROR: No support for this operation for this
object type
> [0]PETSC ERROR: MatGetRow is not supported for SBAIJ
matrix format. Getting
> the upper triangular part of row, run with
-mat_getrow_uppertriangular, call
> MatSetOption(mat,MAT_GETROW_UPPERTRIANGULAR,PETSC_TRUE) or
> MatGetRowUpperTriangular()
> [0]PETSC ERROR: See
http://www.mcs.anl.gov/petsc/documentation/faq.html for
> trouble shooting.
> [0]PETSC ERROR: Petsc Development GIT revision:
v3.11.1-277-g63b3610  GIT
> Date: 2019-04-18 08:33:56 -0500
> [0]PETSC ERROR:
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
<http://Test.deliMEFPP.dev>
> on a  named compile by Unknown Fri Apr 19 03:19:09 2019
> [0]PETSC ERROR: Configure options
--prefix=/opt/petsc-master_debug
> --with-mpi-compilers=1 --with-mpi-dir=/opt/openmpi-1.10.2
> --with-cxx-dialect=C++11 --with-make-np=12
--with-shared-libraries=1
> --with-debugging=yes --with-memalign=64 --with-visibility=0
> --with-64-bit-indices=0 --download-ml=yes
--download-mumps=yes
> --download-superlu=yes --download-superlu_dist=yes
--download-parmetis=yes
> --download-ptscotch=yes --download-metis=yes
--download-suitesparse=yes
> --download-hypre=yes
>

--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64
>
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl
>
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl
> --with-scalapack=1
>

--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include
>

--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64
> -lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
> [0]PETSC ERROR: #1 MatGetRow_SeqSBAIJ() line 281 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
> [0]PETSC ERROR: #2 MatGetRow() line 574 in
>

/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
> [0]PE

Re: [petsc-dev] Something changed with SBAIJ on april 17?

2019-04-22 Thread Éric Chamberland via petsc-dev

Hi Stefano,

ok, it will be tested tonight.

Meanwhile, I ran on example to extract some information you asked for:

Le 19-04-22 à 18:42, Stefano Zampini a écrit :

Eric,

I have update (force pushed) the branch. It should be fixed now, Can 
you please confirm?


Thanks

Il giorno lun 22 apr 2019 alle ore 09:00 Stefano Zampini 
mailto:stefano.zamp...@gmail.com>> ha scritto:


Eric

I'll try to reproduce your setting.
Few questions.

Is your AIJ matrix lA symmetric?


No, it is not.


Does it have any block size set?


No, block size is 1.


Do you get the error the first time you do mat copy? Or in
subsequent ones?


At the first MatCopy... which is following the MatConvert...

Thanks,

Eric





Il Lun 22 Apr 2019, 08:41 Éric Chamberland via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> ha scritto:

Hi,

the patch fixed the 1st kind of error I got ("No support for
this operation for this object type"), but I still have all
the same faulty tests now returning the 2nd error I reported:

[0]PETSC ERROR: - Error Message 
--
[0]PETSC ERROR: Argument out of range
[0]PETSC ERROR: New nonzero at (0,1) caused a malloc
Use MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE) to 
turn off this check
[0]PETSC ERROR: Seehttp://www.mcs.anl.gov/petsc/documentation/faq.html  
for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.11.1, unknown
[0]PETSC ERROR: 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
  <http://Test.deliMEFPP.dev>  on a  named compile by Unknown Sun Apr 21 
18:14:41 2019
[0]PETSC ERROR: Configure options --prefix=/opt/petsc-master_debug 
--with-mpi-compilers=1 --with-mpi-dir=/opt/openmpi-1.10.2 --with-cxx-dialect=C++11 
--with-make-np=12 --with-shared-libraries=1 --with-debugging=yes --with-memalign=64 
--with-visibility=0 --with-64-bit-indices=0 --download-ml=yes --download-mumps=yes 
--download-superlu=yes --download-superlu_dist=yes --download-parmetis=yes 
--download-ptscotch=yes --download-metis=yes --download-suitesparse=yes 
--download-hypre=yes 
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl 
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl --with-scalapack=1 
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include 
--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
[0]PETSC ERROR: #1 MatSetValues_SeqSBAIJ() line 992 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
[0]PETSC ERROR: #2 MatSetValues() line 1407 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #3 MatAXPY_BasicWithPreallocation() line 171 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #4 MatAXPY() line 52 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #5 MatAYPX() line 348 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #6 MatCopy_Basic() line 4044 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #7 MatCopy_SeqAIJ() line 2844 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/aij/seq/aij.c
[0]PETSC ERROR: #8 MatCopy() line 4098 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c

We are calling a MatCopy from an aij (lA) to sbaij (lB) matrix
with DIFFERENT_NONZERO_PATTERN option.

But on first call, the SBAIJ matrix has first been created
then filled with MatConvert call:

MatConvert(lA,MATSBAIJ, MAT_INITIAL_MATRIX, );

I just noticed we then do a:
MatSetOption(lA, MAT_SYMMETRIC, PETSC_FALSE);
(I have to find why???)

and on other calls, we call the "faulty" MatCopy with
previously created matrices:

MatCopy(lA,lB,DIFFERENT_NONZERO_PATTERN);

which gives the "Argument out of range" error...

    Thanks,

    Eric

Le 19-04-21 à 22:52, Éric Chamberland via petsc-dev a écrit :


Hi Stefano,

sure!

configuration is running with your branch and tests will
begin later.  I will see and sha

Re: [petsc-dev] Something changed with SBAIJ on april 17?

2019-04-21 Thread Éric Chamberland via petsc-dev

Hi,

the patch fixed the 1st kind of error I got ("No support for this 
operation for this object type"), but I still have all the same faulty 
tests now returning the 2nd error I reported:


[0]PETSC ERROR: - Error Message 
--
[0]PETSC ERROR: Argument out of range
[0]PETSC ERROR: New nonzero at (0,1) caused a malloc
Use MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE) to turn off 
this check
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for 
trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.11.1, unknown
[0]PETSC ERROR: 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
 on a  named compile by Unknown Sun Apr 21 18:14:41 2019
[0]PETSC ERROR: Configure options --prefix=/opt/petsc-master_debug --with-mpi-compilers=1 
--with-mpi-dir=/opt/openmpi-1.10.2 --with-cxx-dialect=C++11 --with-make-np=12 
--with-shared-libraries=1 --with-debugging=yes --with-memalign=64 --with-visibility=0 
--with-64-bit-indices=0 --download-ml=yes --download-mumps=yes --download-superlu=yes 
--download-superlu_dist=yes --download-parmetis=yes --download-ptscotch=yes 
--download-metis=yes --download-suitesparse=yes --download-hypre=yes 
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl 
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl --with-scalapack=1 
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include 
--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
[0]PETSC ERROR: #1 MatSetValues_SeqSBAIJ() line 992 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
[0]PETSC ERROR: #2 MatSetValues() line 1407 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #3 MatAXPY_BasicWithPreallocation() line 171 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #4 MatAXPY() line 52 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #5 MatAYPX() line 348 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #6 MatCopy_Basic() line 4044 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #7 MatCopy_SeqAIJ() line 2844 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/aij/seq/aij.c
[0]PETSC ERROR: #8 MatCopy() line 4098 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c

We are calling a MatCopy from an aij (lA) to sbaij (lB) matrix with 
DIFFERENT_NONZERO_PATTERN option.


But on first call, the SBAIJ matrix has first been created then filled 
with MatConvert call:


MatConvert(lA,MATSBAIJ, MAT_INITIAL_MATRIX, );

I just noticed we then do a:
MatSetOption(lA, MAT_SYMMETRIC, PETSC_FALSE);
(I have to find why???)

and on other calls, we call the "faulty" MatCopy with previously created 
matrices:


MatCopy(lA,lB,DIFFERENT_NONZERO_PATTERN);

which gives the "Argument out of range" error...

Thanks,

Eric

Le 19-04-21 à 22:52, Éric Chamberland via petsc-dev a écrit :


Hi Stefano,

sure!

configuration is running with your branch and tests will begin later.  
I will see and share the results tomorrow.


thanks! :)

Eric


Le 19-04-21 à 17:21, Stefano Zampini a écrit :

Eric

I have opened a PRmay fix the issues you reported 
https://bitbucket.org/petsc/petsc/pull-requests/1571/fix-sbaij/diff
Could you please try 
https://bitbucket.org/petsc/petsc/branch/stefano_zampini/fix-matcopy-sbaij? 
(off maint)


Thanks

Il giorno ven 19 apr 2019 alle ore 23:26 Éric Chamberland via 
petsc-dev mailto:petsc-dev@mcs.anl.gov>> ha 
scritto:


Hi,

ok, I will try do to one, but since I am on vacation right now, I
will try to do it at my return in a week.

I wanted to report the bug asap, so you may figure out the
problem quickly.

Thanks,

Eric


Le 19-04-19 à 19:10, Stefano Zampini via petsc-dev a écrit :

Can you please send a MWE to reproduce the errors so that I can
provide a fix?

Il Ven 19 Apr 2019, 17:00 Matthew Knepley via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> ha scritto:

On Fri, Apr 19, 2019 at 9:40 AM Balay, Satish via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> wrote:

There were a few merges in the the past few days.

For ex:

https://bitbucket.

Re: [petsc-dev] Something changed with SBAIJ on april 17?

2019-04-22 Thread Éric Chamberland via petsc-dev

Hi Stefano,

I confirm that your commit 0a16297aeba2de71 fixed all bugs we got since 
april 17!


Thanks a lot!!! :)

Eric


Le 19-04-22 à 22:42, Éric Chamberland via petsc-dev a écrit :


Hi Stefano,

ok, it will be tested tonight.

Meanwhile, I ran on example to extract some information you asked for:

Le 19-04-22 à 18:42, Stefano Zampini a écrit :

Eric,

I have update (force pushed) the branch. It should be fixed now, Can 
you please confirm?


Thanks

Il giorno lun 22 apr 2019 alle ore 09:00 Stefano Zampini 
mailto:stefano.zamp...@gmail.com>> ha 
scritto:


Eric

I'll try to reproduce your setting.
Few questions.

Is your AIJ matrix lA symmetric?


No, it is not.


Does it have any block size set?


No, block size is 1.


Do you get the error the first time you do mat copy? Or in
subsequent ones?


At the first MatCopy... which is following the MatConvert...

Thanks,

Eric





Il Lun 22 Apr 2019, 08:41 Éric Chamberland via petsc-dev
mailto:petsc-dev@mcs.anl.gov>> ha scritto:

Hi,

the patch fixed the 1st kind of error I got ("No support for
this operation for this object type"), but I still have all
the same faulty tests now returning the 2nd error I reported:

[0]PETSC ERROR: - Error Message 
--
[0]PETSC ERROR: Argument out of range
[0]PETSC ERROR: New nonzero at (0,1) caused a malloc
Use MatSetOption(A, MAT_NEW_NONZERO_ALLOCATION_ERR, PETSC_FALSE) to 
turn off this check
[0]PETSC ERROR: Seehttp://www.mcs.anl.gov/petsc/documentation/faq.html  
for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.11.1, unknown
[0]PETSC ERROR: 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/BIB/bin/Test.deliMEFPP.dev
  <http://Test.deliMEFPP.dev>  on a  named compile by Unknown Sun Apr 21 
18:14:41 2019
[0]PETSC ERROR: Configure options --prefix=/opt/petsc-master_debug 
--with-mpi-compilers=1 --with-mpi-dir=/opt/openmpi-1.10.2 --with-cxx-dialect=C++11 
--with-make-np=12 --with-shared-libraries=1 --with-debugging=yes --with-memalign=64 
--with-visibility=0 --with-64-bit-indices=0 --download-ml=yes --download-mumps=yes 
--download-superlu=yes --download-superlu_dist=yes --download-parmetis=yes 
--download-ptscotch=yes --download-metis=yes --download-suitesparse=yes 
--download-hypre=yes 
--with-blaslapack-dir=/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
--with-mkl_pardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl 
--with-mkl_cpardiso-dir=/opt/intel/composer_xe_2015.2.164/mkl --with-scalapack=1 
--with-scalapack-include=/opt/intel/composer_xe_2015.2.164/mkl/include 
--with-scalapack-lib="-L/opt/intel/composer_xe_2015.2.164/mkl/lib/intel64 
-lmkl_scalapack_lp64 -lmkl_blacs_openmpi_lp64"
[0]PETSC ERROR: #1 MatSetValues_SeqSBAIJ() line 992 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/sbaij/seq/sbaij.c
[0]PETSC ERROR: #2 MatSetValues() line 1407 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #3 MatAXPY_BasicWithPreallocation() line 171 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #4 MatAXPY() line 52 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #5 MatAYPX() line 348 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/utils/axpy.c
[0]PETSC ERROR: #6 MatCopy_Basic() line 4044 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c
[0]PETSC ERROR: #7 MatCopy_SeqAIJ() line 2844 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/impls/aij/seq/aij.c
[0]PETSC ERROR: #8 MatCopy() line 4098 in 
/pmi/cmpbib/compilation_BIB_gcc_redhat_petsc-master_debug/COMPILE_AUTO/petsc-master-debug/src/mat/interface/matrix.c

We are calling a MatCopy from an aij (lA) to sbaij (lB)
matrix with DIFFERENT_NONZERO_PATTERN option.

But on first call, the SBAIJ matrix has first been created
then filled with MatConvert call:

MatConvert(lA,MATSBAIJ, MAT_INITIAL_MATRIX, );

I just noticed we then do a:
MatSetOption(lA, MAT_SYMMETRIC, PETSC_FALSE);
(I have to find why???)

and on other calls, we call the "faulty" MatCopy with
previously created matrices:

MatCopy(lA,lB,DIFFERENT_NONZERO_PATTERN);

which gives the "Argument out of range" error...

    Thanks,

    Eric

Le 19-04-21 à 22:52, Éri