[petsc-dev] [petsc-maint #129715] __float128 complex

Jose E. Roman jroman at dsic.upv.es
Wed Aug 22 11:56:41 CDT 2012


El 22/08/2012, a las 18:52, Jose E. Roman escribió:

> f2cblaslapack is more or less prepared for this case already (it is not much tested though, we will make some tests for the w* subroutines tomorrow).
> 
> What is not ready is PETSc itself. Some definitions are missing. For instance, PetscScalar is undefined, so one should add the following to petscmath.h:106:
> 
> #elif defined(PETSC_USE_REAL___FLOAT128)
> typedef __complex128 PetscScalar;
> 
> #define PetscRealPart(a)      crealq(a)
> #define PetscImaginaryPart(a) cimagq(a)
> #define PetscAbsScalar(a)     cabsq(a)
> #define PetscConj(a)          conjq(a)
> #define PetscSqrtScalar(a)    csqrtq(a)
> #define PetscPowScalar(a,b)   cpowq(a,b)
> #define PetscExpScalar(a)     cexpq(a)
> #define PetscLogScalar(a)     clogq(a)
> #define PetscSinScalar(a)     csinq(a)
> #define PetscCosScalar(a)     ccosq(a)
> 
> Similarly, MPIU_SCALAR should be defined. Maybe other as well.
> 
> Jose

I forgot to mention that the Lapack w* subroutines should be added in the petscblaslapack*h files.




More information about the petsc-dev mailing list