Browse Source

move definition of union _starpu_interface from include/starpu_data_interfaces.h to src/datawizard/interfaces/data_interface.h

Nathalie Furmento 12 years ago
parent
commit
2c41b7e0b9

+ 0 - 15
include/starpu_data_interfaces.h

@@ -461,21 +461,6 @@ void starpu_multiformat_data_register(starpu_data_handle_t *handle, unsigned hom
 #define STARPU_MULTIFORMAT_GET_MIC_PTR(interface) (((struct starpu_multiformat_interface *)(interface))->mic_ptr)
 #define STARPU_MULTIFORMAT_GET_NX(interface)  (((struct starpu_multiformat_interface *)(interface))->nx)
 
-/* Generic type representing an interface, for now it's only used before
- * execution on message-passing devices but it can be useful in other cases.
- */
-union _starpu_interface
-{
-	struct starpu_matrix_interface matrix;
-	struct starpu_block_interface block;
-	struct starpu_vector_interface vector;
-	struct starpu_csr_interface csr;
-	struct starpu_coo_interface coo;
-	struct starpu_bcsr_interface bcsr;
-	struct starpu_variable_interface variable;
-	struct starpu_multiformat_interface multiformat;
-};
-
 enum starpu_data_interface_id starpu_data_get_interface_id(starpu_data_handle_t handle);
 
 int starpu_data_pack(starpu_data_handle_t handle, void **ptr, starpu_ssize_t *count);

+ 16 - 1
src/datawizard/interfaces/data_interface.h

@@ -1,7 +1,7 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  * Copyright (C) 2009-2012  Université de Bordeaux 1
- * Copyright (C) 2010, 2012  Centre National de la Recherche Scientifique
+ * Copyright (C) 2010, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
  * it under the terms of the GNU Lesser General Public License as published by
@@ -21,6 +21,21 @@
 #include <starpu.h>
 #include <common/config.h>
 
+/* Generic type representing an interface, for now it's only used before
+ * execution on message-passing devices but it can be useful in other cases.
+ */
+union _starpu_interface
+{
+	struct starpu_matrix_interface matrix;
+	struct starpu_block_interface block;
+	struct starpu_vector_interface vector;
+	struct starpu_csr_interface csr;
+	struct starpu_coo_interface coo;
+	struct starpu_bcsr_interface bcsr;
+	struct starpu_variable_interface variable;
+	struct starpu_multiformat_interface multiformat;
+};
+
 /* Some data interfaces or filters use this interface internally */
 extern struct starpu_data_interface_ops starpu_interface_matrix_ops;
 extern struct starpu_data_interface_ops starpu_interface_block_ops;

+ 1 - 0
src/drivers/mp_common/mp_common.c

@@ -17,6 +17,7 @@
 #include <stdlib.h>
 #include <pthread.h>
 
+#include <datawizard/interfaces/data_interface.h>
 #include <drivers/mp_common/mp_common.h>
 #include <drivers/mp_common/sink_common.h>
 #include <drivers/mic/driver_mic_common.h>

+ 1 - 0
src/drivers/mp_common/source_common.c

@@ -20,6 +20,7 @@
 
 #include <starpu.h>
 #include <datawizard/coherency.h>
+#include <datawizard/interfaces/data_interface.h>
 #include <drivers/mp_common/mp_common.h>
 
 int

+ 1 - 0
src/drivers/scc/driver_scc_sink.c

@@ -17,6 +17,7 @@
 
 #include <RCCE.h>
 
+#include <datawizard/interfaces/data_interface.h>
 #include <drivers/mp_common/sink_common.h>
 #include <drivers/scc/driver_scc_common.h>
 #include <drivers/scc/driver_scc_sink.h>