Makefile.am 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831
  1. # StarPU --- Runtime system for heterogeneous multicore architectures.
  2. #
  3. # Copyright (C) 2009, 2010-2012 Université de Bordeaux 1
  4. # Copyright (C) 2010, 2011, 2012 Centre National de la Recherche Scientifique
  5. # Copyright (C) 2011 Télécom-SudParis
  6. # Copyright (C) 2012 INRIA
  7. #
  8. # StarPU is free software; you can redistribute it and/or modify
  9. # it under the terms of the GNU Lesser General Public License as published by
  10. # the Free Software Foundation; either version 2.1 of the License, or (at
  11. # your option) any later version.
  12. #
  13. # StarPU is distributed in the hope that it will be useful, but
  14. # WITHOUT ANY WARRANTY; without even the implied warranty of
  15. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  16. #
  17. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  18. AM_CFLAGS = $(MAGMA_CFLAGS) $(HWLOC_CFLAGS) -Wall $(STARPU_CUDA_CPPFLAGS) $(STARPU_OPENCL_CPPFLAGS)
  19. AM_CXXFLAGS = $(MAGMA_CFLAGS) $(HWLOC_CFLAGS) -Wall $(STARPU_CUDA_CPPFLAGS) $(STARPU_OPENCL_CPPFLAGS)
  20. LIBS = $(top_builddir)/src/libstarpu-@STARPU_EFFECTIVE_VERSION@.la $(MAGMA_LIBS) $(HWLOC_LIBS) @LIBS@
  21. AM_CPPFLAGS = -I$(top_srcdir)/include/ -I$(top_srcdir)/examples/ -I$(top_builddir)/include
  22. AM_LDFLAGS = $(STARPU_CUDA_LDFLAGS) $(STARPU_OPENCL_LDFLAGS)
  23. SUBDIRS = stencil
  24. BUILT_SOURCES =
  25. if STARPU_USE_OPENCL
  26. nobase_STARPU_OPENCL_DATA_DATA =
  27. endif
  28. EXTRA_DIST = \
  29. axpy/axpy_opencl_kernel.cl \
  30. basic_examples/vector_scal_opencl_kernel.cl \
  31. basic_examples/multiformat_opencl_kernel.cl \
  32. basic_examples/multiformat_conversion_codelets_opencl_kernel.cl \
  33. common/blas_model.c \
  34. spmd/vector_scal_spmd.c \
  35. spmv/spmv_cuda.cu \
  36. spmv/spmv_opencl.cl \
  37. gordon/null_kernel_gordon.c \
  38. mult/xgemm.c \
  39. lu/xlu.c \
  40. lu/xlu_pivot.c \
  41. lu/xlu_implicit.c \
  42. lu/xlu_implicit_pivot.c \
  43. lu/xlu_kernels.c \
  44. lu/lu_example.c \
  45. incrementer/incrementer_kernels_opencl_kernel.cl \
  46. basic_examples/variable_kernels_opencl_kernel.cl \
  47. matvecmult/matvecmult_kernel.cl \
  48. basic_examples/block_opencl_kernel.cl \
  49. openmp/vector_scal.c \
  50. filters/fblock_opencl_kernel.cl \
  51. filters/custom_mf/conversion_opencl.cl \
  52. filters/custom_mf/custom_opencl.cl \
  53. interface/complex_kernels.cl \
  54. reductions/dot_product_opencl_kernels.cl
  55. CLEANFILES = \
  56. gordon/null_kernel_gordon.spuelf
  57. CLEANFILES += *.gcno *.gcda *.linkinfo
  58. if STARPU_USE_CUDA
  59. NVCCFLAGS += --compiler-options -fno-strict-aliasing -I$(top_srcdir)/include/ -I$(top_builddir)/include/ -I$(top_srcdir)/examples/ $(HWLOC_CFLAGS) -arch sm_13
  60. .cu.o:
  61. $(NVCC) $< -c -o $@ $(NVCCFLAGS)
  62. endif
  63. if STARPU_USE_GORDON
  64. SPU_CC ?= spu-gcc
  65. SPU_LD ?= spu-ld
  66. SPULDFLAGS =
  67. SPULIBS = -lblas #-lc -lgloss -lc
  68. .c.spuo:
  69. $(MKDIR_P) `dirname $@`
  70. $(SPU_CC) -c -fpic $< -o $@
  71. .spuo.spuelf:
  72. $(MKDIR_P) `dirname $@`
  73. $(SPU_LD) $(SPULDFLAGS) $< -o $@ $(SPULIBS)
  74. BUILT_SOURCES += \
  75. gordon/null_kernel_gordon.spuelf
  76. endif
  77. if STARPU_HAVE_ICC
  78. .icc.o:
  79. $(ICC) -x c $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
  80. $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) $< -c -o $@
  81. endif
  82. examplebindir = $(libdir)/starpu/examples/
  83. examplebin_PROGRAMS =
  84. noinst_HEADERS = \
  85. axpy/axpy.h \
  86. cg/cg.h \
  87. heat/lu_kernels_model.h \
  88. heat/dw_sparse_cg.h \
  89. heat/heat.h \
  90. heat/dw_factolu.h \
  91. lu/xlu.h \
  92. lu/xlu_kernels.h \
  93. lu/float.h \
  94. lu/double.h \
  95. lu/complex_float.h \
  96. lu/complex_double.h \
  97. lu/blas_complex.h \
  98. cholesky/cholesky.h \
  99. common/blas_model.h \
  100. common/blas.h \
  101. mult/simple.h \
  102. mult/double.h \
  103. gordon/null.h \
  104. fortran/bindings/StarPU_fortran.h \
  105. ppm_downscaler/ppm_downscaler.h \
  106. ppm_downscaler/yuv_downscaler.h \
  107. spmv/matrix_market/mmio.h \
  108. spmv/matrix_market/mm_to_bcsr.h \
  109. spmv/spmv.h \
  110. spmv/dw_block_spmv.h \
  111. basic_examples/multiformat_types.h \
  112. filters/custom_mf/custom_interface.h \
  113. filters/custom_mf/custom_types.h \
  114. interface/complex_interface.h \
  115. pi/pi.h \
  116. pi/SobolQRNG/sobol.h \
  117. pi/SobolQRNG/sobol_gold.h \
  118. pi/SobolQRNG/sobol_gpu.h \
  119. pi/SobolQRNG/sobol_primitives.h \
  120. reductions/dot_product.h
  121. #####################################
  122. # What to install and what to check #
  123. #####################################
  124. STARPU_EXAMPLES =
  125. TESTS = $(STARPU_EXAMPLES)
  126. if STARPU_HAVE_WINDOWS
  127. check_PROGRAMS = $(STARPU_EXAMPLES)
  128. else
  129. check_PROGRAMS = $(LOADER) $(STARPU_EXAMPLES)
  130. endif
  131. if !STARPU_HAVE_WINDOWS
  132. ## test loader program
  133. LOADER = loader
  134. loader_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) -I$(top_builddir)/src/
  135. LOADER_BIN = $(abs_top_builddir)/examples/$(LOADER)
  136. loader_SOURCES = ../tests/loader.c
  137. TESTS_ENVIRONMENT = top_builddir="$(abs_top_builddir)" top_srcdir="$(abs_top_srcdir)" $(LOADER_BIN)
  138. endif
  139. examplebin_PROGRAMS += \
  140. basic_examples/hello_world \
  141. basic_examples/vector_scal \
  142. basic_examples/mult \
  143. basic_examples/block \
  144. basic_examples/variable \
  145. basic_examples/multiformat \
  146. cpp/incrementer_cpp \
  147. filters/custom_mf/custom_mf_filter \
  148. filters/fvector \
  149. filters/fblock \
  150. filters/fmatrix \
  151. tag_example/tag_example \
  152. tag_example/tag_example2 \
  153. tag_example/tag_example3 \
  154. tag_example/tag_example4 \
  155. tag_example/tag_restartable \
  156. spmd/vector_scal_spmd \
  157. spmv/spmv \
  158. callback/callback \
  159. incrementer/incrementer \
  160. interface/complex \
  161. matvecmult/matvecmult \
  162. profiling/profiling \
  163. scheduler/dummy_sched \
  164. reductions/dot_product \
  165. reductions/minmax_reduction \
  166. mandelbrot/mandelbrot \
  167. ppm_downscaler/ppm_downscaler \
  168. ppm_downscaler/yuv_downscaler
  169. if STARPU_HAVE_F77_H
  170. examplebin_PROGRAMS += \
  171. basic_examples/vector_scal_fortran
  172. endif
  173. if !NO_BLAS_LIB
  174. examplebin_PROGRAMS += \
  175. axpy/axpy \
  176. mult/sgemm \
  177. mult/dgemm \
  178. cholesky/cholesky_tag \
  179. cholesky/cholesky_tile_tag \
  180. cholesky/cholesky_grain_tag \
  181. cholesky/cholesky_implicit \
  182. lu/lu_example_float \
  183. lu/lu_example_double \
  184. lu/lu_implicit_example_float \
  185. lu/lu_implicit_example_double \
  186. heat/heat \
  187. cg/cg
  188. endif
  189. if MKL_BLAS_LIB
  190. examplebin_PROGRAMS += \
  191. lu/lu_example_complex_float \
  192. lu/lu_example_complex_double \
  193. lu/lu_implicit_example_complex_float \
  194. lu/lu_implicit_example_complex_double
  195. endif
  196. if ATLAS_BLAS_LIB
  197. examplebin_PROGRAMS += \
  198. spmv/dw_block_spmv
  199. endif
  200. STARPU_EXAMPLES += \
  201. basic_examples/hello_world \
  202. basic_examples/vector_scal \
  203. basic_examples/mult \
  204. basic_examples/block \
  205. basic_examples/variable \
  206. basic_examples/multiformat \
  207. cpp/incrementer_cpp \
  208. filters/fvector \
  209. filters/fblock \
  210. filters/fmatrix \
  211. tag_example/tag_example \
  212. tag_example/tag_example2 \
  213. tag_example/tag_example3 \
  214. tag_example/tag_example4 \
  215. tag_example/tag_restartable \
  216. spmd/vector_scal_spmd \
  217. spmv/spmv \
  218. callback/callback \
  219. incrementer/incrementer \
  220. interface/complex \
  221. matvecmult/matvecmult \
  222. profiling/profiling \
  223. scheduler/dummy_sched \
  224. reductions/dot_product \
  225. reductions/minmax_reduction
  226. if STARPU_HAVE_F77_H
  227. STARPU_EXAMPLES += \
  228. basic_examples/vector_scal_fortran
  229. endif
  230. if !NO_BLAS_LIB
  231. STARPU_EXAMPLES += \
  232. axpy/axpy \
  233. mult/sgemm \
  234. mult/dgemm \
  235. cholesky/cholesky_tag \
  236. cholesky/cholesky_tile_tag \
  237. cholesky/cholesky_grain_tag \
  238. cholesky/cholesky_implicit \
  239. lu/lu_example_float \
  240. lu/lu_example_double \
  241. lu/lu_implicit_example_float \
  242. lu/lu_implicit_example_double \
  243. heat/heat \
  244. cg/cg
  245. endif
  246. if MKL_BLAS_LIB
  247. STARPU_EXAMPLES += \
  248. lu/lu_example_complex_float \
  249. lu/lu_example_complex_double \
  250. lu/lu_implicit_example_complex_float \
  251. lu/lu_implicit_example_complex_double
  252. endif
  253. if ATLAS_BLAS_LIB
  254. STARPU_EXAMPLES += \
  255. spmv/dw_block_spmv
  256. endif
  257. ##################
  258. # Basic examples #
  259. ##################
  260. basic_examples_vector_scal_SOURCES = \
  261. basic_examples/vector_scal.c \
  262. basic_examples/vector_scal_cpu.c
  263. if STARPU_HAVE_ICC
  264. basic_examples_vector_scal_SOURCES += \
  265. basic_examples/vector_scal_cpu_icc.icc
  266. basic_examples/vector_scal_cpu_icc.o: CFLAGS += -Dscal_cpu_func=scal_cpu_func_icc -Dscal_sse_func=scal_sse_func_icc
  267. endif
  268. if STARPU_USE_CUDA
  269. basic_examples_vector_scal_SOURCES += \
  270. basic_examples/vector_scal_cuda.cu
  271. endif
  272. if STARPU_USE_OPENCL
  273. basic_examples_vector_scal_SOURCES += \
  274. basic_examples/vector_scal_opencl.c
  275. nobase_STARPU_OPENCL_DATA_DATA += \
  276. basic_examples/vector_scal_opencl_kernel.cl
  277. endif
  278. if STARPU_HAVE_F77_H
  279. basic_examples_vector_scal_fortran_SOURCES = \
  280. basic_examples/vector_scal_fortran.F \
  281. basic_examples/vector_scal_c.c \
  282. basic_examples/vector_scal_cpu.c
  283. if STARPU_USE_CUDA
  284. basic_examples_vector_scal_fortran_SOURCES += \
  285. basic_examples/vector_scal_cuda.cu
  286. basic_examples_vector_scal_fortran_LDADD = \
  287. $(STARPU_CUDA_FORTRAN_LDFLAGS)
  288. endif
  289. endif
  290. #######################
  291. # Multiformat example #
  292. #######################
  293. basic_examples_multiformat_SOURCES = \
  294. basic_examples/multiformat.c \
  295. basic_examples/multiformat_conversion_codelets.c
  296. if STARPU_USE_CUDA
  297. basic_examples_multiformat_SOURCES += \
  298. basic_examples/multiformat_cuda.cu \
  299. basic_examples/multiformat_conversion_codelets_cuda.cu
  300. endif
  301. if STARPU_USE_OPENCL
  302. basic_examples_multiformat_SOURCES += \
  303. basic_examples/multiformat_opencl.c \
  304. basic_examples/multiformat_conversion_codelets_opencl.c
  305. nobase_STARPU_OPENCL_DATA_DATA += \
  306. basic_examples/multiformat_opencl_kernel.cl \
  307. basic_examples/multiformat_conversion_codelets_opencl_kernel.cl
  308. endif
  309. #################
  310. # block example #
  311. #################
  312. basic_examples_block_SOURCES = \
  313. basic_examples/block.c \
  314. basic_examples/block_cpu.c
  315. if STARPU_USE_CUDA
  316. basic_examples_block_SOURCES += \
  317. basic_examples/block_cuda.cu
  318. endif
  319. if STARPU_USE_OPENCL
  320. basic_examples_block_SOURCES += \
  321. basic_examples/block_opencl.c
  322. nobase_STARPU_OPENCL_DATA_DATA += \
  323. basic_examples/block_opencl_kernel.cl
  324. endif
  325. ####################
  326. # Variable example #
  327. ####################
  328. basic_examples_variable_SOURCES = \
  329. basic_examples/variable.c \
  330. basic_examples/variable_kernels_cpu.c
  331. if STARPU_USE_CUDA
  332. basic_examples_variable_SOURCES += \
  333. basic_examples/variable_kernels.cu
  334. endif
  335. if STARPU_USE_OPENCL
  336. basic_examples_variable_SOURCES += \
  337. basic_examples/variable_kernels_opencl.c
  338. nobase_STARPU_OPENCL_DATA_DATA += \
  339. basic_examples/variable_kernels_opencl_kernel.cl
  340. endif
  341. ###########
  342. # Filters #
  343. ###########
  344. filters_fblock_SOURCES = \
  345. filters/fblock.c \
  346. filters/fblock_cpu.c
  347. if STARPU_USE_CUDA
  348. filters_fblock_SOURCES += \
  349. filters/fblock_cuda.cu
  350. endif
  351. if STARPU_USE_OPENCL
  352. filters_fblock_SOURCES += \
  353. filters/fblock_opencl.c
  354. nobase_STARPU_OPENCL_DATA_DATA += \
  355. filters/fblock_opencl_kernel.cl
  356. endif
  357. #############################
  358. # Custom multiformat filter #
  359. #############################
  360. filters_custom_mf_custom_mf_filter_SOURCES=\
  361. filters/custom_mf/custom_mf_filter.c \
  362. filters/custom_mf/custom_interface.c \
  363. filters/custom_mf/custom_conversion_codelets.c
  364. if STARPU_USE_CUDA
  365. filters_custom_mf_custom_mf_filter_SOURCES += \
  366. filters/custom_mf/conversion.cu \
  367. filters/custom_mf/cuda.cu
  368. endif
  369. if STARPU_USE_OPENCL
  370. filters_custom_mf_custom_mf_filter_SOURCES += \
  371. filters/custom_mf/conversion_opencl.c \
  372. filters/custom_mf/custom_opencl.c
  373. nobase_STARPU_OPENCL_DATA_DATA += \
  374. filters/custom_mf/conversion_opencl.cl \
  375. filters/custom_mf/custom_opencl.cl
  376. endif
  377. ################
  378. # AXPY example #
  379. ################
  380. if !NO_BLAS_LIB
  381. axpy_axpy_SOURCES = \
  382. axpy/axpy.c \
  383. common/blas.c
  384. if STARPU_USE_OPENCL
  385. axpy_axpy_SOURCES += \
  386. axpy/axpy_opencl.c
  387. nobase_STARPU_OPENCL_DATA_DATA += \
  388. axpy/axpy_opencl_kernel.cl
  389. endif
  390. axpy_axpy_LDADD = \
  391. $(STARPU_BLAS_LDFLAGS)
  392. endif
  393. ################
  394. # Mult example #
  395. ################
  396. if !NO_BLAS_LIB
  397. mult_sgemm_SOURCES = \
  398. mult/sgemm.c \
  399. common/blas.c
  400. mult_sgemm_LDADD = \
  401. $(STARPU_BLAS_LDFLAGS)
  402. mult_dgemm_SOURCES = \
  403. mult/dgemm.c \
  404. common/blas.c
  405. mult_dgemm_LDADD = \
  406. $(STARPU_BLAS_LDFLAGS)
  407. endif
  408. ####################
  409. # Cholesky example #
  410. ####################
  411. if !NO_BLAS_LIB
  412. cholesky_cholesky_tag_SOURCES = \
  413. cholesky/cholesky_tag.c \
  414. cholesky/cholesky_models.c \
  415. cholesky/cholesky_kernels.c \
  416. common/blas.c
  417. cholesky_cholesky_tag_LDADD = \
  418. $(STARPU_BLAS_LDFLAGS)
  419. cholesky_cholesky_tile_tag_SOURCES = \
  420. cholesky/cholesky_tile_tag.c \
  421. cholesky/cholesky_models.c \
  422. cholesky/cholesky_kernels.c \
  423. common/blas.c
  424. cholesky_cholesky_tile_tag_LDADD = \
  425. $(STARPU_BLAS_LDFLAGS)
  426. cholesky_cholesky_grain_tag_SOURCES = \
  427. cholesky/cholesky_grain_tag.c \
  428. cholesky/cholesky_models.c \
  429. cholesky/cholesky_kernels.c \
  430. common/blas.c
  431. cholesky_cholesky_grain_tag_LDADD = \
  432. $(STARPU_BLAS_LDFLAGS)
  433. cholesky_cholesky_implicit_SOURCES = \
  434. cholesky/cholesky_implicit.c \
  435. cholesky/cholesky_models.c \
  436. cholesky/cholesky_kernels.c \
  437. common/blas.c
  438. cholesky_cholesky_implicit_LDADD = \
  439. $(STARPU_BLAS_LDFLAGS)
  440. endif
  441. ##############
  442. # LU example #
  443. ##############
  444. if !NO_BLAS_LIB
  445. lu_lu_example_float_SOURCES = \
  446. lu/lu_example_float.c \
  447. lu/slu.c \
  448. lu/slu_pivot.c \
  449. lu/slu_kernels.c \
  450. common/blas.c
  451. lu_lu_example_float_LDADD = \
  452. $(STARPU_BLAS_LDFLAGS)
  453. lu_lu_example_double_SOURCES = \
  454. lu/lu_example_double.c \
  455. lu/dlu.c \
  456. lu/dlu_pivot.c \
  457. lu/dlu_kernels.c \
  458. common/blas.c
  459. lu_lu_example_double_LDADD = \
  460. $(STARPU_BLAS_LDFLAGS)
  461. lu_lu_implicit_example_float_SOURCES = \
  462. lu/lu_example_float.c \
  463. lu/slu_implicit.c \
  464. lu/slu_implicit_pivot.c \
  465. lu/slu_kernels.c \
  466. common/blas.c
  467. lu_lu_implicit_example_float_LDADD = \
  468. $(STARPU_BLAS_LDFLAGS)
  469. lu_lu_implicit_example_double_SOURCES = \
  470. lu/lu_example_double.c \
  471. lu/dlu_implicit.c \
  472. lu/dlu_implicit_pivot.c \
  473. lu/dlu_kernels.c \
  474. common/blas.c
  475. lu_lu_implicit_example_double_LDADD = \
  476. $(STARPU_BLAS_LDFLAGS)
  477. if MKL_BLAS_LIB
  478. lu_lu_example_complex_float_SOURCES = \
  479. lu/lu_example_complex_float.c \
  480. lu/clu.c \
  481. lu/clu_pivot.c \
  482. lu/clu_kernels.c \
  483. lu/blas_complex.c \
  484. common/blas.c
  485. lu_lu_example_complex_float_LDADD = \
  486. $(STARPU_BLAS_LDFLAGS)
  487. lu_lu_implicit_example_complex_float_SOURCES = \
  488. lu/lu_example_complex_float.c \
  489. lu/clu_implicit.c \
  490. lu/clu_implicit_pivot.c \
  491. lu/clu_kernels.c \
  492. lu/blas_complex.c \
  493. common/blas.c
  494. lu_lu_implicit_example_complex_float_LDADD = \
  495. $(STARPU_BLAS_LDFLAGS)
  496. lu_lu_example_complex_double_SOURCES = \
  497. lu/lu_example_complex_double.c \
  498. lu/zlu.c \
  499. lu/zlu_pivot.c \
  500. lu/zlu_kernels.c \
  501. lu/blas_complex.c \
  502. common/blas.c
  503. lu_lu_example_complex_double_LDADD = \
  504. $(STARPU_BLAS_LDFLAGS)
  505. lu_lu_implicit_example_complex_double_SOURCES = \
  506. lu/lu_example_complex_double.c \
  507. lu/zlu_implicit.c \
  508. lu/zlu_implicit_pivot.c \
  509. lu/zlu_kernels.c \
  510. lu/blas_complex.c \
  511. common/blas.c
  512. lu_lu_implicit_example_complex_double_LDADD = \
  513. $(STARPU_BLAS_LDFLAGS)
  514. endif
  515. endif
  516. ################
  517. # Heat example #
  518. ################
  519. if !NO_BLAS_LIB
  520. heat_heat_SOURCES = \
  521. heat/heat.c \
  522. heat/dw_factolu.c \
  523. heat/dw_factolu_tag.c \
  524. heat/dw_factolu_grain.c \
  525. heat/dw_sparse_cg.c \
  526. heat/heat_display.c \
  527. heat/lu_kernels_model.c \
  528. heat/dw_sparse_cg_kernels.c \
  529. heat/dw_factolu_kernels.c \
  530. common/blas.c
  531. heat_heat_LDADD = \
  532. $(STARPU_OPENGL_RENDER_LDFLAGS) \
  533. $(STARPU_BLAS_LDFLAGS)
  534. endif
  535. ##############
  536. # CG example #
  537. ##############
  538. if !NO_BLAS_LIB
  539. cg_cg_SOURCES = \
  540. cg/cg.c \
  541. cg/cg_kernels.c \
  542. common/blas.c
  543. if STARPU_USE_CUDA
  544. cg_cg_SOURCES += \
  545. cg/cg_dot_kernel.cu
  546. endif
  547. cg_cg_LDADD = \
  548. $(STARPU_BLAS_LDFLAGS)
  549. endif
  550. ################
  551. # SPMD example #
  552. ################
  553. spmd_vector_scal_spmd_SOURCES = \
  554. spmd/vector_scal_spmd.c
  555. ################
  556. # SpMV example #
  557. ################
  558. spmv_spmv_SOURCES = \
  559. spmv/spmv.c \
  560. spmv/spmv_kernels.c
  561. if STARPU_USE_CUDA
  562. spmv_spmv_SOURCES += \
  563. spmv/spmv_cuda.cu
  564. endif
  565. if ATLAS_BLAS_LIB
  566. spmv_dw_block_spmv_SOURCES = \
  567. spmv/dw_block_spmv.c \
  568. spmv/dw_block_spmv_kernels.c \
  569. spmv/matrix_market/mm_to_bcsr.c \
  570. spmv/matrix_market/mmio.c
  571. spmv_dw_block_spmv_LDADD = \
  572. $(STARPU_BLAS_LDFLAGS)
  573. endif
  574. ###########################
  575. # C++ Incrementer example #
  576. ###########################
  577. cpp_incrementer_cpp_SOURCES = \
  578. cpp/incrementer_cpp.cpp
  579. if STARPU_USE_CUDA
  580. cpp_incrementer_cpp_SOURCES += \
  581. incrementer/incrementer_kernels.cu
  582. endif
  583. if STARPU_USE_OPENCL
  584. cpp_incrementer_cpp_SOURCES += \
  585. incrementer/incrementer_kernels_opencl.c
  586. endif
  587. #######################
  588. # Incrementer example #
  589. #######################
  590. incrementer_incrementer_SOURCES = \
  591. incrementer/incrementer.c
  592. if STARPU_USE_CUDA
  593. incrementer_incrementer_SOURCES += \
  594. incrementer/incrementer_kernels.cu
  595. endif
  596. if STARPU_USE_OPENCL
  597. incrementer_incrementer_SOURCES += \
  598. incrementer/incrementer_kernels_opencl.c
  599. nobase_STARPU_OPENCL_DATA_DATA += \
  600. incrementer/incrementer_kernels_opencl_kernel.cl
  601. endif
  602. #####################
  603. # interface example #
  604. #####################
  605. interface_complex_SOURCES = \
  606. interface/complex.c \
  607. interface/complex_interface.c
  608. if STARPU_USE_CUDA
  609. interface_complex_SOURCES += \
  610. interface/complex_kernels.cu
  611. endif
  612. if STARPU_USE_OPENCL
  613. interface_complex_SOURCES +=\
  614. interface/complex_kernels_opencl.c
  615. nobase_STARPU_OPENCL_DATA_DATA += \
  616. interface/complex_kernels.cl
  617. endif
  618. ######################
  619. # matVecMult example #
  620. ######################
  621. if STARPU_USE_OPENCL
  622. nobase_STARPU_OPENCL_DATA_DATA += \
  623. matvecmult/matvecmult_kernel.cl
  624. endif
  625. #######################
  626. # dot_product example #
  627. #######################
  628. reductions_dot_product_SOURCES = \
  629. reductions/dot_product.c
  630. if STARPU_USE_CUDA
  631. reductions_dot_product_SOURCES += \
  632. reductions/dot_product_kernels.cu
  633. endif
  634. if STARPU_USE_OPENCL
  635. nobase_STARPU_OPENCL_DATA_DATA += \
  636. reductions/dot_product_opencl_kernels.cl
  637. endif
  638. ##################
  639. # Mandelbrot Set #
  640. ##################
  641. mandelbrot_mandelbrot_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS)
  642. if HAVE_X11
  643. mandelbrot_mandelbrot_CPPFLAGS += $(X_CFLAGS)
  644. mandelbrot_mandelbrot_LDADD = $(X_PRE_LIBS) $(X_LIBS) $(X_EXTRA_LIBS) -lX11
  645. endif
  646. ################
  647. # Top Examples #
  648. ################
  649. examplebin_PROGRAMS += \
  650. top/hello_world_top
  651. top_hello_world_top_SOURCES = \
  652. top/hello_world_top.c
  653. ######
  654. # Pi #
  655. ######
  656. check_PROGRAMS += \
  657. pi/pi \
  658. pi/pi_redux
  659. examplebin_PROGRAMS += \
  660. pi/pi \
  661. pi/pi_redux
  662. pi_pi_SOURCES = \
  663. pi/pi.c \
  664. pi/SobolQRNG/sobol_gold.c \
  665. pi/SobolQRNG/sobol_primitives.c
  666. if STARPU_USE_CUDA
  667. pi_pi_SOURCES += \
  668. pi/pi_kernel.cu \
  669. pi/SobolQRNG/sobol_gpu.cu
  670. endif
  671. pi_pi_redux_SOURCES = \
  672. pi/pi_redux.c
  673. if STARPU_USE_CUDA
  674. pi_pi_redux_SOURCES += \
  675. pi/pi_redux_kernel.cu
  676. pi_pi_redux_LDADD = \
  677. $(STARPU_CURAND_LDFLAGS)
  678. endif
  679. showcheck:
  680. -cat $(TEST_LOGS) /dev/null
  681. for i in $(SUBDIRS) ; do \
  682. make -C $$i showcheck ; \
  683. done