Makefile.am 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428
  1. # StarPU --- Runtime system for heterogeneous multicore architectures.
  2. #
  3. # Copyright (C) 2011-2017 Inria
  4. # Copyright (C) 2012 Benjamin Lorendeau
  5. # Copyright (C) 2009-2019 Université de Bordeaux
  6. # Copyright (C) 2010-2015,2017,2018 CNRS
  7. # Copyright (C) 2013 Simon Archipoff
  8. #
  9. # StarPU is free software; you can redistribute it and/or modify
  10. # it under the terms of the GNU Lesser General Public License as published by
  11. # the Free Software Foundation; either version 2.1 of the License, or (at
  12. # your option) any later version.
  13. #
  14. # StarPU is distributed in the hope that it will be useful, but
  15. # WITHOUT ANY WARRANTY; without even the implied warranty of
  16. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  17. #
  18. # See the GNU Lesser General Public License in COPYING.LGPL for more details.
  19. #
  20. SUBDIRS =
  21. CLEANFILES = *.gcno *.gcda *.linkinfo
  22. EXTRA_DIST = dolib.c
  23. xml_DATA = $(srcdir)/core/perfmodel/starpu-perfmodel.dtd
  24. xmldir = $(pkgdatadir)
  25. EXTRA_DIST += core/perfmodel/starpu-perfmodel.dtd
  26. ldflags =
  27. libstarpu_so_version = $(LIBSTARPU_INTERFACE_CURRENT):$(LIBSTARPU_INTERFACE_REVISION):$(LIBSTARPU_INTERFACE_AGE)
  28. if STARPU_HAVE_WINDOWS
  29. LC_MESSAGES=C
  30. export LC_MESSAGES
  31. ldflags += -Xlinker --output-def -Xlinker .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.def
  32. if STARPU_HAVE_MS_LIB
  33. .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.lib: libstarpu-@STARPU_EFFECTIVE_VERSION@.la dolib
  34. ./dolib "$(STARPU_MS_LIB)" $(STARPU_MS_LIB_ARCH) .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.def @STARPU_EFFECTIVE_VERSION@ $(libstarpu_so_version) .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.lib
  35. all-local: .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.lib
  36. endif STARPU_HAVE_MS_LIB
  37. install-exec-hook:
  38. $(INSTALL) .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.def $(DESTDIR)$(libdir)
  39. if STARPU_HAVE_MS_LIB
  40. $(INSTALL) .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.lib $(DESTDIR)$(libdir)
  41. $(INSTALL) .libs/libstarpu-@STARPU_EFFECTIVE_VERSION@.exp $(DESTDIR)$(libdir)
  42. endif STARPU_HAVE_MS_LIB
  43. endif STARPU_HAVE_WINDOWS
  44. lib_LTLIBRARIES = libstarpu-@STARPU_EFFECTIVE_VERSION@.la
  45. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_CPPFLAGS = -I$(top_srcdir)/include/ -DBUILDING_STARPU $(GLOBAL_AM_CFLAGS) $(HWLOC_CFLAGS) $(STARPU_CUDA_CPPFLAGS) $(STARPU_OPENCL_CPPFLAGS) $(FXT_CFLAGS) $(STARPU_COI_CPPFLAGS) $(STARPU_SCIF_CPPFLAGS) $(STARPU_RCCE_CFLAGS) $(STARPU_RCCE_CPPFLAGS) -DSTARPU_DATADIR='"$(datadir)"'
  46. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_LIBADD = -lm $(STARPU_OPENCL_LDFLAGS) $(STARPU_CUDA_LDFLAGS) $(LIBSTARPU_LDFLAGS)
  47. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_LDFLAGS = $(ldflags) $(FXT_LDFLAGS) -no-undefined \
  48. -version-info $(libstarpu_so_version)
  49. if STARPU_HAVE_DARWIN
  50. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_LDFLAGS += \
  51. -Wl,-U,_starpu_main \
  52. -Wl,-U,_smpi_main \
  53. -Wl,-U,__starpu_mpi_simgrid_init \
  54. -Wl,-U,_smpi_simulated_main_ \
  55. -Wl,-U,_starpu_mpi_world_rank
  56. endif
  57. noinst_HEADERS = \
  58. core/dependencies/data_concurrency.h \
  59. core/dependencies/cg.h \
  60. core/dependencies/tags.h \
  61. core/dependencies/implicit_data_deps.h \
  62. core/disk.h \
  63. core/disk_ops/unistd/disk_unistd_global.h \
  64. core/progress_hook.h \
  65. core/idle_hook.h \
  66. core/sched_policy.h \
  67. core/sched_ctx.h \
  68. core/sched_ctx_list.h \
  69. core/perfmodel/perfmodel.h \
  70. core/perfmodel/regression.h \
  71. core/perfmodel/multiple_regression.h \
  72. core/jobs.h \
  73. core/task.h \
  74. core/drivers.h \
  75. core/workers.h \
  76. core/topology.h \
  77. core/debug.h \
  78. core/errorcheck.h \
  79. core/combined_workers.h \
  80. core/simgrid.h \
  81. core/task_bundle.h \
  82. core/detect_combined_workers.h \
  83. sched_policies/helper_mct.h \
  84. sched_policies/fifo_queues.h \
  85. datawizard/footprint.h \
  86. datawizard/datawizard.h \
  87. datawizard/data_request.h \
  88. datawizard/filters.h \
  89. datawizard/write_back.h \
  90. datawizard/datastats.h \
  91. datawizard/malloc.h \
  92. datawizard/memstats.h \
  93. datawizard/memory_manager.h \
  94. datawizard/memalloc.h \
  95. datawizard/copy_driver.h \
  96. datawizard/coherency.h \
  97. datawizard/sort_data_handles.h \
  98. datawizard/memory_nodes.h \
  99. datawizard/interfaces/data_interface.h \
  100. common/barrier.h \
  101. common/timing.h \
  102. common/list.h \
  103. common/rwlock.h \
  104. common/starpu_spinlock.h \
  105. common/fxt.h \
  106. common/utils.h \
  107. common/thread.h \
  108. common/barrier.h \
  109. common/uthash.h \
  110. common/barrier_counter.h \
  111. common/rbtree.h \
  112. common/rbtree_i.h \
  113. common/prio_list.h \
  114. common/graph.h \
  115. drivers/driver_common/driver_common.h \
  116. drivers/mp_common/mp_common.h \
  117. drivers/mp_common/source_common.h \
  118. drivers/mp_common/sink_common.h \
  119. drivers/cpu/driver_cpu.h \
  120. drivers/cuda/driver_cuda.h \
  121. drivers/opencl/driver_opencl.h \
  122. drivers/opencl/driver_opencl_utils.h \
  123. debug/starpu_debug_helpers.h \
  124. drivers/mic/driver_mic_common.h \
  125. drivers/mic/driver_mic_source.h \
  126. drivers/mic/driver_mic_sink.h \
  127. drivers/scc/driver_scc_common.h \
  128. drivers/scc/driver_scc_source.h \
  129. drivers/scc/driver_scc_sink.h \
  130. drivers/mpi/driver_mpi_common.h \
  131. drivers/mpi/driver_mpi_source.h \
  132. drivers/mpi/driver_mpi_sink.h \
  133. drivers/disk/driver_disk.h \
  134. debug/traces/starpu_fxt.h \
  135. profiling/bound.h \
  136. profiling/profiling.h \
  137. util/openmp_runtime_support.h \
  138. util/starpu_clusters_create.h \
  139. util/starpu_task_insert_utils.h \
  140. util/starpu_data_cpy.h \
  141. starpu_parameters.h \
  142. top/starpu_top_message_queue.h \
  143. top/starpu_top_connection.h \
  144. top/starpu_top_core.h \
  145. sched_policies/prio_deque.h \
  146. sched_policies/sched_component.h
  147. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES = \
  148. common/barrier.c \
  149. common/barrier_counter.c \
  150. common/bitmap.c \
  151. common/hash.c \
  152. common/rwlock.c \
  153. common/starpu_spinlock.c \
  154. common/timing.c \
  155. common/fxt.c \
  156. common/utils.c \
  157. common/thread.c \
  158. common/rbtree.c \
  159. common/graph.c \
  160. common/inlines.c \
  161. core/jobs.c \
  162. core/task.c \
  163. core/task_bundle.c \
  164. core/tree.c \
  165. core/drivers.c \
  166. core/workers.c \
  167. core/combined_workers.c \
  168. core/topology.c \
  169. core/disk.c \
  170. core/debug.c \
  171. core/errorcheck.c \
  172. core/progress_hook.c \
  173. core/idle_hook.c \
  174. core/dependencies/cg.c \
  175. core/dependencies/dependencies.c \
  176. core/dependencies/implicit_data_deps.c \
  177. core/dependencies/tags.c \
  178. core/dependencies/task_deps.c \
  179. core/dependencies/data_concurrency.c \
  180. core/dependencies/data_arbiter_concurrency.c \
  181. core/disk_ops/disk_stdio.c \
  182. core/disk_ops/disk_unistd.c \
  183. core/disk_ops/unistd/disk_unistd_global.c \
  184. core/perfmodel/perfmodel_history.c \
  185. core/perfmodel/perfmodel_bus.c \
  186. core/perfmodel/perfmodel.c \
  187. core/perfmodel/perfmodel_print.c \
  188. core/perfmodel/perfmodel_nan.c \
  189. core/perfmodel/regression.c \
  190. core/perfmodel/multiple_regression.c \
  191. core/sched_policy.c \
  192. core/simgrid.c \
  193. core/simgrid_cpp.cpp \
  194. core/sched_ctx.c \
  195. core/sched_ctx_list.c \
  196. core/parallel_task.c \
  197. core/detect_combined_workers.c \
  198. sched_policies/eager_central_policy.c \
  199. sched_policies/eager_central_priority_policy.c \
  200. sched_policies/work_stealing_policy.c \
  201. sched_policies/deque_modeling_policy_data_aware.c \
  202. sched_policies/random_policy.c \
  203. sched_policies/fifo_queues.c \
  204. sched_policies/parallel_heft.c \
  205. sched_policies/parallel_eager.c \
  206. sched_policies/heteroprio.c \
  207. sched_policies/graph_test_policy.c \
  208. drivers/driver_common/driver_common.c \
  209. drivers/disk/driver_disk.c \
  210. datawizard/memory_nodes.c \
  211. datawizard/write_back.c \
  212. datawizard/coherency.c \
  213. datawizard/data_request.c \
  214. datawizard/datawizard.c \
  215. datawizard/copy_driver.c \
  216. datawizard/filters.c \
  217. datawizard/sort_data_handles.c \
  218. datawizard/malloc.c \
  219. datawizard/memory_manager.c \
  220. datawizard/memalloc.c \
  221. datawizard/memstats.c \
  222. datawizard/footprint.c \
  223. datawizard/datastats.c \
  224. datawizard/user_interactions.c \
  225. datawizard/reduction.c \
  226. datawizard/interfaces/data_interface.c \
  227. datawizard/interfaces/bcsr_interface.c \
  228. datawizard/interfaces/coo_interface.c \
  229. datawizard/interfaces/csr_interface.c \
  230. datawizard/interfaces/matrix_filters.c \
  231. datawizard/interfaces/matrix_interface.c \
  232. datawizard/interfaces/block_filters.c \
  233. datawizard/interfaces/block_interface.c \
  234. datawizard/interfaces/vector_interface.c \
  235. datawizard/interfaces/bcsr_filters.c \
  236. datawizard/interfaces/csr_filters.c \
  237. datawizard/interfaces/vector_filters.c \
  238. datawizard/interfaces/variable_interface.c \
  239. datawizard/interfaces/void_interface.c \
  240. datawizard/interfaces/multiformat_interface.c \
  241. util/execute_on_all.c \
  242. util/starpu_create_sync_task.c \
  243. util/file.c \
  244. util/fstarpu.c \
  245. util/misc.c \
  246. util/openmp_runtime_support.c \
  247. util/openmp_runtime_support_environment.c \
  248. util/openmp_runtime_support_omp_api.c \
  249. util/starpu_data_cpy.c \
  250. util/starpu_task_insert.c \
  251. util/starpu_task_insert_utils.c \
  252. debug/traces/starpu_fxt.c \
  253. debug/traces/starpu_fxt_mpi.c \
  254. debug/traces/starpu_fxt_dag.c \
  255. debug/traces/starpu_paje.c \
  256. debug/traces/anim.c \
  257. debug/latency.c \
  258. debug/structures_size.c \
  259. profiling/profiling.c \
  260. profiling/bound.c \
  261. profiling/profiling_helpers.c \
  262. top/starpu_top.c \
  263. top/starpu_top_task.c \
  264. top/starpu_top_message_queue.c \
  265. top/starpu_top_connection.c \
  266. worker_collection/worker_list.c \
  267. worker_collection/worker_tree.c \
  268. sched_policies/component_worker.c \
  269. sched_policies/component_sched.c \
  270. sched_policies/component_fifo.c \
  271. sched_policies/prio_deque.c \
  272. sched_policies/helper_mct.c \
  273. sched_policies/component_prio.c \
  274. sched_policies/component_random.c \
  275. sched_policies/component_eager.c \
  276. sched_policies/component_eager_calibration.c \
  277. sched_policies/component_mct.c \
  278. sched_policies/component_heft.c \
  279. sched_policies/component_best_implementation.c \
  280. sched_policies/component_perfmodel_select.c \
  281. sched_policies/component_composed.c \
  282. sched_policies/component_work_stealing.c \
  283. sched_policies/modular_eager.c \
  284. sched_policies/modular_eager_prefetching.c \
  285. sched_policies/modular_gemm.c \
  286. sched_policies/modular_prio.c \
  287. sched_policies/modular_prio_prefetching.c \
  288. sched_policies/modular_random.c \
  289. sched_policies/modular_parallel_random.c \
  290. sched_policies/modular_random_prefetching.c \
  291. sched_policies/modular_parallel_heft.c \
  292. sched_policies/modular_heft.c \
  293. sched_policies/modular_heft_prio.c \
  294. sched_policies/modular_heft2.c \
  295. sched_policies/modular_ws.c \
  296. sched_policies/modular_ez.c
  297. if STARPU_HAVE_LEVELDB
  298. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += core/disk_ops/disk_leveldb.cpp
  299. endif
  300. if STARPU_HAVE_HDF5
  301. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += core/disk_ops/disk_hdf5.c
  302. endif
  303. if STARPU_USE_CPU
  304. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/cpu/driver_cpu.c
  305. endif
  306. if STARPU_USE_CUDA
  307. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/cuda/driver_cuda.c
  308. else
  309. if STARPU_SIMGRID
  310. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/cuda/driver_cuda.c
  311. endif
  312. endif
  313. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/cuda/starpu_cublas.c
  314. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/cuda/starpu_cusparse.c
  315. if STARPU_USE_OPENCL
  316. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/opencl/driver_opencl.c
  317. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/opencl/driver_opencl_utils.c
  318. else
  319. if STARPU_SIMGRID
  320. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/opencl/driver_opencl.c
  321. endif
  322. endif
  323. if STARPU_USE_SCC
  324. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/scc/driver_scc_common.c
  325. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/scc/driver_scc_source.c
  326. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/scc/driver_scc_sink.c
  327. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/scc/driver_scc_utils.c
  328. endif
  329. if STARPU_LINUX_SYS
  330. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += core/disk_ops/disk_unistd_o_direct.c
  331. endif
  332. if STARPU_HAVE_HWLOC
  333. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += \
  334. sched_policies/scheduler_maker.c \
  335. sched_policies/hierarchical_heft.c
  336. if STARPU_HWLOC_HAVE_TOPOLOGY_DUP
  337. if STARPU_HAVE_OPENMP
  338. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += util/starpu_clusters_create.c
  339. endif
  340. endif
  341. endif
  342. #########################################
  343. # #
  344. # Generic MP compilation #
  345. # #
  346. #########################################
  347. if STARPU_USE_MP
  348. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mp_common/mp_common.c
  349. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mp_common/source_common.c
  350. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mp_common/sink_common.c
  351. endif
  352. #########################################
  353. # #
  354. # MIC compilation #
  355. # #
  356. #########################################
  357. if STARPU_USE_MIC
  358. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mic/driver_mic_common.c
  359. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mic/driver_mic_source.c
  360. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mic/driver_mic_sink.c
  361. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mic/driver_mic_utils.c
  362. endif
  363. #########################################
  364. # #
  365. # MPI Master/Slave compilation #
  366. # #
  367. #########################################
  368. if STARPU_USE_MPI_MASTER_SLAVE
  369. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mpi/driver_mpi_common.c
  370. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mpi/driver_mpi_source.c
  371. libstarpu_@STARPU_EFFECTIVE_VERSION@_la_SOURCES += drivers/mpi/driver_mpi_sink.c
  372. endif
  373. #########################################
  374. # If some external references appear (U), it means the corresponding .c file has
  375. # only included <starpu.h> and not the internal src/ header which contains the
  376. # static inline definition
  377. dist-hook:
  378. failed=0 ; \
  379. for i in $$( $(GREP) "static inline" $$(find $(srcdir) -name \*.h) | $(SED) -e 's/.*static inline //g' | $(GREP) -v ENAME | $(SED) -e 's/[^(]* \(\|\*\)\([^ (]*\)(.*/\2/' | $(GREP) -v _starpu_spin_init) ; do \
  380. for j in .libs/*.o ; do \
  381. nm $$j | $(GREP) "U $$i$$" && { echo $$j ; failed=1 ; } ; \
  382. done ; \
  383. done ; \
  384. [ $$failed == 0 ]
  385. showcheck:
  386. -cat /dev/null
  387. showsuite:
  388. -cat /dev/null