Makefile.am 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873
  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_LINK@ $(MAGMA_LIBS) $(HWLOC_LIBS) @LIBS@
  21. AM_CPPFLAGS = -I$(top_srcdir)/include/ -I$(top_srcdir)/examples/ -I$(top_builddir)/include
  22. AM_LDFLAGS = $(STARPU_OPENCL_LDFLAGS) $(STARPU_CUDA_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. scheduler/schedulers.sh
  56. CLEANFILES = \
  57. gordon/null_kernel_gordon.spuelf
  58. CLEANFILES += *.gcno *.gcda *.linkinfo
  59. if STARPU_USE_CUDA
  60. NVCCFLAGS += --compiler-options -fno-strict-aliasing -I$(top_srcdir)/include/ -I$(top_builddir)/include/ -I$(top_srcdir)/examples/ $(HWLOC_CFLAGS)
  61. .cu.o:
  62. $(NVCC) $< -c -o $@ $(NVCCFLAGS)
  63. endif
  64. if STARPU_HAVE_ICC
  65. .icc.o:
  66. $(ICC) -x c $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
  67. $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) $< -c -o $@
  68. endif
  69. examplebindir = $(libdir)/starpu/examples/
  70. examplebin_PROGRAMS =
  71. noinst_HEADERS = \
  72. axpy/axpy.h \
  73. cg/cg.h \
  74. heat/lu_kernels_model.h \
  75. heat/dw_sparse_cg.h \
  76. heat/heat.h \
  77. heat/dw_factolu.h \
  78. lu/xlu.h \
  79. lu/xlu_kernels.h \
  80. lu/lu-float.h \
  81. lu/lu-double.h \
  82. lu/complex_float.h \
  83. lu/complex_double.h \
  84. lu/blas_complex.h \
  85. cholesky/cholesky.h \
  86. common/blas_model.h \
  87. common/blas.h \
  88. mult/simple.h \
  89. mult/double.h \
  90. gordon/null.h \
  91. fortran/bindings/StarPU_fortran.h \
  92. ppm_downscaler/ppm_downscaler.h \
  93. ppm_downscaler/yuv_downscaler.h \
  94. spmv/matrix_market/mmio.h \
  95. spmv/matrix_market/mm_to_bcsr.h \
  96. spmv/spmv.h \
  97. spmv/dw_block_spmv.h \
  98. basic_examples/multiformat_types.h \
  99. filters/custom_mf/custom_interface.h \
  100. filters/custom_mf/custom_types.h \
  101. interface/complex_interface.h \
  102. interface/complex_codelet.h \
  103. pi/pi.h \
  104. pi/SobolQRNG/sobol.h \
  105. pi/SobolQRNG/sobol_gold.h \
  106. pi/SobolQRNG/sobol_gpu.h \
  107. pi/SobolQRNG/sobol_primitives.h \
  108. reductions/dot_product.h \
  109. basic_examples/vector_scal_cpu_template.h
  110. #####################################
  111. # What to install and what to check #
  112. #####################################
  113. STARPU_EXAMPLES =
  114. TESTS = $(STARPU_EXAMPLES)
  115. TESTS += scheduler/schedulers.sh
  116. if STARPU_HAVE_WINDOWS
  117. check_PROGRAMS = $(STARPU_EXAMPLES)
  118. else
  119. check_PROGRAMS = $(LOADER) $(STARPU_EXAMPLES)
  120. endif
  121. if !STARPU_HAVE_WINDOWS
  122. ## test loader program
  123. LOADER = loader
  124. loader_CPPFLAGS = $(AM_CFLAGS) $(AM_CPPFLAGS) -I$(top_builddir)/src/
  125. LOADER_BIN = $(abs_top_builddir)/examples/$(LOADER)
  126. loader_SOURCES = ../tests/loader.c
  127. if STARPU_HAVE_AM111
  128. TESTS_ENVIRONMENT = top_builddir="$(abs_top_builddir)" top_srcdir="$(abs_top_srcdir)"
  129. LOG_COMPILER = $(LOADER_BIN)
  130. else
  131. TESTS_ENVIRONMENT = top_builddir="$(abs_top_builddir)" top_srcdir="$(abs_top_srcdir)" $(LOADER_BIN)
  132. endif
  133. endif
  134. examplebin_PROGRAMS += \
  135. basic_examples/hello_world \
  136. basic_examples/vector_scal \
  137. basic_examples/mult \
  138. basic_examples/block \
  139. basic_examples/variable \
  140. basic_examples/multiformat \
  141. cpp/incrementer_cpp \
  142. filters/custom_mf/custom_mf_filter \
  143. filters/fvector \
  144. filters/fblock \
  145. filters/fmatrix \
  146. filters/shadow \
  147. filters/shadow2d \
  148. filters/shadow3d \
  149. tag_example/tag_example \
  150. tag_example/tag_example2 \
  151. tag_example/tag_example3 \
  152. tag_example/tag_example4 \
  153. tag_example/tag_restartable \
  154. spmd/vector_scal_spmd \
  155. spmv/spmv \
  156. callback/callback \
  157. incrementer/incrementer \
  158. binary/binary \
  159. interface/complex \
  160. matvecmult/matvecmult \
  161. profiling/profiling \
  162. scheduler/dummy_sched \
  163. reductions/dot_product \
  164. reductions/minmax_reduction \
  165. ppm_downscaler/ppm_downscaler \
  166. ppm_downscaler/yuv_downscaler
  167. if STARPU_HAVE_F77_H
  168. examplebin_PROGRAMS += \
  169. basic_examples/vector_scal_fortran
  170. endif
  171. if !NO_BLAS_LIB
  172. examplebin_PROGRAMS += \
  173. axpy/axpy \
  174. mult/sgemm \
  175. mult/dgemm \
  176. cholesky/cholesky_tag \
  177. cholesky/cholesky_tile_tag \
  178. cholesky/cholesky_grain_tag \
  179. cholesky/cholesky_implicit \
  180. lu/lu_example_float \
  181. lu/lu_example_double \
  182. lu/lu_implicit_example_float \
  183. lu/lu_implicit_example_double \
  184. heat/heat \
  185. cg/cg \
  186. pipeline/pipeline
  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. spmd/vector_scal_spmd \
  216. spmv/spmv \
  217. callback/callback \
  218. incrementer/incrementer \
  219. binary/binary \
  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. pipeline/pipeline
  246. endif
  247. if MKL_BLAS_LIB
  248. STARPU_EXAMPLES += \
  249. lu/lu_example_complex_float \
  250. lu/lu_example_complex_double \
  251. lu/lu_implicit_example_complex_float \
  252. lu/lu_implicit_example_complex_double
  253. endif
  254. if ATLAS_BLAS_LIB
  255. STARPU_EXAMPLES += \
  256. spmv/dw_block_spmv
  257. endif
  258. ##################
  259. # Basic examples #
  260. ##################
  261. basic_examples_vector_scal_SOURCES = \
  262. basic_examples/vector_scal.c \
  263. basic_examples/vector_scal_cpu.c
  264. if STARPU_HAVE_ICC
  265. basic_examples_vector_scal_SOURCES += \
  266. basic_examples/vector_scal_cpu_icc.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. cg/cg_dot_kernel.o: cg/cg_dot_kernel.cu
  547. $(NVCC) $< -c -o $@ $(NVCCFLAGS) -arch sm_13
  548. endif
  549. cg_cg_LDADD = \
  550. $(STARPU_BLAS_LDFLAGS)
  551. endif
  552. ################
  553. # SPMD example #
  554. ################
  555. spmd_vector_scal_spmd_SOURCES = \
  556. spmd/vector_scal_spmd.c
  557. ################
  558. # SpMV example #
  559. ################
  560. spmv_spmv_SOURCES = \
  561. spmv/spmv.c \
  562. spmv/spmv_kernels.c
  563. if STARPU_USE_CUDA
  564. spmv_spmv_SOURCES += \
  565. spmv/spmv_cuda.cu
  566. endif
  567. if ATLAS_BLAS_LIB
  568. spmv_dw_block_spmv_SOURCES = \
  569. spmv/dw_block_spmv.c \
  570. spmv/dw_block_spmv_kernels.c \
  571. spmv/matrix_market/mm_to_bcsr.c \
  572. spmv/matrix_market/mmio.c
  573. spmv_dw_block_spmv_LDADD = \
  574. $(STARPU_BLAS_LDFLAGS)
  575. endif
  576. ###########################
  577. # C++ Incrementer example #
  578. ###########################
  579. cpp_incrementer_cpp_SOURCES = \
  580. cpp/incrementer_cpp.cpp
  581. if STARPU_USE_CUDA
  582. cpp_incrementer_cpp_SOURCES += \
  583. incrementer/incrementer_kernels.cu
  584. endif
  585. if STARPU_USE_OPENCL
  586. cpp_incrementer_cpp_SOURCES += \
  587. incrementer/incrementer_kernels_opencl.c
  588. endif
  589. #######################
  590. # Incrementer example #
  591. #######################
  592. incrementer_incrementer_SOURCES = \
  593. incrementer/incrementer.c
  594. if STARPU_USE_CUDA
  595. incrementer_incrementer_SOURCES += \
  596. incrementer/incrementer_kernels.cu
  597. endif
  598. if STARPU_USE_OPENCL
  599. incrementer_incrementer_SOURCES += \
  600. incrementer/incrementer_kernels_opencl.c
  601. nobase_STARPU_OPENCL_DATA_DATA += \
  602. incrementer/incrementer_kernels_opencl_kernel.cl
  603. endif
  604. ##################
  605. # Binary example #
  606. ##################
  607. binary_binary_SOURCES = \
  608. binary/binary.c
  609. if STARPU_USE_OPENCL
  610. binary_binary_SOURCES += \
  611. incrementer/incrementer_kernels_opencl.c
  612. endif
  613. #####################
  614. # interface example #
  615. #####################
  616. interface_complex_SOURCES = \
  617. interface/complex.c \
  618. interface/complex_interface.c
  619. if STARPU_USE_CUDA
  620. interface_complex_SOURCES += \
  621. interface/complex_kernels.cu
  622. interface/complex_kernels.o: interface/complex_kernels.cu
  623. $(NVCC) $< -c -o $@ $(NVCCFLAGS) -arch sm_13
  624. endif
  625. if STARPU_USE_OPENCL
  626. interface_complex_SOURCES +=\
  627. interface/complex_kernels_opencl.c
  628. nobase_STARPU_OPENCL_DATA_DATA += \
  629. interface/complex_kernels.cl
  630. endif
  631. ######################
  632. # matVecMult example #
  633. ######################
  634. if STARPU_USE_OPENCL
  635. nobase_STARPU_OPENCL_DATA_DATA += \
  636. matvecmult/matvecmult_kernel.cl
  637. endif
  638. #######################
  639. # dot_product example #
  640. #######################
  641. reductions_dot_product_SOURCES = \
  642. reductions/dot_product.c
  643. if STARPU_USE_CUDA
  644. reductions_dot_product_SOURCES += \
  645. reductions/dot_product_kernels.cu
  646. reductions/dot_product_kernels.o: reductions/dot_product_kernels.cu
  647. $(NVCC) $< -c -o $@ $(NVCCFLAGS) -arch sm_13
  648. endif
  649. if STARPU_USE_OPENCL
  650. nobase_STARPU_OPENCL_DATA_DATA += \
  651. reductions/dot_product_opencl_kernels.cl
  652. endif
  653. ##################
  654. # Mandelbrot Set #
  655. ##################
  656. ################
  657. # Top Examples #
  658. ################
  659. examplebin_PROGRAMS += \
  660. top/hello_world_top
  661. top_hello_world_top_SOURCES = \
  662. top/hello_world_top.c
  663. ######
  664. # Pi #
  665. ######
  666. check_PROGRAMS += \
  667. pi/pi \
  668. pi/pi_redux
  669. examplebin_PROGRAMS += \
  670. pi/pi \
  671. pi/pi_redux
  672. pi_pi_SOURCES = \
  673. pi/pi.c \
  674. pi/SobolQRNG/sobol_gold.c \
  675. pi/SobolQRNG/sobol_primitives.c
  676. if STARPU_USE_CUDA
  677. pi_pi_SOURCES += \
  678. pi/pi_kernel.cu \
  679. pi/SobolQRNG/sobol_gpu.cu
  680. endif
  681. pi_pi_redux_SOURCES = \
  682. pi/pi_redux.c
  683. if STARPU_USE_CUDA
  684. pi_pi_redux_SOURCES += \
  685. pi/pi_redux_kernel.cu
  686. pi_pi_redux_LDADD = \
  687. $(STARPU_CURAND_LDFLAGS)
  688. endif
  689. ###########################
  690. # OpenGL interoperability #
  691. ###########################
  692. if HAVE_OPENGL
  693. examplebin_PROGRAMS += \
  694. gl_interop/gl_interop \
  695. gl_interop/gl_interop_idle
  696. gl_interop_gl_interop_SOURCES = \
  697. gl_interop/gl_interop.c
  698. gl_interop_gl_interop_LDADD = \
  699. $(STARPU_OPENGL_RENDER_LDFLAGS)
  700. gl_interop_gl_interop_idle_SOURCES = \
  701. gl_interop/gl_interop_idle.c
  702. gl_interop_gl_interop_idle_LDADD = \
  703. $(STARPU_OPENGL_RENDER_LDFLAGS)
  704. endif
  705. ####################
  706. # pipeline example #
  707. ####################
  708. if !NO_BLAS_LIB
  709. pipeline_pipeline_SOURCES = \
  710. pipeline/pipeline.c \
  711. common/blas.c
  712. pipeline_pipeline_LDADD = \
  713. $(STARPU_BLAS_LDFLAGS)
  714. endif
  715. showcheck:
  716. -cat $(TEST_LOGS) /dev/null
  717. for i in $(SUBDIRS) ; do \
  718. make -C $$i showcheck ; \
  719. done