Skip to content

Commit ec32621

Browse files
author
root
committed
refactor: move parallel_2d to module_base
1 parent f7b62a7 commit ec32621

File tree

31 files changed

+47
-59
lines changed

31 files changed

+47
-59
lines changed

CMakeLists.txt

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -421,10 +421,8 @@ else()
421421
include_directories(${FFTW3_INCLUDE_DIRS})
422422
list(APPEND math_libs FFTW3::FFTW3 LAPACK::LAPACK BLAS::BLAS)
423423

424-
if(ENABLE_LCAO)
425-
find_package(ScaLAPACK REQUIRED)
426-
list(APPEND math_libs ScaLAPACK::ScaLAPACK)
427-
endif()
424+
find_package(ScaLAPACK REQUIRED)
425+
list(APPEND math_libs ScaLAPACK::ScaLAPACK)
428426

429427
if(USE_OPENMP)
430428
list(APPEND math_libs FFTW3::FFTW3_OMP)

source/Makefile.Objects

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,7 @@ OBJS_BASE=abfs-vector3_order.o\
168168
broyden_mixing.o\
169169
memory_op.o\
170170
device.o\
171+
parallel_2d.o\
171172

172173
OBJS_CELL=atom_pseudo.o\
173174
atom_spec.o\
@@ -377,7 +378,6 @@ OBJS_ORBITAL=ORB_atomic.o\
377378
ORB_nonlocal.o\
378379
ORB_nonlocal_lm.o\
379380
ORB_read.o\
380-
parallel_2d.o\
381381
parallel_orbitals.o\
382382
atomic_radials.o\
383383
hydrogen_radials.o\

source/module_base/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ add_library(
5353
parallel_device.cpp
5454
spherical_bessel_transformer.cpp
5555
cubic_spline.cpp
56+
parallel_2d.cpp
5657
module_mixing/mixing_data.cpp
5758
module_mixing/mixing.cpp
5859
module_mixing/plain_mixing.cpp
File renamed without changes.
File renamed without changes.

source/module_base/test/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,4 +241,5 @@ if(ENABLE_GOOGLEBENCH)
241241
LIBS parameter
242242
SOURCES perf_sphbes_test.cpp ../math_sphbes.cpp ../timer.cpp
243243
)
244+
244245
endif()

source/module_base/test_parallel/CMakeLists.txt

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,19 @@ add_test(NAME base_parallel_reduce_test
3434
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
3535
)
3636

37+
AddTest(
38+
TARGET parallel_2d_test
39+
SOURCES parallel_2d_test.cpp ../parallel_2d.cpp
40+
LIBS parameter ${math_libs} device base
41+
)
42+
43+
install(FILES parallel_2d_test.sh DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
44+
find_program(BASH bash)
45+
add_test(NAME parallel_2d_test_para
46+
COMMAND ${BASH} parallel_2d_test.sh
47+
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
48+
)
49+
3750
if(ENABLE_LCAO)
3851
# figure out the lib that provides BLACS
3952
if(MKLROOT)

source/module_basis/module_ao/CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ if(ENABLE_LCAO)
88
ORB_nonlocal.cpp
99
ORB_nonlocal_lm.cpp
1010
ORB_read.cpp
11-
parallel_2d.cpp
1211
parallel_orbitals.cpp
1312
)
1413

0 commit comments

Comments
 (0)