Attention une mise à jour du service Gitlab va être effectuée le mardi 30 novembre entre 17h30 et 18h00. Cette mise à jour va générer une interruption du service dont nous ne maîtrisons pas complètement la durée mais qui ne devrait pas excéder quelques minutes. Cette mise à jour intermédiaire en version 14.0.12 nous permettra de rapidement pouvoir mettre à votre disposition une version plus récente.

Commit d058572a authored by BLANCHARD Pierre's avatar BLANCHARD Pierre
Browse files

Clean up some routines that are not used anymore in blas interface and UnifKernel.

parent 1ff261cf
...@@ -332,17 +332,6 @@ public: ...@@ -332,17 +332,6 @@ public:
FY[j]); FY[j]);
} }
// // Perform entrywise product using BLAS and MKL routines
// // PB: not necessary faster than the naive version
// FComplex<FReal> tmpFX[rc];
// FBlas::c_setzero(rc,reinterpret_cast<FReal*>(tmpFX));
// FMkl::c_had(rc,reinterpret_cast<const FReal* const>(FC + idx*rc),
// reinterpret_cast<const FReal* const>(FY),
// reinterpret_cast<FReal* const>(tmpFX));
// // Scale
// FBlas::c_axpy(rc,&scale,reinterpret_cast<FReal* const>(tmpFX),
// reinterpret_cast<FReal* const>(FX));
} }
...@@ -529,17 +518,6 @@ public: ...@@ -529,17 +518,6 @@ public:
FX[j].addMul(FC[TreeLevel][d][idx*opt_rc + j], FY[j]); FX[j].addMul(FC[TreeLevel][d][idx*opt_rc + j], FY[j]);
} }
// // Perform entrywise product using BLAS and MKL routines
// // PB: not necessary faster than the naive version
// FComplex<FReal> tmpFX[rc];
// FBlas::c_setzero(rc,reinterpret_cast<FReal*>(tmpFX));
// FMkl::c_had(rc,reinterpret_cast<const FReal* const>(FC + idx*rc),
// reinterpret_cast<const FReal* const>(FY),
// reinterpret_cast<FReal* const>(tmpFX));
// // Scale
// FBlas::c_axpy(rc,&scale,reinterpret_cast<FReal* const>(tmpFX),
// reinterpret_cast<FReal* const>(FX));
} }
......
...@@ -83,16 +83,6 @@ extern "C" ...@@ -83,16 +83,6 @@ extern "C"
double*, const unsigned*, int*); double*, const unsigned*, int*);
void dpotrf_(const char*, const unsigned*, double*, const unsigned*, int*); void dpotrf_(const char*, const unsigned*, double*, const unsigned*, int*);
#ifdef SCALFMM_USE_MKL_AS_BLAS
// mkl: hadamard product is not implemented in mkl_blas
void vdmul_(const unsigned* n, const double*, const double*, double*);
void vsmul_(const unsigned* n, const float*, const float*, float*);
void vzmul_(const unsigned* n, const double*, const double*, double*);
void vcmul_(const unsigned* n, const float*, const float*, float*);
#else
// TODO create interface for hadamard product in case an external Blas is used
#endif
// single ////////////////////////////////////////////////////////// // single //////////////////////////////////////////////////////////
// blas 1 // blas 1
float sdot_(const unsigned*, const float*, const unsigned*, const float*, const unsigned*); float sdot_(const unsigned*, const float*, const unsigned*, const float*, const unsigned*);
...@@ -171,41 +161,6 @@ extern "C" ...@@ -171,41 +161,6 @@ extern "C"
} }
// Hadamard (i.e. entrywise) product:
// NB: The following optimized routines are currently not used
// since they have not proved their efficiency in comparison
// with a naive application of the entrywise product.
#ifdef SCALFMM_USE_MKL_AS_BLAS
//#include "mkl_vml.h"
namespace FMkl{
// Hadamard product: dest[i]=a[i]*b[i]
inline void had(const unsigned n, const double* const a, const double* const b, double* const dest)
{ vdmul_(&n, a, b, dest); }
inline void had(const unsigned n, const float* const a, const float* const b, float* const dest)
{ vsmul_(&n, a, b, dest); }
inline void c_had(const unsigned n, const double* const a, const double* const b, double* const dest)
{ vzmul_(&n, a, b, dest); }
inline void c_had(const unsigned n, const float* const a, const float* const b, float* const dest)
{ vcmul_(&n, a, b, dest); }
}
#else
namespace FBlas{
// TODO create interface for Hadamard product in case an external Blas is used
}
#endif
// end Hadamard product
namespace FBlas { namespace FBlas {
// copy // copy
......
...@@ -397,12 +397,6 @@ int main(int argc, char ** argv){ ...@@ -397,12 +397,6 @@ int main(int argc, char ** argv){
time.tic(); time.tic();
// Application of M2L in FOURIER SPACE // Application of M2L in FOURIER SPACE
// > Use FMkl::c_had for hadamard product
// if mkl is used as blas (TODO otherwise use FBlas::c_had())
// FMkl::c_had(rc,reinterpret_cast<FReal*>(FT),
// reinterpret_cast<FReal*>(FPMultExp),
// reinterpret_cast<FReal*>(FPLocalExp));
// > or perform entrywise product manually
for (unsigned int pj=0; pj<rc; ++pj){ for (unsigned int pj=0; pj<rc; ++pj){
FPLocalExp[pj]=FT[pj]; FPLocalExp[pj]=FT[pj];
FPLocalExp[pj]*=FPMultExp[pj]; FPLocalExp[pj]*=FPMultExp[pj];
......
...@@ -437,12 +437,6 @@ int main(int argc, char ** argv){ ...@@ -437,12 +437,6 @@ int main(int argc, char ** argv){
time.tic(); time.tic();
// Application of M2L in FOURIER SPACE // Application of M2L in FOURIER SPACE
// > Use FMkl::c_had for hadamard product
// if mkl is used as blas (TODO otherwise use FBlas::c_had())
// FMkl::c_had(rc,reinterpret_cast<FReal*>(FT),
// reinterpret_cast<FReal*>(FPMultExp),
// reinterpret_cast<FReal*>(FPLocalExp));
// > or perform entrywise product manually
FComplex<FReal> tmpFX; FComplex<FReal> tmpFX;
for (unsigned int idxLhs=0; idxLhs<nlhs; ++idxLhs){ for (unsigned int idxLhs=0; idxLhs<nlhs; ++idxLhs){
unsigned int idxRhs = idxLhs % npot; unsigned int idxRhs = idxLhs % npot;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment