Makefile.am 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557
  1. #
  2. # StarPU
  3. # Copyright (C) Université Bordeaux 1, CNRS 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 = coverage/coverage.sh \
  19. $(check_PROGRAMS)
  20. if STARPU_HAVE_FFTW
  21. if STARPU_HAVE_FFTWL
  22. SUBDIRS = starpufft
  23. endif
  24. endif
  25. check_PROGRAMS =
  26. BUILT_SOURCES =
  27. EXTRA_DIST = \
  28. basic_examples/vector_scal_opencl_codelet.cl \
  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. basic_examples/variable_kernels_opencl_codelet.cl \
  42. matvecmult/matvecmult_kernel.cl \
  43. basic_examples/block_opencl_kernel.cl \
  44. filters/fblock_opencl_codelet.cl \
  45. coverage/coverage.sh
  46. CLEANFILES = \
  47. gordon/null_kernel_gordon.spuelf \
  48. mult/gordon/func_sgemm_ibm.spuelf
  49. CLEANFILES += *.gcno *.gcda *.linkinfo
  50. if STARPU_USE_CUDA
  51. .cu.cubin:
  52. $(MKDIR_P) `dirname $@`
  53. $(NVCC) -cubin $< -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS)
  54. .cu.o:
  55. $(NVCC) $< -c -o $@ --compiler-options -fno-strict-aliasing $(NVCCFLAGS) -I$(top_srcdir)/include/ -I$(top_builddir)/include/
  56. endif
  57. if STARPU_USE_GORDON
  58. SPU_CC ?= spu-gcc
  59. SPU_LD ?= spu-ld
  60. SPULDFLAGS =
  61. SPULIBS = -lblas #-lc -lgloss -lc
  62. .c.spuo:
  63. $(MKDIR_P) `dirname $@`
  64. $(SPU_CC) -c -fpic $< -o $@
  65. .spuo.spuelf:
  66. $(MKDIR_P) `dirname $@`
  67. $(SPU_LD) $(SPULDFLAGS) $< -o $@ $(SPULIBS)
  68. BUILT_SOURCES += \
  69. gordon/null_kernel_gordon.spuelf \
  70. mult/gordon/func_sgemm_ibm.spuelf
  71. endif
  72. examplebindir = $(libdir)/starpu/examples/
  73. examplebin_PROGRAMS =
  74. noinst_HEADERS = \
  75. heat/lu_kernels_model.h \
  76. heat/dw_sparse_cg.h \
  77. heat/heat.h \
  78. heat/dw_factolu.h \
  79. lu/xlu.h \
  80. lu/xlu_kernels.h \
  81. lu/float.h \
  82. lu/double.h \
  83. pi/pi.h \
  84. pi/SobolQRNG/sobol.h \
  85. pi/SobolQRNG/sobol_gold.h \
  86. pi/SobolQRNG/sobol_gpu.h \
  87. pi/SobolQRNG/sobol_primitives.h \
  88. cholesky/dw_cholesky_models.h \
  89. cholesky/dw_cholesky.h \
  90. common/blas_model.h \
  91. common/blas.h \
  92. mult/dw_mult.h \
  93. mult/gordon/func_sgemm_ibm.h \
  94. gordon/null.h \
  95. fortran/bindings/StarPU_fortran.h \
  96. ppm_downscaler/ppm_downscaler.h \
  97. ppm_downscaler/yuv_downscaler.h \
  98. spmv/matrix_market/mmio.h \
  99. spmv/matrix_market/mm_to_bcsr.h \
  100. spmv/dw_spmv.h \
  101. spmv/dw_block_spmv.h
  102. ##################
  103. # Basic examples #
  104. ##################
  105. examplebin_PROGRAMS += \
  106. basic_examples/hello_world
  107. basic_examples_hello_world_SOURCES = \
  108. basic_examples/hello_world.c
  109. examplebin_PROGRAMS += \
  110. basic_examples/vector_scal
  111. basic_examples_vector_scal_SOURCES = \
  112. basic_examples/vector_scal.c \
  113. basic_examples/vector_scal_cpu.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. # block example #
  130. #################
  131. check_PROGRAMS += \
  132. basic_examples/block
  133. examplebin_PROGRAMS += \
  134. basic_examples/block
  135. basic_examples_block_SOURCES = \
  136. basic_examples/block.c \
  137. basic_examples/block_cpu.c
  138. if STARPU_USE_CUDA
  139. basic_examples_block_SOURCES += \
  140. basic_examples/block_cuda.cu
  141. endif
  142. if STARPU_USE_OPENCL
  143. basic_examples_block_SOURCES += \
  144. basic_examples/block_opencl.c
  145. nobase_STARPU_OPENCL_DATA_DATA += \
  146. basic_examples/block_opencl_kernel.cl
  147. endif
  148. ####################
  149. # Variable example #
  150. ####################
  151. check_PROGRAMS += \
  152. basic_examples/variable
  153. examplebin_PROGRAMS += \
  154. basic_examples/variable
  155. basic_examples_variable_SOURCES = \
  156. basic_examples/variable.c \
  157. basic_examples/variable_kernels_cpu.c
  158. if STARPU_USE_CUDA
  159. basic_examples_variable_SOURCES += \
  160. basic_examples/variable_kernels.cu
  161. endif
  162. if STARPU_USE_OPENCL
  163. basic_examples_variable_SOURCES += \
  164. basic_examples/variable_kernels_opencl.c
  165. endif
  166. nobase_STARPU_OPENCL_DATA_DATA += \
  167. basic_examples/variable_kernels_opencl_codelet.cl
  168. ###########
  169. # Filters #
  170. ###########
  171. examplebin_PROGRAMS += \
  172. filters/fvector \
  173. filters/fblock \
  174. filters/fmatrix
  175. filters_fvector_SOURCES = \
  176. filters/fvector.c
  177. filters_fblock_SOURCES = \
  178. filters/fblock.c \
  179. filters/fblock_cpu.c
  180. if STARPU_USE_CUDA
  181. filters_fblock_SOURCES += \
  182. filters/fblock_cuda.cu
  183. endif
  184. if STARPU_USE_OPENCL
  185. filters_fblock_SOURCES += \
  186. filters/fblock_opencl.c
  187. endif
  188. nobase_STARPU_OPENCL_DATA_DATA += \
  189. filters/fblock_opencl_codelet.cl
  190. filters_fmatrix_SOURCES = \
  191. filters/fmatrix.c
  192. ###################
  193. # PPM downscaling #
  194. ###################
  195. examplebin_PROGRAMS += \
  196. ppm_downscaler/ppm_downscaler
  197. ppm_downscaler_ppm_downscaler_SOURCES = \
  198. ppm_downscaler/ppm_downscaler.c
  199. examplebin_PROGRAMS += \
  200. ppm_downscaler/yuv_downscaler
  201. ppm_downscaler_yuv_downscaler_SOURCES = \
  202. ppm_downscaler/yuv_downscaler.c
  203. ######
  204. # Pi #
  205. ######
  206. examplebin_PROGRAMS += \
  207. pi/pi
  208. pi_pi_SOURCES = \
  209. pi/pi.c \
  210. pi/SobolQRNG/sobol_gold.c \
  211. pi/SobolQRNG/sobol_primitives.c
  212. if STARPU_USE_CUDA
  213. pi_pi_SOURCES += \
  214. pi/pi_kernel.cu \
  215. pi/SobolQRNG/sobol_gpu.cu
  216. endif
  217. ################
  218. # AXPY example #
  219. ################
  220. if !NO_BLAS_LIB
  221. examplebin_PROGRAMS += \
  222. axpy/axpy
  223. axpy_axpy_SOURCES = \
  224. axpy/axpy.c \
  225. common/blas.c
  226. endif
  227. ################
  228. # Mult example #
  229. ################
  230. if !NO_BLAS_LIB
  231. examplebin_PROGRAMS += \
  232. mult/sgemm \
  233. mult/dgemm \
  234. mult/dw_mult_no_stride \
  235. mult/dw_mult_no_stride_no_tag
  236. mult_sgemm_SOURCES = \
  237. mult/sgemm.c \
  238. common/blas.c \
  239. common/blas_model.c
  240. mult_dgemm_SOURCES = \
  241. mult/dgemm.c \
  242. common/blas.c \
  243. common/blas_model.c
  244. mult_dw_mult_no_stride_SOURCES = \
  245. mult/dw_mult_no_stride.c \
  246. mult/sgemm_kernels.c \
  247. common/blas.c \
  248. common/blas_model.c
  249. mult_dw_mult_no_stride_no_tag_SOURCES = \
  250. mult/dw_mult_no_stride_no_tag.c \
  251. mult/sgemm_kernels.c \
  252. common/blas.c \
  253. common/blas_model.c
  254. endif
  255. ####################
  256. # Cholesky example #
  257. ####################
  258. if !NO_BLAS_LIB
  259. examplebin_PROGRAMS += \
  260. cholesky/dw_cholesky \
  261. cholesky/dw_cholesky_no_stride \
  262. cholesky/dw_cholesky_grain
  263. cholesky_dw_cholesky_SOURCES = \
  264. cholesky/dw_cholesky.c \
  265. cholesky/dw_cholesky_models.c \
  266. cholesky/dw_cholesky_kernels.c \
  267. common/blas.c
  268. cholesky_dw_cholesky_no_stride_SOURCES = \
  269. cholesky/dw_cholesky_no_stride.c \
  270. cholesky/dw_cholesky_models.c \
  271. cholesky/dw_cholesky_kernels.c \
  272. common/blas.c
  273. cholesky_dw_cholesky_grain_SOURCES = \
  274. cholesky/dw_cholesky_grain.c \
  275. cholesky/dw_cholesky_models.c \
  276. cholesky/dw_cholesky_kernels.c \
  277. common/blas.c
  278. endif
  279. ##############
  280. # LU example #
  281. ##############
  282. if !NO_BLAS_LIB
  283. check_PROGRAMS += \
  284. lu/lu_example_float \
  285. lu/lu_implicit_example_float
  286. examplebin_PROGRAMS += \
  287. lu/lu_example_float \
  288. lu/lu_example_double
  289. lu_lu_example_float_SOURCES = \
  290. lu/lu_example_float.c \
  291. lu/slu.c \
  292. lu/slu_pivot.c \
  293. lu/slu_kernels.c \
  294. common/blas.c
  295. lu_lu_example_double_SOURCES = \
  296. lu/lu_example_double.c \
  297. lu/dlu.c \
  298. lu/dlu_pivot.c \
  299. lu/dlu_kernels.c \
  300. common/blas.c
  301. examplebin_PROGRAMS += \
  302. lu/lu_implicit_example_float \
  303. lu/lu_implicit_example_double
  304. lu_lu_implicit_example_float_SOURCES = \
  305. lu/lu_example_float.c \
  306. lu/slu_implicit.c \
  307. lu/slu_implicit_pivot.c \
  308. lu/slu_kernels.c \
  309. common/blas.c
  310. lu_lu_implicit_example_double_SOURCES = \
  311. lu/lu_example_double.c \
  312. lu/dlu_implicit.c \
  313. lu/dlu_implicit_pivot.c \
  314. lu/dlu_kernels.c \
  315. common/blas.c
  316. endif
  317. ################
  318. # Heat example #
  319. ################
  320. if !NO_BLAS_LIB
  321. examplebin_PROGRAMS += heat/heat
  322. heat_heat_SOURCES = \
  323. heat/heat.c \
  324. heat/dw_factolu.c \
  325. heat/dw_factolu_tag.c \
  326. heat/dw_factolu_grain.c \
  327. heat/dw_sparse_cg.c \
  328. heat/heat_display.c \
  329. heat/lu_kernels_model.c \
  330. heat/dw_sparse_cg_kernels.c \
  331. heat/dw_factolu_kernels.c \
  332. common/blas.c
  333. endif
  334. ################
  335. # Tag examples #
  336. ################
  337. check_PROGRAMS += \
  338. tag_example/tag_example \
  339. tag_example/tag_example3 \
  340. tag_example/tag_example2 \
  341. tag_example/tag_restartable
  342. examplebin_PROGRAMS += \
  343. tag_example/tag_example \
  344. tag_example/tag_example3 \
  345. tag_example/tag_example2 \
  346. tag_example/tag_restartable
  347. tag_example_tag_example_SOURCES = \
  348. tag_example/tag_example.c
  349. tag_example_tag_example2_SOURCES = \
  350. tag_example/tag_example2.c
  351. tag_example_tag_example3_SOURCES = \
  352. tag_example/tag_example3.c
  353. tag_example_tag_restartable_SOURCES = \
  354. tag_example/tag_restartable.c
  355. ################
  356. # SpMV example #
  357. ################
  358. examplebin_PROGRAMS += \
  359. spmv/dw_spmv
  360. spmv_dw_spmv_SOURCES = \
  361. spmv/dw_spmv.c
  362. if STARPU_USE_CUDA
  363. spmv_dw_spmv_SOURCES += \
  364. spmv/spmv_cuda.cu
  365. endif
  366. if ATLAS_BLAS_LIB
  367. examplebin_PROGRAMS += \
  368. spmv/dw_block_spmv
  369. spmv_dw_block_spmv_SOURCES = \
  370. spmv/dw_block_spmv.c \
  371. spmv/dw_block_spmv_kernels.c \
  372. spmv/matrix_market/mm_to_bcsr.c \
  373. spmv/matrix_market/mmio.c
  374. endif
  375. #######################
  376. # Incrementer example #
  377. #######################
  378. check_PROGRAMS += \
  379. incrementer/incrementer
  380. examplebin_PROGRAMS += \
  381. incrementer/incrementer
  382. incrementer_incrementer_SOURCES = \
  383. incrementer/incrementer.c
  384. if STARPU_USE_CUDA
  385. incrementer_incrementer_SOURCES += \
  386. incrementer/incrementer_kernels.cu
  387. endif
  388. if STARPU_USE_OPENCL
  389. incrementer_incrementer_SOURCES += \
  390. incrementer/incrementer_kernels_opencl.c
  391. endif
  392. nobase_STARPU_OPENCL_DATA_DATA += \
  393. incrementer/incrementer_kernels_opencl_codelet.cl
  394. ######################
  395. # matVecMult example #
  396. ######################
  397. check_PROGRAMS += \
  398. matvecmult/matvecmult
  399. examplebin_PROGRAMS += \
  400. matvecmult/matvecmult
  401. matvecmult_matvecmult_SOURCES = \
  402. matvecmult/matvecmult.c
  403. if STARPU_USE_OPENCL
  404. nobase_STARPU_OPENCL_DATA_DATA += \
  405. matvecmult/matvecmult_kernel.cl
  406. endif
  407. #####################
  408. # profiling example #
  409. #####################
  410. check_PROGRAMS += \
  411. profiling/profiling
  412. examplebin_PROGRAMS += \
  413. profiling/profiling
  414. profiling_profiling_SOURCES = \
  415. profiling/profiling.c
  416. #####################
  417. # scheduler example #
  418. #####################
  419. check_PROGRAMS += \
  420. scheduler/dummy_sched
  421. examplebin_PROGRAMS += \
  422. scheduler/dummy_sched
  423. scheduler_dummy_sched_SOURCES = \
  424. scheduler/dummy_sched.c