Makefile.am 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294
  1. # StarPU --- Runtime system for heterogeneous multicore architectures.
  2. #
  3. # Copyright (C) 2009-2012 Université de Bordeaux 1
  4. # Copyright (C) 2010, 2011, 2012 Centre National de la Recherche Scientifique
  5. #
  6. # StarPU is free software; you can redistribute it and/or modify
  7. # it under the terms of the GNU Lesser General Public License as published by
  8. # the Free Software Foundation; either version 2.1 of the License, or (at
  9. # your option) any later version.
  10. #
  11. # StarPU is distributed in the hope that it will be useful, but
  12. # WITHOUT ANY WARRANTY; without even the implied warranty of
  13. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  14. #
  15. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  16. CC=$(MPICC)
  17. CCLD=$(MPICC)
  18. if STARPU_MPI_CHECK
  19. TESTS_ENVIRONMENT = $(MPIEXEC) -np 2 -H localhost
  20. TESTS = $(check_PROGRAMS)
  21. endif
  22. check_PROGRAMS =
  23. BUILT_SOURCES =
  24. CLEANFILES = *.gcno *.gcda *.linkinfo
  25. EXTRA_DIST = \
  26. examples/mpi_lu/float.h \
  27. examples/mpi_lu/double.h \
  28. examples/mpi_lu/plu_example.c \
  29. examples/mpi_lu/plu_solve.c \
  30. examples/mpi_lu/pxlu.h \
  31. examples/mpi_lu/pxlu.c \
  32. examples/mpi_lu/pxlu_kernels.h \
  33. examples/mpi_lu/pxlu_kernels.c \
  34. examples/cholesky/mpi_cholesky.h \
  35. examples/cholesky/mpi_cholesky_models.h \
  36. tests/helper.h
  37. examplebindir = $(libdir)/starpu/examples/mpi
  38. examplebin_PROGRAMS =
  39. if STARPU_USE_CUDA
  40. # TODO define NVCCFLAGS
  41. NVCC ?= nvcc
  42. NVCCFLAGS += -I$(top_srcdir)/include/ -I$(top_builddir)/include
  43. .cu.cubin:
  44. $(MKDIR_P) `dirname $@`
  45. $(NVCC) -cubin $< -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS)
  46. .cu.o:
  47. $(NVCC) $< -c -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS) -I$(top_srcdir)/include/ -I$(top_builddir)/include/
  48. endif
  49. AM_CFLAGS = -Wall $(STARPU_CUDA_CPPFLAGS) $(STARPU_OPENCL_CPPFLAGS) $(FXT_CFLAGS) $(MAGMA_CFLAGS)
  50. LIBS = $(top_builddir)/src/libstarpu-@STARPU_EFFECTIVE_VERSION@.la @LIBS@ $(FXT_LIBS) $(MAGMA_LIBS)
  51. AM_CPPFLAGS = -I$(top_srcdir)/include/ -I$(top_srcdir)/mpi/ -I$(top_srcdir)/src/ -I$(top_srcdir)/examples/ -I$(top_builddir)/src -I$(top_builddir)/include
  52. AM_LDFLAGS = $(STARPU_CUDA_LDFLAGS) $(STARPU_OPENCL_LDFLAGS)
  53. lib_LTLIBRARIES = libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  54. libstarpumpi_@STARPU_EFFECTIVE_VERSION@_la_LIBADD = $(top_builddir)/src/libstarpu-@STARPU_EFFECTIVE_VERSION@.la
  55. libstarpumpi_@STARPU_EFFECTIVE_VERSION@_la_LDFLAGS = $(ldflags) -no-undefined \
  56. -version-info $(LIBSTARPUMPI_INTERFACE_CURRENT):$(LIBSTARPUMPI_INTERFACE_REVISION):$(LIBSTARPUMPI_INTERFACE_AGE)
  57. noinst_HEADERS = \
  58. starpu_mpi_private.h \
  59. starpu_mpi_fxt.h
  60. versincludedir = $(includedir)/starpu/$(STARPU_EFFECTIVE_VERSION)
  61. versinclude_HEADERS = \
  62. starpu_mpi.h \
  63. starpu_mpi_datatype.h
  64. libstarpumpi_@STARPU_EFFECTIVE_VERSION@_la_SOURCES = \
  65. starpu_mpi.c \
  66. starpu_mpi_helper.c \
  67. starpu_mpi_datatype.c \
  68. starpu_mpi_insert_task.c \
  69. starpu_mpi_collective.c
  70. ###################
  71. # Stencil example #
  72. ###################
  73. examplebin_PROGRAMS += \
  74. examples/stencil/stencil5
  75. examples_stencil_stencil5_LDADD = \
  76. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  77. check_PROGRAMS += \
  78. examples/stencil/stencil5
  79. ##################
  80. # MPI LU example #
  81. ##################
  82. if !NO_BLAS_LIB
  83. examplebin_PROGRAMS += \
  84. examples/mpi_lu/plu_example_float \
  85. examples/mpi_lu/plu_example_double
  86. examples_mpi_lu_plu_example_float_LDADD = \
  87. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la \
  88. $(STARPU_LIBNUMA_LDFLAGS) \
  89. $(STARPU_BLAS_LDFLAGS)
  90. examples_mpi_lu_plu_example_float_SOURCES = \
  91. examples/mpi_lu/plu_example_float.c \
  92. examples/mpi_lu/plu_solve_float.c \
  93. examples/mpi_lu/pslu_kernels.c \
  94. examples/mpi_lu/pslu.c \
  95. $(top_srcdir)/examples/common/blas.c
  96. examples_mpi_lu_plu_example_double_LDADD = \
  97. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la \
  98. $(STARPU_LIBNUMA_LDFLAGS) \
  99. $(STARPU_BLAS_LDFLAGS)
  100. examples_mpi_lu_plu_example_double_SOURCES = \
  101. examples/mpi_lu/plu_example_double.c \
  102. examples/mpi_lu/plu_solve_double.c \
  103. examples/mpi_lu/pdlu_kernels.c \
  104. examples/mpi_lu/pdlu.c \
  105. $(top_srcdir)/examples/common/blas.c
  106. endif
  107. ########################
  108. # MPI Cholesky example #
  109. ########################
  110. if !NO_BLAS_LIB
  111. examplebin_PROGRAMS += \
  112. examples/cholesky/mpi_cholesky \
  113. examples/cholesky/mpi_cholesky_distributed
  114. examples_cholesky_mpi_cholesky_SOURCES = \
  115. examples/cholesky/mpi_cholesky.c \
  116. examples/cholesky/mpi_cholesky_models.c \
  117. examples/cholesky/mpi_cholesky_kernels.c \
  118. $(top_srcdir)/examples/common/blas.c
  119. examples_cholesky_mpi_cholesky_LDADD = \
  120. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la \
  121. $(STARPU_BLAS_LDFLAGS)
  122. examples_cholesky_mpi_cholesky_distributed_SOURCES = \
  123. examples/cholesky/mpi_cholesky_distributed.c \
  124. examples/cholesky/mpi_cholesky_models.c \
  125. examples/cholesky/mpi_cholesky_kernels.c \
  126. $(top_srcdir)/examples/common/blas.c
  127. examples_cholesky_mpi_cholesky_distributed_LDADD = \
  128. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la \
  129. $(STARPU_BLAS_LDFLAGS)
  130. check_PROGRAMS += \
  131. examples/cholesky/mpi_cholesky \
  132. examples/cholesky/mpi_cholesky_distributed
  133. endif
  134. ########################
  135. # Scatter Gather #
  136. ########################
  137. examplebin_PROGRAMS += \
  138. examples/scatter_gather/mpi_scatter_gather
  139. examples_scatter_gather_mpi_scatter_gather_LDADD = \
  140. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  141. check_PROGRAMS += \
  142. examples/scatter_gather/mpi_scatter_gather
  143. ###################
  144. # Reduction #
  145. ###################
  146. examplebin_PROGRAMS += \
  147. examples/reduction/mpi_reduction
  148. examples_reduction_mpi_reduction_SOURCES = \
  149. examples/reduction/mpi_reduction.c \
  150. examples/reduction/mpi_reduction_kernels.c
  151. examples_reduction_mpi_reduction_LDADD = \
  152. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  153. check_PROGRAMS += \
  154. examples/reduction/mpi_reduction
  155. ########################
  156. # Unit testcases #
  157. ########################
  158. check_PROGRAMS += \
  159. tests/pingpong \
  160. tests/mpi_test \
  161. tests/mpi_isend \
  162. tests/mpi_irecv \
  163. tests/mpi_isend_detached \
  164. tests/mpi_irecv_detached \
  165. tests/mpi_detached_tag \
  166. tests/ring \
  167. tests/ring_async \
  168. tests/ring_async_implicit \
  169. tests/block_interface \
  170. tests/block_interface_pinned \
  171. tests/insert_task \
  172. tests/insert_task_cache \
  173. tests/insert_task_block \
  174. tests/insert_task_owner \
  175. tests/insert_task_owner2 \
  176. tests/insert_task_owner_data \
  177. tests/multiple_send
  178. noinst_PROGRAMS = \
  179. tests/pingpong \
  180. tests/mpi_test \
  181. tests/mpi_isend \
  182. tests/mpi_irecv \
  183. tests/mpi_isend_detached \
  184. tests/mpi_irecv_detached \
  185. tests/mpi_detached_tag \
  186. tests/ring \
  187. tests/ring_async \
  188. tests/ring_async_implicit \
  189. tests/block_interface \
  190. tests/block_interface_pinned \
  191. tests/insert_task \
  192. tests/insert_task_cache \
  193. tests/insert_task_block \
  194. tests/insert_task_owner \
  195. tests/insert_task_owner2 \
  196. tests/insert_task_owner_data \
  197. tests/multiple_send
  198. tests_mpi_isend_LDADD = \
  199. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  200. tests_mpi_irecv_LDADD = \
  201. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  202. tests_mpi_isend_detached_LDADD = \
  203. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  204. tests_mpi_irecv_detached_LDADD = \
  205. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  206. tests_mpi_detached_tag_LDADD = \
  207. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  208. tests_pingpong_LDADD = \
  209. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  210. tests_mpi_test_LDADD = \
  211. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  212. tests_ring_LDADD = \
  213. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  214. tests_ring_async_LDADD = \
  215. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  216. tests_ring_async_implicit_LDADD = \
  217. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  218. tests_block_interface_LDADD = \
  219. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  220. tests_block_interface_pinned_LDADD = \
  221. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  222. tests_insert_task_LDADD = \
  223. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  224. tests_insert_task_cache_LDADD = \
  225. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  226. tests_insert_task_block_LDADD = \
  227. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  228. tests_insert_task_owner_LDADD = \
  229. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  230. tests_insert_task_owner2_LDADD = \
  231. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  232. tests_insert_task_owner_data_LDADD = \
  233. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  234. tests_multiple_send_LDADD = \
  235. libstarpumpi-@STARPU_EFFECTIVE_VERSION@.la
  236. tests_ring_SOURCES = tests/ring.c
  237. tests_ring_async_SOURCES = tests/ring_async.c
  238. tests_ring_async_implicit_SOURCES = tests/ring_async_implicit.c
  239. if STARPU_USE_CUDA
  240. tests_ring_SOURCES += tests/ring_kernel.cu
  241. tests_ring_async_SOURCES += tests/ring_kernel.cu
  242. tests_ring_async_implicit_SOURCES += tests/ring_kernel.cu
  243. endif