| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 | /* * This file is part of the StarPU Handbook. * Copyright (C) 2009--2011  Universit@'e de Bordeaux * Copyright (C) 2010, 2011, 2012, 2013  CNRS * Copyright (C) 2011, 2012 INRIA * See the file version.doxy for copying conditions. *//*! \defgroup API_Task_Bundles Task Bundles\typedef starpu_task_bundle_t\ingroup API_Task_BundlesOpaque structure describing a list of tasks that should be scheduledon the same worker whenever it’s possible. It must be considered as ahint given to the scheduler as there is no guarantee that they will beexecuted on the same worker.\fn void starpu_task_bundle_create(starpu_task_bundle_t *bundle)\ingroup API_Task_BundlesFactory function creating and initializing \p bundle, when the callreturns, memory needed is allocated and \p bundle is ready to use.\fn int starpu_task_bundle_insert(starpu_task_bundle_t bundle, struct starpu_task *task)\ingroup API_Task_BundlesInsert \p task in \p bundle. Until \p task is removed from \p bundleits expected length and data transfer time will be considered alongthose of the other tasks of bundle. This function must not be calledif \p bundle is already closed and/or \p task is already submitted.On success, it returns 0. There are two cases of error : if \p bundleis already closed it returns <c>-EPERM</c>, if \p task was alreadysubmitted it returns <c>-EINVAL</c>.\fn int starpu_task_bundle_remove(starpu_task_bundle_t bundle, struct starpu_task *task)\ingroup API_Task_BundlesRemove \p task from \p bundle. Of course \p task must have beenpreviously inserted in \p bundle. This function must not be called if\p bundle is already closed and/or \p task is already submitted. Doingso would result in undefined behaviour. On success, it returns 0. If\p bundle is already closed it returns <c>-ENOENT</c>.\fn void starpu_task_bundle_close(starpu_task_bundle_t bundle)\ingroup API_Task_BundlesInform the runtime that the user will not modify \p bundle anymore, itmeans no more inserting or removing task. Thus the runtime can destroyit when possible.\fn double starpu_task_bundle_expected_length(starpu_task_bundle_t bundle, struct starpu_perfmodel_arch *arch, unsigned nimpl)\ingroup API_Task_BundlesReturn the expected duration of \p bundle in micro-seconds.\fn double starpu_task_bundle_expected_energy(starpu_task_bundle_t bundle, struct starpu_perfmodel_arch *arch, unsigned nimpl)\ingroup API_Task_BundlesReturn the expected energy consumption of \p bundle in J.\fn double starpu_task_bundle_expected_data_transfer_time(starpu_task_bundle_t bundle, unsigned memory_node)\ingroup API_Task_BundlesReturn the time (in micro-seconds) expected to transfer all data used within \p bundle.*/
 |