Browse Source

tests/datawizard/interfaces/multiformat/advanced/multiformat_handle_conversion.c: tests/datawizard/interfaces/multiformat/advanced/multiformat_data_release.c: define code only when needed

Nathalie Furmento 13 years ago
parent
commit
2635220533

+ 2 - 0
tests/datawizard/interfaces/multiformat/advanced/multiformat_data_release.c

@@ -43,6 +43,7 @@ unregister_handle(void)
 	starpu_data_unregister(handle);
 }
 
+#if defined(STARPU_USE_CUDA) || defined(STARPU_USE_OPENCL)
 static void
 create_and_submit(int where)
 {
@@ -68,6 +69,7 @@ create_and_submit(int where)
 	task->synchronous = 1;
 	starpu_task_submit(task);
 }
+#endif
 
 static int
 test(void)

+ 2 - 0
tests/datawizard/interfaces/multiformat/advanced/multiformat_handle_conversion.c

@@ -32,6 +32,7 @@
 
 extern struct stats global_stats;
 
+#if defined(STARPU_USE_CUDA) || defined(STARPU_USE_OPENCL)
 static void
 create_and_submit_tasks(int where, starpu_data_handle_t handles[])
 {
@@ -104,6 +105,7 @@ create_and_submit_tasks(int where, starpu_data_handle_t handles[])
 	FPRINTF(stderr, "***** End of all tasks\n");
 	return;
 }
+#endif
 
 /* XXX Just a little bit of copy/pasta here... */
 #ifdef STARPU_USE_CUDA