.
This commit is contained in:
@@ -90,13 +90,13 @@ endfunction()
|
|||||||
configure_file(${CMAKE_CURRENT_LIST_DIR}/run-all.sh ${CMAKE_CURRENT_BINARY_DIR}/run-all.sh COPYONLY)
|
configure_file(${CMAKE_CURRENT_LIST_DIR}/run-all.sh ${CMAKE_CURRENT_BINARY_DIR}/run-all.sh COPYONLY)
|
||||||
|
|
||||||
if (MPI_FOUND)
|
if (MPI_FOUND)
|
||||||
add_executable(main main.cpp)
|
add_executable(hello-world hello_world.cpp)
|
||||||
target_link_libraries(main MPI::MPI_CXX)
|
target_link_libraries(hello-world MPI::MPI_CXX)
|
||||||
# target_include_directories(main PRIVATE ${MPI_CXX_INCLUDE_PATH})
|
# target_include_directories(hello-world PRIVATE ${MPI_CXX_INCLUDE_PATH})
|
||||||
# target_compile_options(main PRIVATE ${MPI_CXX_COMPILE_FLAGS})
|
# target_compile_options(hello-world PRIVATE ${MPI_CXX_COMPILE_FLAGS})
|
||||||
# target_link_libraries(main ${MPI_CXX_LIBRARIES} ${MPI_CXX_LINK_FLAGS})
|
# target_link_libraries(hello-world ${MPI_CXX_LIBRARIES} ${MPI_CXX_LINK_FLAGS})
|
||||||
set_cxx_options(main)
|
set_cxx_options(hello-world)
|
||||||
set_cxx_standard(main)
|
set_cxx_standard(hello-world)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (MPI_FOUND)
|
if (MPI_FOUND)
|
||||||
|
19
Makefile
19
Makefile
@@ -1,19 +0,0 @@
|
|||||||
TARGETS = main one-sided persistent
|
|
||||||
|
|
||||||
all: ${TARGETS}
|
|
||||||
|
|
||||||
.PHONY: clean
|
|
||||||
clean:
|
|
||||||
rm -f ${TARGETS} *.o
|
|
||||||
|
|
||||||
MPICXX := mpicxx
|
|
||||||
CXXFLAGS := -std=c++11 -Wall -Wextra -Wshadow -pedantic -O2
|
|
||||||
|
|
||||||
main: main.cpp Makefile
|
|
||||||
$(MPICXX) $(CXXFLAGS) $< -o $@
|
|
||||||
|
|
||||||
one-sided: one_sided.cpp Makefile
|
|
||||||
$(MPICXX) $(CXXFLAGS) $< -o $@
|
|
||||||
|
|
||||||
persistent: persistent.cpp Makefile
|
|
||||||
$(MPICXX) $(CXXFLAGS) $< -o $@
|
|
16
README.md
16
README.md
@@ -1,6 +1,15 @@
|
|||||||
# mpi_test
|
# mpi_test
|
||||||
|
|
||||||
Various standalone MPI binaries, either tests or examples depending on your perspective.
|
Various standalone C++ MPI tests/examples/benchmarks.
|
||||||
|
|
||||||
|
If CUDA is detected, additional binaries can be built.
|
||||||
|
|
||||||
|
| name | Kind | Reqs. | Ranks | Description |
|
||||||
|
|---------------|-----------|----------|-------|-------------|
|
||||||
|
|`hello-world` | Test | MPI | 1+ | an MPI hello-world |
|
||||||
|
|`one-sided` | Test | MPI | 2 | one-sided communication |
|
||||||
|
|`one-sided-gpu`| Test | MPI+CUDA | 2 | one-sided communication on GPU buffer |
|
||||||
|
|`persistent` | Benchmark | MPI | 2 | ping-pong time for persistent Send/Recv |
|
||||||
|
|
||||||
## Build
|
## Build
|
||||||
```
|
```
|
||||||
@@ -24,11 +33,6 @@ If any tests fails, you can re-run them individually.
|
|||||||
|
|
||||||
Execute any binary you want using `mpirun`, or whatever is appropriate for your platform.
|
Execute any binary you want using `mpirun`, or whatever is appropriate for your platform.
|
||||||
|
|
||||||
## Run Microbenchmarks
|
|
||||||
|
|
||||||
- `persistent` (`persistent.cpp`) ping-pong time for persistent communication.
|
|
||||||
|
|
||||||
|
|
||||||
## Notes on specific platforms
|
## Notes on specific platforms
|
||||||
|
|
||||||
Some Open MPIs use `long long` for their datatypes, which means we can't support ANSI C++ (`-ansi`).
|
Some Open MPIs use `long long` for their datatypes, which means we can't support ANSI C++ (`-ansi`).
|
Reference in New Issue
Block a user