Makefile.am 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543
  1. #
  2. # StarPU
  3. # Copyright (C) INRIA 2008-2010 (see AUTHORS file)
  4. #
  5. # This program is free software; you can redistribute it and/or modify
  6. # it under the terms of the GNU Lesser General Public License as published by
  7. # the Free Software Foundation; either version 2.1 of the License, or (at
  8. # your option) any later version.
  9. #
  10. # This program is distributed in the hope that it will be useful, but
  11. # WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  13. #
  14. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  15. #
  16. LIBS = $(top_builddir)/src/libstarpu.la @LIBS@
  17. AM_CPPFLAGS = -I$(top_srcdir)/include/ -I$(top_srcdir)/examples/ -I$(top_builddir)/include
  18. TESTS = $(check_PROGRAMS)
  19. if STARPU_HAVE_FFTW
  20. if STARPU_HAVE_FFTWL
  21. SUBDIRS = starpufft
  22. endif
  23. endif
  24. check_PROGRAMS =
  25. BUILT_SOURCES =
  26. EXTRA_DIST = \
  27. basic_examples/vector_scal_opencl_codelet.cl \
  28. cuda/incrementer_cuda.cu \
  29. spmv/spmv_cuda.cu \
  30. gordon/null_kernel_gordon.c \
  31. mult/xgemm.c \
  32. mult/xgemm_kernels.c \
  33. mult/gordon/func_sgemm_ibm.c \
  34. lu/xlu.c \
  35. lu/xlu_pivot.c \
  36. lu/xlu_implicit.c \
  37. lu/xlu_implicit_pivot.c \
  38. lu/xlu_kernels.c \
  39. lu/lu_example.c \
  40. incrementer/incrementer_kernels_opencl_codelet.cl \
  41. variable/variable_kernels_opencl_codelet.cl \
  42. matvecmult/matvecmult_kernel.cl \
  43. block/block_kernel.cl
  44. CLEANFILES = \
  45. gordon/null_kernel_gordon.spuelf \
  46. mult/gordon/func_sgemm_ibm.spuelf
  47. CLEANFILES += *.gcno *.gcda *.linkinfo
  48. if STARPU_USE_CUDA
  49. .cu.cubin:
  50. $(MKDIR_P) `dirname $@`
  51. $(NVCC) -cubin $< -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS)
  52. .cu.o:
  53. $(NVCC) $< -c -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS) -I$(top_srcdir)/include/ -I$(top_builddir)/include/
  54. endif
  55. if STARPU_USE_GORDON
  56. SPU_CC ?= spu-gcc
  57. SPU_LD ?= spu-ld
  58. SPULDFLAGS =
  59. SPULIBS = -lblas #-lc -lgloss -lc
  60. .c.spuo:
  61. $(MKDIR_P) `dirname $@`
  62. $(SPU_CC) -c -fpic $< -o $@
  63. .spuo.spuelf:
  64. $(MKDIR_P) `dirname $@`
  65. $(SPU_LD) $(SPULDFLAGS) $< -o $@ $(SPULIBS)
  66. BUILT_SOURCES += \
  67. gordon/null_kernel_gordon.spuelf \
  68. mult/gordon/func_sgemm_ibm.spuelf
  69. endif
  70. examplebindir = $(libdir)/starpu/examples/
  71. examplebin_PROGRAMS =
  72. noinst_HEADERS = \
  73. heat/lu_kernels_model.h \
  74. heat/dw_sparse_cg.h \
  75. heat/heat.h \
  76. heat/dw_factolu.h \
  77. lu/xlu.h \
  78. lu/xlu_kernels.h \
  79. lu/float.h \
  80. lu/double.h \
  81. pi/pi.h \
  82. pi/SobolQRNG/sobol.h \
  83. pi/SobolQRNG/sobol_gold.h \
  84. pi/SobolQRNG/sobol_gpu.h \
  85. pi/SobolQRNG/sobol_primitives.h \
  86. cholesky/dw_cholesky_models.h \
  87. cholesky/dw_cholesky.h \
  88. common/blas_model.h \
  89. common/blas.h \
  90. mult/dw_mult.h \
  91. mult/gordon/func_sgemm_ibm.h \
  92. cuda/incrementer_cuda.h \
  93. gordon/null.h \
  94. fortran/bindings/StarPU_fortran.h \
  95. ppm_downscaler/ppm_downscaler.h \
  96. ppm_downscaler/yuv_downscaler.h \
  97. strassen/strassen.h \
  98. strassen/strassen_models.h \
  99. spmv/matrix_market/mmio.h \
  100. spmv/matrix_market/mm_to_bcsr.h \
  101. spmv/dw_spmv.h \
  102. spmv/dw_block_spmv.h
  103. ##################
  104. # Basic examples #
  105. ##################
  106. examplebin_PROGRAMS += \
  107. basic_examples/hello_world
  108. basic_examples_hello_world_SOURCES = \
  109. basic_examples/hello_world.c
  110. examplebin_PROGRAMS += \
  111. basic_examples/vector_scal
  112. basic_examples_vector_scal_SOURCES = \
  113. basic_examples/vector_scal.c
  114. if STARPU_USE_CUDA
  115. basic_examples_vector_scal_SOURCES += \
  116. basic_examples/vector_scal_cuda.cu
  117. endif
  118. if STARPU_USE_OPENCL
  119. basic_examples_vector_scal_SOURCES += \
  120. basic_examples/vector_scal_opencl.c
  121. endif
  122. nobase_STARPU_OPENCL_DATA_DATA = \
  123. basic_examples/vector_scal_opencl_codelet.cl
  124. examplebin_PROGRAMS += \
  125. basic_examples/mult
  126. basic_examples_mult_SOURCES = \
  127. basic_examples/mult.c
  128. ###################
  129. # PPM downscaling #
  130. ###################
  131. examplebin_PROGRAMS += \
  132. ppm_downscaler/ppm_downscaler
  133. ppm_downscaler_ppm_downscaler_SOURCES = \
  134. ppm_downscaler/ppm_downscaler.c
  135. examplebin_PROGRAMS += \
  136. ppm_downscaler/yuv_downscaler
  137. ppm_downscaler_yuv_downscaler_SOURCES = \
  138. ppm_downscaler/yuv_downscaler.c
  139. ######
  140. # Pi #
  141. ######
  142. examplebin_PROGRAMS += \
  143. pi/pi
  144. pi_pi_SOURCES = \
  145. pi/pi.c \
  146. pi/SobolQRNG/sobol_gold.c \
  147. pi/SobolQRNG/sobol_primitives.c
  148. if STARPU_USE_CUDA
  149. pi_pi_SOURCES += \
  150. pi/pi_kernel.cu \
  151. pi/SobolQRNG/sobol_gpu.cu
  152. endif
  153. ################
  154. # AXPY example #
  155. ################
  156. if !NO_BLAS_LIB
  157. examplebin_PROGRAMS += \
  158. axpy/axpy
  159. axpy_axpy_SOURCES = \
  160. axpy/axpy.c \
  161. common/blas.c
  162. endif
  163. ################
  164. # Mult example #
  165. ################
  166. if !NO_BLAS_LIB
  167. examplebin_PROGRAMS += \
  168. mult/sgemm \
  169. mult/dgemm \
  170. mult/dw_mult_no_stride \
  171. mult/dw_mult_no_stride_no_tag
  172. mult_sgemm_SOURCES = \
  173. mult/sgemm.c \
  174. common/blas.c \
  175. common/blas_model.c
  176. mult_dgemm_SOURCES = \
  177. mult/dgemm.c \
  178. common/blas.c \
  179. common/blas_model.c
  180. mult_dw_mult_no_stride_SOURCES = \
  181. mult/dw_mult_no_stride.c \
  182. mult/sgemm_kernels.c \
  183. common/blas.c \
  184. common/blas_model.c
  185. mult_dw_mult_no_stride_no_tag_SOURCES = \
  186. mult/dw_mult_no_stride_no_tag.c \
  187. mult/sgemm_kernels.c \
  188. common/blas.c \
  189. common/blas_model.c
  190. endif
  191. ####################
  192. # Cholesky example #
  193. ####################
  194. if !NO_BLAS_LIB
  195. examplebin_PROGRAMS += \
  196. cholesky/dw_cholesky \
  197. cholesky/dw_cholesky_no_stride \
  198. cholesky/dw_cholesky_grain
  199. cholesky_dw_cholesky_SOURCES = \
  200. cholesky/dw_cholesky.c \
  201. cholesky/dw_cholesky_models.c \
  202. cholesky/dw_cholesky_kernels.c \
  203. common/blas.c
  204. cholesky_dw_cholesky_no_stride_SOURCES = \
  205. cholesky/dw_cholesky_no_stride.c \
  206. cholesky/dw_cholesky_models.c \
  207. cholesky/dw_cholesky_kernels.c \
  208. common/blas.c
  209. cholesky_dw_cholesky_grain_SOURCES = \
  210. cholesky/dw_cholesky_grain.c \
  211. cholesky/dw_cholesky_models.c \
  212. cholesky/dw_cholesky_kernels.c \
  213. common/blas.c
  214. endif
  215. ##############
  216. # LU example #
  217. ##############
  218. if !NO_BLAS_LIB
  219. check_PROGRAMS += \
  220. lu/lu_example_float \
  221. lu/lu_implicit_example_float
  222. examplebin_PROGRAMS += \
  223. lu/lu_example_float \
  224. lu/lu_example_double
  225. lu_lu_example_float_SOURCES = \
  226. lu/lu_example_float.c \
  227. lu/slu.c \
  228. lu/slu_pivot.c \
  229. lu/slu_kernels.c \
  230. common/blas.c
  231. lu_lu_example_double_SOURCES = \
  232. lu/lu_example_double.c \
  233. lu/dlu.c \
  234. lu/dlu_pivot.c \
  235. lu/dlu_kernels.c \
  236. common/blas.c
  237. examplebin_PROGRAMS += \
  238. lu/lu_implicit_example_float \
  239. lu/lu_implicit_example_double
  240. lu_lu_implicit_example_float_SOURCES = \
  241. lu/lu_example_float.c \
  242. lu/slu_implicit.c \
  243. lu/slu_implicit_pivot.c \
  244. lu/slu_kernels.c \
  245. common/blas.c
  246. lu_lu_implicit_example_double_SOURCES = \
  247. lu/lu_example_double.c \
  248. lu/dlu_implicit.c \
  249. lu/dlu_implicit_pivot.c \
  250. lu/dlu_kernels.c \
  251. common/blas.c
  252. endif
  253. ################
  254. # Heat example #
  255. ################
  256. if !NO_BLAS_LIB
  257. examplebin_PROGRAMS += heat/heat
  258. heat_heat_SOURCES = \
  259. heat/heat.c \
  260. heat/dw_factolu.c \
  261. heat/dw_factolu_tag.c \
  262. heat/dw_factolu_grain.c \
  263. heat/dw_sparse_cg.c \
  264. heat/heat_display.c \
  265. heat/lu_kernels_model.c \
  266. heat/dw_sparse_cg_kernels.c \
  267. heat/dw_factolu_kernels.c \
  268. common/blas.c
  269. endif
  270. ################
  271. # Tag examples #
  272. ################
  273. check_PROGRAMS += \
  274. tag_example/tag_example \
  275. tag_example/tag_example3 \
  276. tag_example/tag_example2 \
  277. tag_example/tag_restartable
  278. examplebin_PROGRAMS += \
  279. tag_example/tag_example \
  280. tag_example/tag_example3 \
  281. tag_example/tag_example2 \
  282. tag_example/tag_restartable
  283. tag_example_tag_example_SOURCES = \
  284. tag_example/tag_example.c
  285. tag_example_tag_example2_SOURCES = \
  286. tag_example/tag_example2.c
  287. tag_example_tag_example3_SOURCES = \
  288. tag_example/tag_example3.c
  289. tag_example_tag_restartable_SOURCES = \
  290. tag_example/tag_restartable.c
  291. ####################
  292. # Strassen example #
  293. ####################
  294. if ATLAS_BLAS_LIB
  295. examplebin_PROGRAMS += strassen/dw_strassen
  296. strassen_dw_strassen_SOURCES = \
  297. strassen/strassen.c \
  298. strassen/strassen_kernels.c \
  299. strassen/test_strassen.c \
  300. strassen/strassen_models.c \
  301. common/blas.c
  302. endif
  303. #####################
  304. # Strassen2 example #
  305. #####################
  306. if !NO_BLAS_LIB
  307. check_PROGRAMS += strassen2/strassen
  308. examplebin_PROGRAMS += strassen2/strassen
  309. strassen2_strassen_SOURCES = \
  310. strassen2/strassen2.c \
  311. strassen2/strassen2_kernels.c \
  312. common/blas.c
  313. endif
  314. ################
  315. # SpMV example #
  316. ################
  317. examplebin_PROGRAMS += \
  318. spmv/dw_spmv
  319. spmv_dw_spmv_SOURCES = \
  320. spmv/dw_spmv.c
  321. if STARPU_USE_CUDA
  322. spmv_dw_spmv_SOURCES += \
  323. spmv/spmv_cuda.cu
  324. endif
  325. if ATLAS_BLAS_LIB
  326. examplebin_PROGRAMS += \
  327. spmv/dw_block_spmv
  328. spmv_dw_block_spmv_SOURCES = \
  329. spmv/dw_block_spmv.c \
  330. spmv/dw_block_spmv_kernels.c \
  331. spmv/matrix_market/mm_to_bcsr.c \
  332. spmv/matrix_market/mmio.c
  333. endif
  334. #######################
  335. # Incrementer example #
  336. #######################
  337. check_PROGRAMS += \
  338. incrementer/incrementer
  339. examplebin_PROGRAMS += \
  340. incrementer/incrementer
  341. incrementer_incrementer_SOURCES = \
  342. incrementer/incrementer.c
  343. if STARPU_USE_CUDA
  344. incrementer_incrementer_SOURCES += \
  345. incrementer/incrementer_kernels.cu
  346. endif
  347. if STARPU_USE_OPENCL
  348. incrementer_incrementer_SOURCES += \
  349. incrementer/incrementer_kernels_opencl.c
  350. endif
  351. nobase_STARPU_OPENCL_DATA_DATA += \
  352. incrementer/incrementer_kernels_opencl_codelet.cl
  353. ####################
  354. # Variable example #
  355. ####################
  356. check_PROGRAMS += \
  357. variable/variable
  358. examplebin_PROGRAMS += \
  359. variable/variable
  360. variable_variable_SOURCES = \
  361. variable/variable.c
  362. if STARPU_USE_CUDA
  363. variable_variable_SOURCES += \
  364. variable/variable_kernels.cu
  365. endif
  366. if STARPU_USE_OPENCL
  367. variable_variable_SOURCES += \
  368. variable/variable_kernels_opencl.c
  369. endif
  370. nobase_STARPU_OPENCL_DATA_DATA += \
  371. variable/variable_kernels_opencl_codelet.cl
  372. ######################
  373. # matVecMult example #
  374. ######################
  375. check_PROGRAMS += \
  376. matvecmult/matvecmult
  377. examplebin_PROGRAMS += \
  378. matvecmult/matvecmult
  379. matvecmult_matvecmult_SOURCES = \
  380. matvecmult/matvecmult.c
  381. if STARPU_USE_OPENCL
  382. nobase_STARPU_OPENCL_DATA_DATA += \
  383. matvecmult/matvecmult_kernel.cl
  384. endif
  385. #################
  386. # block example #
  387. #################
  388. check_PROGRAMS += \
  389. block/block
  390. examplebin_PROGRAMS += \
  391. block/block
  392. block_block_SOURCES = \
  393. block/block.c
  394. if STARPU_USE_CUDA
  395. block_block_SOURCES += \
  396. block/block_cuda.cu
  397. endif
  398. if STARPU_USE_OPENCL
  399. nobase_STARPU_OPENCL_DATA_DATA += \
  400. block/block_kernel.cl
  401. endif
  402. #####################
  403. # profiling example #
  404. #####################
  405. check_PROGRAMS += \
  406. profiling/profiling
  407. examplebin_PROGRAMS += \
  408. profiling/profiling
  409. profiling_profiling_SOURCES = \
  410. profiling/profiling.c