Просмотр исходного кода

include: remove documentation as it is already defined elsewhere

Nathalie Furmento лет назад: 12
Родитель
Сommit
3bea1e3e51
4 измененных файлов с 1 добавлено и 82 удалено
  1. 1 26
      include/starpu.h
  2. 0 21
      include/starpu_data_interfaces.h
  3. 0 9
      include/starpu_hash.h
  4. 0 26
      include/starpu_worker.h

+ 1 - 26
include/starpu.h

@@ -79,18 +79,13 @@ extern "C"
 
 struct starpu_conf
 {
-	/* Will be initialized by starpu_conf_init */
 	int magic;
-
-	/* which scheduling policy should be used ? (NULL for default) */
 	const char *sched_policy_name;
+
 	struct starpu_sched_policy *sched_policy;
 
-	/* number of CPU workers (-1 for default) */
 	int ncpus;
-	/* number of CUDA GPU workers (-1 for default) */
 	int ncuda;
-	/* number of GPU OpenCL device workers (-1 for default) */
 	int nopencl;
 	/* number of MIC device workers (-1 for default) */
 	int nmic;
@@ -112,49 +107,32 @@ struct starpu_conf
 	unsigned use_explicit_workers_scc_deviceid;
 	unsigned workers_scc_deviceid[STARPU_NMAXWORKERS];
 
-	/* calibrate bus (-1 for default) */
 	int bus_calibrate;
-
-	/* calibrate performance models, if any (-1 for default) */
 	int calibrate;
 
-	/* Create only one combined worker, containing all CPU workers */
 	int single_combined_worker;
 
 	/* Path to the kernel to execute on the MIC device, compiled
 	 * for MIC architecture. */
 	char *mic_sink_program_path;
 
-	/* indicate if all asynchronous copies should be disabled */
 	int disable_asynchronous_copy;
-
-	/* indicate if asynchronous copies to CUDA devices should be disabled */
 	int disable_asynchronous_cuda_copy;
-
-	/* indicate if asynchronous copies to OpenCL devices should be disabled */
 	int disable_asynchronous_opencl_copy;
-
 	/* indicate if asynchronous copies to MIC devices should be disabled */
 	int disable_asynchronous_mic_copy;
 
-	/* Enable CUDA/OpenGL interoperation on these CUDA devices */
 	unsigned *cuda_opengl_interoperability;
 	unsigned n_cuda_opengl_interoperability;
 
-	/* A driver that the application will run in one of its own threads. */
 	struct starpu_driver *not_launched_drivers;
 	unsigned n_not_launched_drivers;
 
-	/* Specifies the buffer size for tracing */
 	unsigned trace_buffer_size;
 };
 
-/* Initialize a starpu_conf structure with default values. */
 int starpu_conf_init(struct starpu_conf *conf);
 
-/* Initialization method: it must be called prior to any other StarPU call
- * Default configuration is used if NULL is passed as argument.
- */
 int starpu_init(struct starpu_conf *conf) STARPU_WARN_UNUSED_RESULT;
 
 /* Alternative initialization method with argc and argv. This is use by
@@ -163,11 +141,8 @@ int starpu_init(struct starpu_conf *conf) STARPU_WARN_UNUSED_RESULT;
  */
 int starpu_initialize(struct starpu_conf *user_conf, int *argc, char ***argv);
 
-/* Shutdown method: note that statistics are only generated once StarPU is
- * shutdown */
 void starpu_shutdown(void);
 
-/* Print topology configuration */
 void starpu_topology_print(FILE *f);
 
 int starpu_asynchronous_copy_disabled(void);

+ 0 - 21
include/starpu_data_interfaces.h

@@ -37,22 +37,17 @@ extern "C"
 
 /* The following structures are used to describe data interfaces */
 
-/* This structure contains the different methods to transfer data between the
- * different types of memory nodes */
 struct starpu_data_copy_methods
 {
-	/* src type is ram */
 	int (*ram_to_ram)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*ram_to_cuda)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*ram_to_opencl)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*ram_to_mic)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 
-	/* src type is cuda */
 	int (*cuda_to_ram)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*cuda_to_cuda)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*cuda_to_opencl)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 
-	/* src type is opencl */
 	int (*opencl_to_ram)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*opencl_to_cuda)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 	int (*opencl_to_opencl)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
@@ -66,7 +61,6 @@ struct starpu_data_copy_methods
 	int (*scc_sink_to_sink)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node);
 
 #ifdef STARPU_USE_CUDA
-	/* for asynchronous CUDA transfers */
 	int (*ram_to_cuda_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cudaStream_t stream);
 	int (*cuda_to_ram_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cudaStream_t stream);
 	int (*cuda_to_cuda_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cudaStream_t stream);
@@ -77,7 +71,6 @@ struct starpu_data_copy_methods
 #endif
 
 #if defined(STARPU_USE_OPENCL) && !defined(__CUDACC__)
-	/* for asynchronous OpenCL transfers */
 	int (*ram_to_opencl_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cl_event *event);
 	int (*opencl_to_ram_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cl_event *event);
 	int (*opencl_to_opencl_async)(void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, cl_event *event);
@@ -115,36 +108,23 @@ enum starpu_data_interface_id
 
 struct starpu_data_interface_ops
 {
-	/* Register an existing interface into a data handle. */
 	void (*register_data_handle)(starpu_data_handle_t handle,
 				     unsigned home_node, void *data_interface);
-	/* Allocate data for the interface on a given node. */
 	starpu_ssize_t (*allocate_data_on_node)(void *data_interface, unsigned node);
-	/* Free data of the interface on a given node. */
 	void (*free_data_on_node)(void *data_interface, unsigned node);
-	/* ram/cuda/opencl synchronous and asynchronous transfer methods */
 	const struct starpu_data_copy_methods *copy_methods;
-	/* Return the current pointer (if any) for the handle on the given node. */
 	void * (*handle_to_pointer)(starpu_data_handle_t handle, unsigned node);
-	/* Return an estimation of the size of data, for performance models */
 	size_t (*get_size)(starpu_data_handle_t handle);
-	/* Return a 32bit footprint which characterizes the data size */
 	uint32_t (*footprint)(starpu_data_handle_t handle);
-	/* Compare the data size of two interfaces */
 	int (*compare)(void *data_interface_a, void *data_interface_b);
-	/* Dump the sizes of a handle to a file */
 	void (*display)(starpu_data_handle_t handle, FILE *f);
-	/* an identifier that is unique to each interface */
 	enum starpu_data_interface_id interfaceid;
-	/* The size of the interface data descriptor */
 	size_t interface_size;
 
 	int is_multiformat;
 	struct starpu_multiformat_data_interface_ops* (*get_mf_ops)(void *data_interface);
 
-	/* Pack the data handle into a contiguous buffer at the address ptr and store the size of the buffer in count */
 	int (*pack_data)(starpu_data_handle_t handle, unsigned node, void **ptr, starpu_ssize_t *count);
-	/* Unpack the data handle from the contiguous buffer at the address ptr */
 	int (*unpack_data)(starpu_data_handle_t handle, unsigned node, void *ptr, size_t count);
 };
 
@@ -281,7 +261,6 @@ size_t starpu_block_get_elemsize(starpu_data_handle_t handle);
 #define STARPU_BLOCK_GET_LDZ(interface)	(((struct starpu_block_interface *)(interface))->ldz)
 #define STARPU_BLOCK_GET_ELEMSIZE(interface)	(((struct starpu_block_interface *)(interface))->elemsize)
 
-/* vector interface for contiguous (non-strided) buffers */
 struct starpu_vector_interface
 {
 	enum starpu_data_interface_id id;

+ 0 - 9
include/starpu_hash.h

@@ -26,19 +26,10 @@ extern "C"
 {
 #endif
 
-/* Compute the CRC of a byte buffer seeded by the inputcrc "current state".
- * The return value should be considered as the new "current state" for future
- * CRC computation. */
 uint32_t starpu_hash_crc32c_be_n(const void *input, size_t n, uint32_t inputcrc);
 
-/* Compute the CRC of a 32bit number seeded by the inputcrc "current state".
- * The return value should be considered as the new "current state" for future
- * CRC computation. */
 uint32_t starpu_hash_crc32c_be(uint32_t input, uint32_t inputcrc);
 
-/* Compute the CRC of a string seeded by the inputcrc "current state".  The
- * return value should be considered as the new "current state" for future CRC
- * computation. */
 uint32_t starpu_hash_crc32c_string(const char *str, uint32_t inputcrc);
 
 #ifdef __cplusplus

+ 0 - 26
include/starpu_worker.h

@@ -100,42 +100,16 @@ int starpu_combined_worker_get_id(void);
 int starpu_combined_worker_get_size(void);
 int starpu_combined_worker_get_rank(void);
 
-/* This function returns the type of worker associated to an identifier (as
- * returned by the starpu_worker_get_id function). The returned value indicates
- * the architecture of the worker: STARPU_CPU_WORKER for a CPU core,
- * STARPU_CUDA_WORKER for a CUDA device. The value returned for an
- * invalid identifier is unspecified.  */
 enum starpu_worker_archtype starpu_worker_get_type(int id);
 
-/* Returns the number of workers of the type indicated by the argument. A
- * positive (or null) value is returned in case of success, -EINVAL indicates
- * that the type is not valid otherwise. */
 int starpu_worker_get_count_by_type(enum starpu_worker_archtype type);
 
-/* Fill the workerids array with the identifiers of the workers that have the
- * type indicated in the first argument. The maxsize argument indicates the
- * size of the workids array. The returned value gives the number of
- * identifiers that were put in the array. -ERANGE is returned is maxsize is
- * lower than the number of workers with the appropriate type: in that case,
- * the array is filled with the maxsize first elements. To avoid such
- * overflows, the value of maxsize can be chosen by the means of the
- * starpu_worker_get_count_by_type function, or by passing a value greater or
- * equal to STARPU_NMAXWORKERS. */
 int starpu_worker_get_ids_by_type(enum starpu_worker_archtype type, int *workerids, int maxsize);
 
-/* Return the identifier of the n-th worker of a specific type */
 int starpu_worker_get_by_type(enum starpu_worker_archtype type, int num);
 
-/* Return the identifier of the worker devid of a specific type */
 int starpu_worker_get_by_devid(enum starpu_worker_archtype type, int devid);
 
-/* StarPU associates a unique human readable string to each processing unit.
- * This function copies at most the "maxlen" first bytes of the unique
- * string associated to a worker identified by its identifier "id" into
- * the "dst" buffer. The caller is responsible for ensuring that the
- * "dst" is a valid pointer to a buffer of "maxlen" bytes at least.
- * Calling this function on an invalid identifier results in an unspecified
- * behaviour. */
 void starpu_worker_get_name(int id, char *dst, size_t maxlen);
 
 /* This functions returns the device id of the worker associated to an