Stefano,

    Thanks for doing this.  A couple of comments:

       - probably would be better if the change for each package was a separate 
change set/patch. (I guessing they are not)

       -  I don't like this:

+/* calls to MUMPS */
+#if defined(PETSC_USE_COMPLEX)
+#if defined(PETSC_USE_REAL_SINGLE)
+#define PetscMUMPS_c cmumps_c
+#else
+#define PetscMUMPS_c zmumps_c
+#endif
+#else
+#if defined(PETSC_USE_REAL_SINGLE)
+#define PetscMUMPS_c smumps_c
+#else
+#define PetscMUMPS_c dmumps_c
+#endif
+#endif

            I understand why you are doing this (since xmumps_c appears in 
multiple places in the code and you don't want the ugly #ifdef at each of those 
places) but essentially you are doing what the mumps people should have done, 
providing a polymorphic interface to their solver. By doing this you are making 
the PETSc--mumps interface less transparent and introducing the complexity of 
additional macros. I think it would be better to use the old style we had 
(where the #ifdef appear each time as needed in the code).

    Barry



 On Sep 21, 2012, at 9:41 AM, Stefano Zampini <stefano.zampini at gmail.com> 
wrote:

> Sorry. I forgot the attachment
> 
> 2012/9/21 Stefano Zampini <stefano.zampini at gmail.com>
> Yesterday it was the first time I try to build a single-precision version of 
> PETSc with some external packages.
> I noticed that SuperLU and MUMPS, which are currently fully compiled (i.e. 
> with scalar types s,d,c and z) by the configure, cannot be used when 
> requiring single precision at configure time. So I decided to wrote a patch 
> to enable their use when PETSC_USE_REAL_SINGLE is defined.
> 
> Attached please find a patch. Is there any reason for which you did not 
> already provide this functionality?
> I tested the patch on BlueGene/Q and it works for scalar types real. 
> Currently, I don't have a complex version of PETSc installed. Can someone 
> test it?
> 
> I also noticed that UMFPACK (which itself does not have support for single 
> precision), is accepted by the configure by requiring --with-precision=single 
> --download-umfpack=1. Is it normal? It breaks the final linking of the 
> executables.  
> 
> -- 
> Stefano
> 
> 
> 
> -- 
> Stefano
> <patch_mumps_superlu_single.diff>

Reply via email to