|
@@ -1,7 +1,7 @@
|
|
|
/* StarPU --- Runtime system for heterogeneous multicore architectures.
|
|
|
*
|
|
|
* Copyright (C) 2011,2012,2014-2017,2019 Inria
|
|
|
- * Copyright (C) 2010-2019 Université de Bordeaux
|
|
|
+ * Copyright (C) 2010-2020 Université de Bordeaux
|
|
|
* Copyright (C) 2010 Mehdi Juhoor
|
|
|
* Copyright (C) 2010-2017,2019 CNRS
|
|
|
* Copyright (C) 2013 Thibaut Lambert
|
|
@@ -1153,7 +1153,7 @@ void _starpu_opencl_wait_request_completion(struct _starpu_async_channel *async_
|
|
|
STARPU_OPENCL_REPORT_ERROR(err);
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_data_from_opencl_to_opencl(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
+int _starpu_opencl_copy_interface_from_opencl_to_opencl(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1186,7 +1186,7 @@ int _starpu_opencl_copy_data_from_opencl_to_opencl(starpu_data_handle_t handle,
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_data_from_opencl_to_cpu(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
+int _starpu_opencl_copy_interface_from_opencl_to_cpu(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1219,7 +1219,7 @@ int _starpu_opencl_copy_data_from_opencl_to_cpu(starpu_data_handle_t handle, voi
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_data_from_cpu_to_opencl(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
+int _starpu_opencl_copy_interface_from_cpu_to_opencl(starpu_data_handle_t handle, void *src_interface, unsigned src_node, void *dst_interface, unsigned dst_node, struct _starpu_data_request *req)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1252,7 +1252,7 @@ int _starpu_opencl_copy_data_from_cpu_to_opencl(starpu_data_handle_t handle, voi
|
|
|
return ret;
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_interface_from_opencl_to_opencl(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
+int _starpu_opencl_copy_data_from_opencl_to_opencl(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1264,7 +1264,7 @@ int _starpu_opencl_copy_interface_from_opencl_to_opencl(uintptr_t src, size_t sr
|
|
|
&async_channel->event.opencl_event);
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_interface_from_opencl_to_cpu(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
+int _starpu_opencl_copy_data_from_opencl_to_cpu(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1276,7 +1276,7 @@ int _starpu_opencl_copy_interface_from_opencl_to_cpu(uintptr_t src, size_t src_o
|
|
|
&async_channel->event.opencl_event);
|
|
|
}
|
|
|
|
|
|
-int _starpu_opencl_copy_interface_from_cpu_to_opencl(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
+int _starpu_opencl_copy_data_from_cpu_to_opencl(uintptr_t src, size_t src_offset, unsigned src_node, uintptr_t dst, size_t dst_offset, unsigned dst_node, size_t size, struct _starpu_async_channel *async_channel)
|
|
|
{
|
|
|
int src_kind = starpu_node_get_kind(src_node);
|
|
|
int dst_kind = starpu_node_get_kind(dst_node);
|
|
@@ -1352,14 +1352,6 @@ int _starpu_opencl_is_direct_access_supported(unsigned node, unsigned handling_n
|
|
|
#ifdef STARPU_SIMGRID
|
|
|
struct _starpu_node_ops _starpu_driver_opencl_node_ops =
|
|
|
{
|
|
|
- .copy_data_to[STARPU_UNUSED] = NULL,
|
|
|
- .copy_data_to[STARPU_CPU_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_CUDA_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_OPENCL_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_DISK_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_MIC_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
-
|
|
|
.copy_interface_to[STARPU_UNUSED] = NULL,
|
|
|
.copy_interface_to[STARPU_CPU_RAM] = NULL,
|
|
|
.copy_interface_to[STARPU_CUDA_RAM] = NULL,
|
|
@@ -1368,6 +1360,14 @@ struct _starpu_node_ops _starpu_driver_opencl_node_ops =
|
|
|
.copy_interface_to[STARPU_MIC_RAM] = NULL,
|
|
|
.copy_interface_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
|
|
|
+ .copy_data_to[STARPU_UNUSED] = NULL,
|
|
|
+ .copy_data_to[STARPU_CPU_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_CUDA_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_OPENCL_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_DISK_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_MIC_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
+
|
|
|
.wait_request_completion = NULL,
|
|
|
.test_request_completion = NULL,
|
|
|
.is_direct_access_supported = _starpu_opencl_is_direct_access_supported,
|
|
@@ -1378,14 +1378,6 @@ struct _starpu_node_ops _starpu_driver_opencl_node_ops =
|
|
|
#else
|
|
|
struct _starpu_node_ops _starpu_driver_opencl_node_ops =
|
|
|
{
|
|
|
- .copy_data_to[STARPU_UNUSED] = NULL,
|
|
|
- .copy_data_to[STARPU_CPU_RAM] = _starpu_opencl_copy_data_from_opencl_to_cpu,
|
|
|
- .copy_data_to[STARPU_CUDA_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_OPENCL_RAM] = _starpu_opencl_copy_data_from_opencl_to_opencl,
|
|
|
- .copy_data_to[STARPU_DISK_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_MIC_RAM] = NULL,
|
|
|
- .copy_data_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
-
|
|
|
.copy_interface_to[STARPU_UNUSED] = NULL,
|
|
|
.copy_interface_to[STARPU_CPU_RAM] = _starpu_opencl_copy_interface_from_opencl_to_cpu,
|
|
|
.copy_interface_to[STARPU_CUDA_RAM] = NULL,
|
|
@@ -1394,6 +1386,14 @@ struct _starpu_node_ops _starpu_driver_opencl_node_ops =
|
|
|
.copy_interface_to[STARPU_MIC_RAM] = NULL,
|
|
|
.copy_interface_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
|
|
|
+ .copy_data_to[STARPU_UNUSED] = NULL,
|
|
|
+ .copy_data_to[STARPU_CPU_RAM] = _starpu_opencl_copy_data_from_opencl_to_cpu,
|
|
|
+ .copy_data_to[STARPU_CUDA_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_OPENCL_RAM] = _starpu_opencl_copy_data_from_opencl_to_opencl,
|
|
|
+ .copy_data_to[STARPU_DISK_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_MIC_RAM] = NULL,
|
|
|
+ .copy_data_to[STARPU_MPI_MS_RAM] = NULL,
|
|
|
+
|
|
|
.wait_request_completion = _starpu_opencl_wait_request_completion,
|
|
|
.test_request_completion = _starpu_opencl_test_request_completion,
|
|
|
.is_direct_access_supported = _starpu_opencl_is_direct_access_supported,
|