Makefile.am 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815
  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) 2011-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. AUTOMAKE_OPTIONS = subdir-objects
  24. SUBDIRS = stencil
  25. BUILT_SOURCES =
  26. if STARPU_USE_OPENCL
  27. nobase_STARPU_OPENCL_DATA_DATA =
  28. endif
  29. EXTRA_DIST = \
  30. axpy/axpy_opencl_kernel.cl \
  31. basic_examples/vector_scal_opencl_kernel.cl \
  32. basic_examples/multiformat_opencl_kernel.cl \
  33. basic_examples/multiformat_conversion_codelets_opencl_kernel.cl \
  34. common/blas_model.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. sched_ctx_utils/sched_ctx_utils.c \
  46. incrementer/incrementer_kernels_opencl_kernel.cl \
  47. basic_examples/variable_kernels_opencl_kernel.cl \
  48. matvecmult/matvecmult_kernel.cl \
  49. basic_examples/block_opencl_kernel.cl \
  50. openmp/vector_scal.c \
  51. filters/fblock_opencl_kernel.cl \
  52. filters/custom_mf/conversion_opencl.cl \
  53. filters/custom_mf/custom_opencl.cl \
  54. interface/complex_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. sched_ctx_utils/sched_ctx_utils.h \
  100. common/blas_model.h \
  101. common/blas.h \
  102. mult/simple.h \
  103. mult/double.h \
  104. gordon/null.h \
  105. fortran/bindings/StarPU_fortran.h \
  106. ppm_downscaler/ppm_downscaler.h \
  107. ppm_downscaler/yuv_downscaler.h \
  108. spmv/matrix_market/mmio.h \
  109. spmv/matrix_market/mm_to_bcsr.h \
  110. spmv/spmv.h \
  111. spmv/dw_block_spmv.h \
  112. basic_examples/multiformat_types.h \
  113. filters/custom_mf/custom_interface.h \
  114. filters/custom_mf/custom_types.h \
  115. interface/complex_interface.h \
  116. pi/pi.h \
  117. pi/SobolQRNG/sobol.h \
  118. pi/SobolQRNG/sobol_gold.h \
  119. pi/SobolQRNG/sobol_gpu.h \
  120. pi/SobolQRNG/sobol_primitives.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. spmv/spmv \
  157. callback/callback \
  158. incrementer/incrementer \
  159. interface/complex \
  160. matvecmult/matvecmult \
  161. profiling/profiling \
  162. scheduler/dummy_sched \
  163. reductions/dot_product \
  164. reductions/minmax_reduction \
  165. mandelbrot/mandelbrot \
  166. ppm_downscaler/ppm_downscaler \
  167. ppm_downscaler/yuv_downscaler
  168. if STARPU_HAVE_F77_H
  169. examplebin_PROGRAMS += \
  170. basic_examples/vector_scal_fortran
  171. endif
  172. if !NO_BLAS_LIB
  173. examplebin_PROGRAMS += \
  174. axpy/axpy \
  175. mult/sgemm \
  176. mult/dgemm \
  177. cholesky/cholesky_tag \
  178. cholesky/cholesky_tile_tag \
  179. cholesky/cholesky_grain_tag \
  180. cholesky/cholesky_implicit \
  181. lu/lu_example_float \
  182. lu/lu_example_double \
  183. lu/lu_implicit_example_float \
  184. lu/lu_implicit_example_double \
  185. heat/heat \
  186. cg/cg
  187. endif
  188. if MKL_BLAS_LIB
  189. examplebin_PROGRAMS += \
  190. lu/lu_example_complex_float \
  191. lu/lu_example_complex_double \
  192. lu/lu_implicit_example_complex_float \
  193. lu/lu_implicit_example_complex_double
  194. endif
  195. if ATLAS_BLAS_LIB
  196. examplebin_PROGRAMS += \
  197. spmv/dw_block_spmv
  198. endif
  199. STARPU_EXAMPLES += \
  200. basic_examples/hello_world \
  201. basic_examples/vector_scal \
  202. basic_examples/mult \
  203. basic_examples/block \
  204. basic_examples/variable \
  205. basic_examples/multiformat \
  206. cpp/incrementer_cpp \
  207. filters/fvector \
  208. filters/fblock \
  209. filters/fmatrix \
  210. tag_example/tag_example \
  211. tag_example/tag_example2 \
  212. tag_example/tag_example3 \
  213. tag_example/tag_example4 \
  214. tag_example/tag_restartable \
  215. spmv/spmv \
  216. callback/callback \
  217. incrementer/incrementer \
  218. interface/complex \
  219. matvecmult/matvecmult \
  220. profiling/profiling \
  221. scheduler/dummy_sched \
  222. reductions/dot_product \
  223. reductions/minmax_reduction
  224. if STARPU_HAVE_F77_H
  225. STARPU_EXAMPLES += \
  226. basic_examples/vector_scal_fortran
  227. endif
  228. if !NO_BLAS_LIB
  229. STARPU_EXAMPLES += \
  230. axpy/axpy \
  231. mult/sgemm \
  232. mult/dgemm \
  233. cholesky/cholesky_tag \
  234. cholesky/cholesky_tile_tag \
  235. cholesky/cholesky_grain_tag \
  236. cholesky/cholesky_implicit \
  237. lu/lu_example_float \
  238. lu/lu_example_double \
  239. lu/lu_implicit_example_float \
  240. lu/lu_implicit_example_double \
  241. heat/heat \
  242. cg/cg
  243. endif
  244. if MKL_BLAS_LIB
  245. STARPU_EXAMPLES += \
  246. lu/lu_example_complex_float \
  247. lu/lu_example_complex_double \
  248. lu/lu_implicit_example_complex_float \
  249. lu/lu_implicit_example_complex_double
  250. endif
  251. if ATLAS_BLAS_LIB
  252. STARPU_EXAMPLES += \
  253. spmv/dw_block_spmv
  254. endif
  255. ##################
  256. # Basic examples #
  257. ##################
  258. basic_examples_vector_scal_SOURCES = \
  259. basic_examples/vector_scal.c \
  260. basic_examples/vector_scal_cpu.c
  261. if STARPU_HAVE_ICC
  262. basic_examples_vector_scal_SOURCES += \
  263. basic_examples/vector_scal_cpu_icc.icc
  264. basic_examples/vector_scal_cpu_icc.o: CFLAGS += -Dscal_cpu_func=scal_cpu_func_icc -Dscal_sse_func=scal_sse_func_icc
  265. endif
  266. if STARPU_USE_CUDA
  267. basic_examples_vector_scal_SOURCES += \
  268. basic_examples/vector_scal_cuda.cu
  269. endif
  270. if STARPU_USE_OPENCL
  271. basic_examples_vector_scal_SOURCES += \
  272. basic_examples/vector_scal_opencl.c
  273. nobase_STARPU_OPENCL_DATA_DATA += \
  274. basic_examples/vector_scal_opencl_kernel.cl
  275. endif
  276. if STARPU_HAVE_F77_H
  277. basic_examples_vector_scal_fortran_SOURCES = \
  278. basic_examples/vector_scal_fortran.F \
  279. basic_examples/vector_scal_c.c \
  280. basic_examples/vector_scal_cpu.c
  281. if STARPU_USE_CUDA
  282. basic_examples_vector_scal_fortran_SOURCES += \
  283. basic_examples/vector_scal_cuda.cu
  284. basic_examples_vector_scal_fortran_LDADD = \
  285. $(STARPU_CUDA_FORTRAN_LDFLAGS)
  286. endif
  287. endif
  288. #######################
  289. # Multiformat example #
  290. #######################
  291. basic_examples_multiformat_SOURCES = \
  292. basic_examples/multiformat.c \
  293. basic_examples/multiformat_conversion_codelets.c
  294. if STARPU_USE_CUDA
  295. basic_examples_multiformat_SOURCES += \
  296. basic_examples/multiformat_cuda.cu \
  297. basic_examples/multiformat_conversion_codelets_cuda.cu
  298. endif
  299. if STARPU_USE_OPENCL
  300. basic_examples_multiformat_SOURCES += \
  301. basic_examples/multiformat_opencl.c \
  302. basic_examples/multiformat_conversion_codelets_opencl.c
  303. nobase_STARPU_OPENCL_DATA_DATA += \
  304. basic_examples/multiformat_opencl_kernel.cl \
  305. basic_examples/multiformat_conversion_codelets_opencl_kernel.cl
  306. endif
  307. #################
  308. # block example #
  309. #################
  310. basic_examples_block_SOURCES = \
  311. basic_examples/block.c \
  312. basic_examples/block_cpu.c
  313. if STARPU_USE_CUDA
  314. basic_examples_block_SOURCES += \
  315. basic_examples/block_cuda.cu
  316. endif
  317. if STARPU_USE_OPENCL
  318. basic_examples_block_SOURCES += \
  319. basic_examples/block_opencl.c
  320. nobase_STARPU_OPENCL_DATA_DATA += \
  321. basic_examples/block_opencl_kernel.cl
  322. endif
  323. ####################
  324. # Variable example #
  325. ####################
  326. basic_examples_variable_SOURCES = \
  327. basic_examples/variable.c \
  328. basic_examples/variable_kernels_cpu.c
  329. if STARPU_USE_CUDA
  330. basic_examples_variable_SOURCES += \
  331. basic_examples/variable_kernels.cu
  332. endif
  333. if STARPU_USE_OPENCL
  334. basic_examples_variable_SOURCES += \
  335. basic_examples/variable_kernels_opencl.c
  336. nobase_STARPU_OPENCL_DATA_DATA += \
  337. basic_examples/variable_kernels_opencl_kernel.cl
  338. endif
  339. ###########
  340. # Filters #
  341. ###########
  342. filters_fblock_SOURCES = \
  343. filters/fblock.c \
  344. filters/fblock_cpu.c
  345. if STARPU_USE_CUDA
  346. filters_fblock_SOURCES += \
  347. filters/fblock_cuda.cu
  348. endif
  349. if STARPU_USE_OPENCL
  350. filters_fblock_SOURCES += \
  351. filters/fblock_opencl.c
  352. nobase_STARPU_OPENCL_DATA_DATA += \
  353. filters/fblock_opencl_kernel.cl
  354. endif
  355. #############################
  356. # Custom multiformat filter #
  357. #############################
  358. filters_custom_mf_custom_mf_filter_SOURCES=\
  359. filters/custom_mf/custom_mf_filter.c \
  360. filters/custom_mf/custom_interface.c \
  361. filters/custom_mf/custom_conversion_codelets.c
  362. if STARPU_USE_CUDA
  363. filters_custom_mf_custom_mf_filter_SOURCES += \
  364. filters/custom_mf/conversion.cu \
  365. filters/custom_mf/cuda.cu
  366. endif
  367. if STARPU_USE_OPENCL
  368. filters_custom_mf_custom_mf_filter_SOURCES += \
  369. filters/custom_mf/conversion_opencl.c \
  370. filters/custom_mf/custom_opencl.c
  371. nobase_STARPU_OPENCL_DATA_DATA += \
  372. filters/custom_mf/conversion_opencl.cl \
  373. filters/custom_mf/custom_opencl.cl
  374. endif
  375. ################
  376. # AXPY example #
  377. ################
  378. if !NO_BLAS_LIB
  379. axpy_axpy_SOURCES = \
  380. axpy/axpy.c \
  381. common/blas.c
  382. if STARPU_USE_OPENCL
  383. axpy_axpy_SOURCES += \
  384. axpy/axpy_opencl.c
  385. nobase_STARPU_OPENCL_DATA_DATA += \
  386. axpy/axpy_opencl_kernel.cl
  387. endif
  388. axpy_axpy_LDADD = \
  389. $(STARPU_BLAS_LDFLAGS)
  390. endif
  391. ################
  392. # Mult example #
  393. ################
  394. if !NO_BLAS_LIB
  395. mult_sgemm_SOURCES = \
  396. mult/sgemm.c \
  397. common/blas.c
  398. mult_sgemm_LDADD = \
  399. $(STARPU_BLAS_LDFLAGS)
  400. mult_dgemm_SOURCES = \
  401. mult/dgemm.c \
  402. common/blas.c
  403. mult_dgemm_LDADD = \
  404. $(STARPU_BLAS_LDFLAGS)
  405. endif
  406. ####################
  407. # Cholesky example #
  408. ####################
  409. if !NO_BLAS_LIB
  410. cholesky_cholesky_tag_SOURCES = \
  411. cholesky/cholesky_tag.c \
  412. cholesky/cholesky_models.c \
  413. cholesky/cholesky_kernels.c \
  414. common/blas.c
  415. cholesky_cholesky_tag_LDADD = \
  416. $(STARPU_BLAS_LDFLAGS)
  417. cholesky_cholesky_tile_tag_SOURCES = \
  418. cholesky/cholesky_tile_tag.c \
  419. cholesky/cholesky_models.c \
  420. cholesky/cholesky_kernels.c \
  421. common/blas.c
  422. cholesky_cholesky_tile_tag_LDADD = \
  423. $(STARPU_BLAS_LDFLAGS)
  424. cholesky_cholesky_grain_tag_SOURCES = \
  425. cholesky/cholesky_grain_tag.c \
  426. cholesky/cholesky_models.c \
  427. cholesky/cholesky_kernels.c \
  428. common/blas.c
  429. cholesky_cholesky_grain_tag_LDADD = \
  430. $(STARPU_BLAS_LDFLAGS)
  431. cholesky_cholesky_implicit_SOURCES = \
  432. cholesky/cholesky_implicit.c \
  433. cholesky/cholesky_models.c \
  434. cholesky/cholesky_kernels.c \
  435. sched_ctx_utils/sched_ctx_utils.c \
  436. common/blas.c
  437. cholesky_cholesky_implicit_LDADD = \
  438. $(STARPU_BLAS_LDFLAGS)
  439. endif
  440. ##############
  441. # LU example #
  442. ##############
  443. if !NO_BLAS_LIB
  444. lu_lu_example_float_SOURCES = \
  445. lu/lu_example_float.c \
  446. lu/slu.c \
  447. lu/slu_pivot.c \
  448. lu/slu_kernels.c \
  449. common/blas.c
  450. lu_lu_example_float_LDADD = \
  451. $(STARPU_BLAS_LDFLAGS)
  452. lu_lu_example_double_SOURCES = \
  453. lu/lu_example_double.c \
  454. lu/dlu.c \
  455. lu/dlu_pivot.c \
  456. lu/dlu_kernels.c \
  457. common/blas.c
  458. lu_lu_example_double_LDADD = \
  459. $(STARPU_BLAS_LDFLAGS)
  460. lu_lu_implicit_example_float_SOURCES = \
  461. lu/lu_example_float.c \
  462. lu/slu_implicit.c \
  463. lu/slu_implicit_pivot.c \
  464. lu/slu_kernels.c \
  465. common/blas.c
  466. lu_lu_implicit_example_float_LDADD = \
  467. $(STARPU_BLAS_LDFLAGS)
  468. lu_lu_implicit_example_double_SOURCES = \
  469. lu/lu_example_double.c \
  470. lu/dlu_implicit.c \
  471. lu/dlu_implicit_pivot.c \
  472. lu/dlu_kernels.c \
  473. common/blas.c
  474. lu_lu_implicit_example_double_LDADD = \
  475. $(STARPU_BLAS_LDFLAGS)
  476. if MKL_BLAS_LIB
  477. lu_lu_example_complex_float_SOURCES = \
  478. lu/lu_example_complex_float.c \
  479. lu/clu.c \
  480. lu/clu_pivot.c \
  481. lu/clu_kernels.c \
  482. lu/blas_complex.c \
  483. common/blas.c
  484. lu_lu_example_complex_float_LDADD = \
  485. $(STARPU_BLAS_LDFLAGS)
  486. lu_lu_implicit_example_complex_float_SOURCES = \
  487. lu/lu_example_complex_float.c \
  488. lu/clu_implicit.c \
  489. lu/clu_implicit_pivot.c \
  490. lu/clu_kernels.c \
  491. lu/blas_complex.c \
  492. common/blas.c
  493. lu_lu_implicit_example_complex_float_LDADD = \
  494. $(STARPU_BLAS_LDFLAGS)
  495. lu_lu_example_complex_double_SOURCES = \
  496. lu/lu_example_complex_double.c \
  497. lu/zlu.c \
  498. lu/zlu_pivot.c \
  499. lu/zlu_kernels.c \
  500. lu/blas_complex.c \
  501. common/blas.c
  502. lu_lu_example_complex_double_LDADD = \
  503. $(STARPU_BLAS_LDFLAGS)
  504. lu_lu_implicit_example_complex_double_SOURCES = \
  505. lu/lu_example_complex_double.c \
  506. lu/zlu_implicit.c \
  507. lu/zlu_implicit_pivot.c \
  508. lu/zlu_kernels.c \
  509. lu/blas_complex.c \
  510. common/blas.c
  511. lu_lu_implicit_example_complex_double_LDADD = \
  512. $(STARPU_BLAS_LDFLAGS)
  513. endif
  514. endif
  515. ################
  516. # Heat example #
  517. ################
  518. if !NO_BLAS_LIB
  519. heat_heat_SOURCES = \
  520. heat/heat.c \
  521. heat/dw_factolu.c \
  522. heat/dw_factolu_tag.c \
  523. heat/dw_factolu_grain.c \
  524. heat/dw_sparse_cg.c \
  525. heat/heat_display.c \
  526. heat/lu_kernels_model.c \
  527. heat/dw_sparse_cg_kernels.c \
  528. heat/dw_factolu_kernels.c \
  529. common/blas.c
  530. heat_heat_LDADD = \
  531. $(STARPU_OPENGL_RENDER_LDFLAGS) \
  532. $(STARPU_BLAS_LDFLAGS)
  533. endif
  534. ##############
  535. # CG example #
  536. ##############
  537. if !NO_BLAS_LIB
  538. cg_cg_SOURCES = \
  539. cg/cg.c \
  540. cg/cg_kernels.c \
  541. common/blas.c
  542. if STARPU_USE_CUDA
  543. cg_cg_SOURCES += \
  544. cg/cg_dot_kernel.cu
  545. endif
  546. cg_cg_LDADD = \
  547. $(STARPU_BLAS_LDFLAGS)
  548. endif
  549. ################
  550. # SpMV example #
  551. ################
  552. spmv_spmv_SOURCES = \
  553. spmv/spmv.c \
  554. spmv/spmv_kernels.c
  555. if STARPU_USE_CUDA
  556. spmv_spmv_SOURCES += \
  557. spmv/spmv_cuda.cu
  558. endif
  559. if ATLAS_BLAS_LIB
  560. spmv_dw_block_spmv_SOURCES = \
  561. spmv/dw_block_spmv.c \
  562. spmv/dw_block_spmv_kernels.c \
  563. spmv/matrix_market/mm_to_bcsr.c \
  564. spmv/matrix_market/mmio.c
  565. spmv_dw_block_spmv_LDADD = \
  566. $(STARPU_BLAS_LDFLAGS)
  567. endif
  568. ###########################
  569. # C++ Incrementer example #
  570. ###########################
  571. cpp_incrementer_cpp_SOURCES = \
  572. cpp/incrementer_cpp.cpp
  573. #if STARPU_USE_CUDA
  574. #cpp_incrementer_cpp_SOURCES += \
  575. # incrementer/incrementer_kernels.cu
  576. #endif
  577. #######################
  578. # Incrementer example #
  579. #######################
  580. incrementer_incrementer_SOURCES = \
  581. incrementer/incrementer.c
  582. if STARPU_USE_CUDA
  583. incrementer_incrementer_SOURCES += \
  584. incrementer/incrementer_kernels.cu
  585. endif
  586. if STARPU_USE_OPENCL
  587. incrementer_incrementer_SOURCES += \
  588. incrementer/incrementer_kernels_opencl.c
  589. nobase_STARPU_OPENCL_DATA_DATA += \
  590. incrementer/incrementer_kernels_opencl_kernel.cl
  591. endif
  592. #####################
  593. # interface example #
  594. #####################
  595. interface_complex_SOURCES = \
  596. interface/complex.c \
  597. interface/complex_interface.c
  598. if STARPU_USE_CUDA
  599. interface_complex_SOURCES += \
  600. interface/complex_kernels.cu
  601. endif
  602. if STARPU_USE_OPENCL
  603. interface_complex_SOURCES +=\
  604. interface/complex_kernels_opencl.c
  605. nobase_STARPU_OPENCL_DATA_DATA += \
  606. interface/complex_kernels.cl
  607. endif
  608. ######################
  609. # matVecMult example #
  610. ######################
  611. if STARPU_USE_OPENCL
  612. nobase_STARPU_OPENCL_DATA_DATA += \
  613. matvecmult/matvecmult_kernel.cl
  614. endif
  615. #######################
  616. # dot_product example #
  617. #######################
  618. reductions_dot_product_SOURCES = \
  619. reductions/dot_product.c
  620. if STARPU_USE_CUDA
  621. reductions_dot_product_SOURCES += \
  622. reductions/dot_product_kernels.cu
  623. endif
  624. ##################
  625. # Mandelbrot Set #
  626. ##################
  627. mandelbrot_mandelbrot_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS)
  628. if HAVE_X11
  629. mandelbrot_mandelbrot_CPPFLAGS += $(X_CFLAGS)
  630. mandelbrot_mandelbrot_LDADD = $(X_PRE_LIBS) $(X_LIBS) $(X_EXTRA_LIBS) -lX11
  631. endif
  632. ################
  633. # Top Examples #
  634. ################
  635. examplebin_PROGRAMS += \
  636. top/hello_world_top
  637. top_hello_world_top_SOURCES = \
  638. top/hello_world_top.c
  639. ######
  640. # Pi #
  641. ######
  642. check_PROGRAMS += \
  643. pi/pi \
  644. pi/pi_redux
  645. examplebin_PROGRAMS += \
  646. pi/pi \
  647. pi/pi_redux
  648. pi_pi_SOURCES = \
  649. pi/pi.c \
  650. pi/SobolQRNG/sobol_gold.c \
  651. pi/SobolQRNG/sobol_primitives.c
  652. if STARPU_USE_CUDA
  653. pi_pi_SOURCES += \
  654. pi/pi_kernel.cu \
  655. pi/SobolQRNG/sobol_gpu.cu
  656. endif
  657. pi_pi_redux_SOURCES = \
  658. pi/pi_redux.c
  659. if STARPU_USE_CUDA
  660. pi_pi_redux_SOURCES += \
  661. pi/pi_redux_kernel.cu
  662. pi_pi_redux_LDADD = \
  663. $(STARPU_CURAND_LDFLAGS)
  664. endif
  665. showcheck:
  666. -cat $(TEST_LOGS) /dev/null
  667. for i in $(SUBDIRS) ; do \
  668. make -C $$i showcheck ; \
  669. done