Skip to content

Commit 281bd9b

Browse files
committed
remove abundant files
1 parent 6d495fb commit 281bd9b

File tree

6 files changed

+180
-181
lines changed

6 files changed

+180
-181
lines changed

source/main.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// AUTHOR : mohan
33
// DATE : 2008-11-10
44
//==========================================================
5+
56
#include "driver.h"
67
#include "fftw3.h"
78
#include "module_base/parallel_global.h"

source/module_basis/module_pw/pw_transform_k.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,7 @@ void PW_Basis_K::recip2real_gpu(const std::complex<FPTYPE>* in,
518518

519519
const int startig = ik * this->npwk_max;
520520
const int npw_k = this->npwk[ik];
521+
521522
set_3d_fft_box_op<FPTYPE, base_device::DEVICE_GPU>()(npw_k,
522523
this->ig2ixyz_k + startig,
523524
in,

source/module_basis/module_pw/test_gpu/pw_basis_k_C2C.cpp

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ class PW_BASIS_K_GPU_TEST : public ::testing::Test
196196
}
197197
};
198198

199-
using MixedTypes = ::testing::Types<TypePair<float, base_device::DEVICE_GPU>,
199+
using MixedTypes = ::testing::Types<TypePair<float, base_device::DEVICE_GPU>,
200200
TypePair<double, base_device::DEVICE_GPU> >;
201201

202202
TYPED_TEST_CASE(PW_BASIS_K_GPU_TEST, MixedTypes);
@@ -239,20 +239,19 @@ TYPED_TEST(PW_BASIS_K_GPU_TEST, FloatDouble)
239239
ModulePW::PW_Basis_K pwtest;
240240
pwtest.set_device("gpu");
241241
pwtest.set_precision("mixing");
242-
// if (typeid(T) == typeid(float))
243-
// {
244-
// pwtest.fft_bundle.setfft("gpu", "single");
245-
// }
246-
// if (typeid(T) == typeid(double))
247-
// {
248-
std::cout << "Using double precision" << std::endl;
242+
if (typeid(T) == typeid(float))
243+
{
244+
pwtest.fft_bundle.setfft("gpu", "single");
245+
}
246+
else if (typeid(T) == typeid(double))
247+
{
249248
pwtest.fft_bundle.setfft("gpu", "double");
250-
// }
251-
// else
252-
// {
253-
// cout << "Error: Unsupported type" << endl;
254-
// return;
255-
// }
249+
}
250+
else
251+
{
252+
cout << "Error: Unsupported type" << endl;
253+
return;
254+
}
256255
this->init(pwtest);
257256
int startiz = pwtest.startz_current;
258257
const int nx = pwtest.nx;
@@ -288,9 +287,8 @@ TYPED_TEST(PW_BASIS_K_GPU_TEST, convulution)
288287
{
289288
pwtest.fft_bundle.setfft("gpu", "single");
290289
}
291-
if (typeid(T) == typeid(double))
290+
else if (typeid(T) == typeid(double))
292291
{
293-
std::cout << "Using double precision" << std::endl;
294292
pwtest.fft_bundle.setfft("gpu", "double");
295293
}
296294
else

0 commit comments

Comments
 (0)