Kaynağa Gözat

src: let's make icc even happier

Nathalie Furmento 13 yıl önce
ebeveyn
işleme
e5083419c7

+ 3 - 3
src/core/perfmodel/perfmodel.c

@@ -225,7 +225,7 @@ double starpu_task_expected_conversion_time(struct starpu_task *task,
 	unsigned i;
 	int err;
 	double sum = 0.0;
-	unsigned int node, cpu_node, cuda_node, opencl_node;
+	unsigned int node, cpu_node;
 
 	/* We need to get one node per archtype. This is kinda ugly,
 	 * but it does the job.
@@ -241,7 +241,7 @@ double starpu_task_expected_conversion_time(struct starpu_task *task,
 	cpu_node = starpu_worker_get_memory_node(cpu_worker);
 #endif
 #ifdef STARPU_USE_CUDA
-	int cuda_worker;
+	int cuda_worker, cuda_node;
 	err = starpu_worker_get_ids_by_type(STARPU_CUDA_WORKER,
 					    &cuda_worker, 1);
 	if (err != 1 && err != -ERANGE)
@@ -249,7 +249,7 @@ double starpu_task_expected_conversion_time(struct starpu_task *task,
 	cuda_node = starpu_worker_get_memory_node(cuda_worker);
 #endif
 #ifdef STARPU_USE_OPENCL
-	int opencl_worker;
+	int opencl_worker, opencl_node;
 	err = starpu_worker_get_ids_by_type(STARPU_OPENCL_WORKER,
 					    &opencl_worker, 1);
 	if (err != 1 && err != -ERANGE)

+ 1 - 1
src/core/sched_policy.c

@@ -376,7 +376,7 @@ struct starpu_task *_starpu_create_conversion_task(starpu_data_handle_t handle,
 			break;
 #endif
 		default:
-			fprintf(stderr, "Oops : %d\n", handle->mf_node);
+			fprintf(stderr, "Oops : %u\n", handle->mf_node);
 			STARPU_ASSERT(0);
 		}
 		break;

+ 1 - 1
src/core/task.c

@@ -311,7 +311,7 @@ void _starpu_task_check_deprecated_fields(struct starpu_task *task)
 		{
 			if (task->buffers[i].handle && task->handles[i])
 			{
-				fprintf(stderr, "[warning][struct starpu_task] task->buffers[%d] and task->handles[%d] both set. Ignoring task->buffers[%d] ?\n", i, i, i);
+				fprintf(stderr, "[warning][struct starpu_task] task->buffers[%u] and task->handles[%u] both set. Ignoring task->buffers[%u] ?\n", i, i, i);
 				STARPU_ASSERT(task->buffers[i].mode == task->cl->modes[i]);
 				STARPU_ABORT();
 			}

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

@@ -25,6 +25,7 @@
 #include <drivers/driver_common/driver_common.h>
 #include <starpu_top.h>
 #include <core/sched_policy.h>
+#include <top/starpu_top_core.h>
 
 void _starpu_driver_start_job(struct _starpu_worker *args, struct _starpu_job *j, struct timespec *codelet_start, int rank)
 {

+ 2 - 2
src/drivers/opencl/driver_opencl.c

@@ -2,7 +2,7 @@
  *
  * Copyright (C) 2010, 2011  Université de Bordeaux 1
  * Copyright (C) 2010  Mehdi Juhoor <mjuhoor@gmail.com>
- * Copyright (C) 2010, 2011  Centre National de la Recherche Scientifique
+ * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  * Copyright (C) 2011  Télécom-SudParis
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -408,7 +408,7 @@ void _starpu_opencl_init(void)
 
 		if (nb_devices > STARPU_MAXOPENCLDEVS)
 		{
-			_STARPU_DISP("# Warning: %d OpenCL devices available. Only %d enabled. Use configure option --enable-maxopencldev=xxx to update the maximum value of supported OpenCL devices?\n", nb_devices, STARPU_MAXOPENCLDEVS);
+			_STARPU_DISP("# Warning: %u OpenCL devices available. Only %d enabled. Use configure option --enable-maxopencldev=xxx to update the maximum value of supported OpenCL devices?\n", nb_devices, STARPU_MAXOPENCLDEVS);
 			nb_devices = STARPU_MAXOPENCLDEVS;
 		}
 

+ 2 - 1
src/sched_policies/detect_combined_workers.c

@@ -1,7 +1,7 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  * Copyright (C) 2010-2011  Université de Bordeaux 1
- * Copyright (C) 2011       Centre National de la Recherche Scientifique
+ * Copyright (C) 2011, 2012       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
@@ -20,6 +20,7 @@
 #include <common/utils.h>
 #include <core/workers.h>
 #include <math.h>
+#include <sched_policies/detect_combined_workers.h>
 
 #ifdef STARPU_HAVE_HWLOC
 #include <hwloc.h>

+ 1 - 0
src/sched_policies/heft.c

@@ -27,6 +27,7 @@
 #include <starpu_task_bundle.h>
 #include <starpu_top.h>
 #include <core/jobs.h>
+#include <top/starpu_top_core.h>
 
 static unsigned nworkers;
 

+ 3 - 1
src/top/starpu_top.c

@@ -1,7 +1,7 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
  * Copyright (C) 2011 William Braik, Yann Courtois, Jean-Marie Couteyen, Anthony Roy
- * Copyright (C) 2011 Centre National de la Recherche Scientifique
+ * Copyright (C) 2011, 2012 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
@@ -61,6 +61,7 @@ char *message_for_topparam_init(struct starpu_top_param* param);
  * we store data and param in a tab to offer a O(1) access when the program  is
  * running
  */
+static
 void copy_data_and_param()
 {
 	printf("%s:%d trace\n", __FILE__, __LINE__);
@@ -208,6 +209,7 @@ void starpu_top_init_and_wait(const char* server_name)
 	sem_wait(&starpu_top_wait_for_go);
 }
 
+static
 void starpu_top_enqueue_data(struct starpu_top_data * data)
 {
 	if(starpu_top_first_data == NULL)

+ 3 - 0
src/util/malloc.c

@@ -20,6 +20,7 @@
 #include <core/workers.h>
 #include <common/config.h>
 #include <starpu.h>
+#include <starpu_data.h>
 #include <starpu_cuda.h>
 #include <drivers/opencl/driver_opencl.h>
 
@@ -238,9 +239,11 @@ int starpu_free(void *A)
 	return 0;
 }
 
+#ifdef STARPU_GCC_PLUGIN
 /* Internal convenience function, used by code generated by the GCC
  * plug-in.  */
 void _starpu_free_unref(void *p)
 {
 	(void)starpu_free(* (void **)p);
 }
+#endif