浏览代码

Add names to codelets

Samuel Thibault 12 年之前
父节点
当前提交
fbadd97f8c

+ 3 - 2
examples/axpy/axpy.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009-2012  Université de Bordeaux 1
+ * Copyright (C) 2009-2013  Université de Bordeaux 1
  * Copyright (C) 2010  Mehdi Juhoor <mjuhoor@gmail.com>
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
@@ -89,7 +89,8 @@ static struct starpu_codelet axpy_cl =
 	.opencl_funcs = {axpy_opencl, NULL},
 #endif
 	.nbuffers = 2,
-	.modes = {STARPU_R, STARPU_RW}
+	.modes = {STARPU_R, STARPU_RW},
+	.name = "axpy"
 };
 
 static int

+ 2 - 1
examples/basic_examples/variable.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2010, 2011  Université de Bordeaux 1
+ * Copyright (C) 2010, 2011, 2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -69,6 +69,7 @@ int main(int argc, char **argv)
         cl.nbuffers = 1;
 	cl.modes[0] = STARPU_RW;
         cl.model = NULL;
+	cl.name = "variable_inc";
 
 	for (i = 0; i < niter; i++)
 	{

+ 3 - 2
examples/callback/callback.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010, 2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -33,7 +33,8 @@ struct starpu_codelet cl =
 {
 	.modes = { STARPU_RW },
 	.cpu_funcs = {cpu_codelet, NULL},
-	.nbuffers = 1
+	.nbuffers = 1,
+	.name = "callback"
 };
 
 void callback_func(void *callback_arg)

+ 2 - 1
examples/cpp/incrementer_cpp.cpp

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010-2011  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010-2011, 2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  * Copyright (C) 2012 inria
  *
@@ -67,6 +67,7 @@ int main(int argc, char **argv)
 #endif
         cl.nbuffers = 1;
         cl.modes[0] = STARPU_RW;
+	cl.name = "incrementer";
 
 	for (i = 0; i < niter; i++)
 	{

+ 3 - 2
examples/filters/fblock.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2010-2011  Université de Bordeaux 1
+ * Copyright (C) 2010-2011, 2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -99,7 +99,8 @@ int main(int argc, char **argv)
                 .opencl_funcs = {opencl_func, NULL},
 #endif
 		.nbuffers = 1,
-                .modes = {STARPU_RW}
+                .modes = {STARPU_RW},
+		.name = "block_scal"
 	};
 
         ret = starpu_init(NULL);

+ 2 - 1
examples/filters/fmatrix.c

@@ -64,7 +64,8 @@ int main(int argc, char **argv)
 	{
                 .cpu_funcs = {cpu_func, NULL},
                 .nbuffers = 1,
-		.modes = {STARPU_RW}
+		.modes = {STARPU_RW},
+		.name = "matrix_scal"
         };
 
         ret = starpu_init(NULL);

+ 2 - 1
examples/filters/fvector.c

@@ -47,7 +47,8 @@ int main(int argc, char **argv)
 	{
                 .cpu_funcs = {cpu_func, NULL},
                 .nbuffers = 1,
-		.modes = {STARPU_RW}
+		.modes = {STARPU_RW},
+		.name = "vector_scal"
         };
 
         for(i=0 ; i<NX ; i++) vector[i] = i;

+ 3 - 2
examples/incrementer/incrementer.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010-2011  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010-2011, 2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -73,7 +73,8 @@ int main(int argc, char **argv)
 		.opencl_funcs = {opencl_codelet, NULL},
 #endif
 		.nbuffers = 1,
-		.modes = {STARPU_RW}
+		.modes = {STARPU_RW},
+		.name = "increment"
 	};
 
 	struct timeval start;

+ 3 - 2
examples/profiling/profiling.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2010-2012  Université de Bordeaux 1
+ * Copyright (C) 2010-2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -53,7 +53,8 @@ int main(int argc, char **argv)
 		.cpu_funcs = {sleep_codelet, NULL},
 		.cuda_funcs = {sleep_codelet, NULL},
 		.opencl_funcs = {sleep_codelet, NULL},
-		.nbuffers = 0
+		.nbuffers = 0,
+		.name = "sleep"
 	};
 
 	struct starpu_task **tasks = (struct starpu_task **) malloc(niter*sizeof(struct starpu_task *));

+ 6 - 3
examples/reductions/dot_product.c

@@ -115,7 +115,8 @@ static struct starpu_codelet init_codelet =
 	.opencl_funcs = {init_opencl_func, NULL},
 #endif
 	.modes = {STARPU_W},
-	.nbuffers = 1
+	.nbuffers = 1,
+	.name = "init",
 };
 
 /*
@@ -196,7 +197,8 @@ static struct starpu_codelet redux_codelet =
 	.opencl_funcs = {redux_opencl_func, NULL},
 #endif
 	.modes = {STARPU_RW, STARPU_R},
-	.nbuffers = 2
+	.nbuffers = 2,
+	.name = "redux"
 };
 
 /*
@@ -313,7 +315,8 @@ static struct starpu_codelet dot_codelet =
 	.opencl_funcs = {dot_opencl_func, NULL},
 #endif
 	.nbuffers = 3,
-	.modes = {STARPU_R, STARPU_R, STARPU_REDUX}
+	.modes = {STARPU_R, STARPU_R, STARPU_REDUX},
+	.name = "dot"
 };
 
 /*

+ 6 - 3
examples/reductions/minmax_reduction.c

@@ -59,7 +59,8 @@ static struct starpu_codelet minmax_init_codelet =
 {
 	.cpu_funcs = {minmax_neutral_cpu_func, NULL},
 	.modes = {STARPU_W},
-	.nbuffers = 1
+	.nbuffers = 1,
+	.name = "init"
 };
 
 /*
@@ -86,7 +87,8 @@ static struct starpu_codelet minmax_redux_codelet =
 {
 	.cpu_funcs = {minmax_redux_cpu_func, NULL},
 	.modes = {STARPU_RW, STARPU_R},
-	.nbuffers = 2
+	.nbuffers = 2,
+	.name = "redux"
 };
 
 /*
@@ -121,7 +123,8 @@ static struct starpu_codelet minmax_codelet =
 {
 	.cpu_funcs = {minmax_cpu_func, NULL},
 	.nbuffers = 2,
-	.modes = {STARPU_R, STARPU_REDUX}
+	.modes = {STARPU_R, STARPU_REDUX},
+	.name = "minmax"
 };
 
 /*

+ 2 - 1
examples/sched_ctx/sched_ctx.c

@@ -39,7 +39,8 @@ static struct starpu_codelet sched_ctx_codelet =
 	.cuda_funcs = {sched_ctx_func, NULL},
 	.opencl_funcs = {sched_ctx_func, NULL},
 	.model = NULL,
-	.nbuffers = 0
+	.nbuffers = 0,
+	.name = "sched_ctx"
 };
 
 

+ 3 - 2
examples/scheduler/dummy_sched.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2010-2012  Université de Bordeaux 1
+ * Copyright (C) 2010-2013  Université de Bordeaux 1
  * Copyright (C) 2010-2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -138,7 +138,8 @@ static struct starpu_codelet dummy_codelet =
 	.cuda_funcs = {dummy_func, NULL},
         .opencl_funcs = {dummy_func, NULL},
 	.model = NULL,
-	.nbuffers = 0
+	.nbuffers = 0,
+	.name = "dummy",
 };
 
 

+ 3 - 2
examples/spmv/spmv.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010, 2011  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010, 2011, 2013  Université de Bordeaux 1
  * Copyright (C) 2010  Mehdi Juhoor <mjuhoor@gmail.com>
  * Copyright (C) 2010, 2011, 2012  Centre National de la Recherche Scientifique
  *
@@ -104,7 +104,8 @@ static struct starpu_codelet spmv_cl =
 #endif
 	.nbuffers = 3,
 	.modes = {STARPU_R, STARPU_R, STARPU_W},
-	.model = NULL
+	.model = NULL,
+	.name = "spmv"
 };
 
 int main(int argc, char **argv)

+ 2 - 1
examples/tag_example/tag_example.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009-2010, 2012  Université de Bordeaux 1
+ * Copyright (C) 2009-2010, 2012-2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -223,6 +223,7 @@ int main(int argc __attribute__((unused)) , char **argv __attribute__((unused)))
 	cl.cuda_funcs[0] = cpu_codelet;
 	cl.opencl_funcs[0] = cpu_codelet;
 	cl.nbuffers = 0;
+	cl.name = "dummy";
 
 	ret = create_task_grid(0);
 	if (ret == 0)

+ 2 - 1
examples/tag_example/tag_example2.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010, 2012  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010, 2012-2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -127,6 +127,7 @@ int main(int argc __attribute__((unused)) , char **argv __attribute__((unused)))
 	cl.cuda_funcs[0] = cpu_codelet;
 	cl.opencl_funcs[0] = cpu_codelet;
 	cl.nbuffers = 0;
+	cl.name = "dummy";
 
 	FPRINTF(stderr, "ITER : %u\n", nk);
 

+ 2 - 1
examples/tag_example/tag_example3.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010, 2012  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010, 2012-2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -129,6 +129,7 @@ int main(int argc __attribute__((unused)) , char **argv __attribute__((unused)))
 	cl.cuda_funcs[0] = cpu_codelet;
 	cl.opencl_funcs[0] = cpu_codelet;
 	cl.nbuffers = 0;
+	cl.name = "dummy";
 
 	FPRINTF(stderr, "ITER : %u\n", nk);
 

+ 3 - 1
examples/tag_example/tag_example4.c

@@ -1,6 +1,6 @@
 /* StarPU --- Runtime system for heterogeneous multicore architectures.
  *
- * Copyright (C) 2009, 2010, 2012  Université de Bordeaux 1
+ * Copyright (C) 2009, 2010, 2012-2013  Université de Bordeaux 1
  * Copyright (C) 2010, 2011, 2012, 2013  Centre National de la Recherche Scientifique
  *
  * StarPU is free software; you can redistribute it and/or modify
@@ -53,6 +53,7 @@ struct starpu_codelet cl_A = {
 	.cuda_funcs = { cpu_codelet_A, NULL},
 	.opencl_funcs = { cpu_codelet_A, NULL},
 	.nbuffers = 0,
+	.name = "dummyA"
 };
 
 struct starpu_codelet cl_B = {
@@ -60,6 +61,7 @@ struct starpu_codelet cl_B = {
 	.cuda_funcs = { cpu_codelet_B, NULL},
 	.opencl_funcs = { cpu_codelet_B, NULL},
 	.nbuffers = 0,
+	.name = "dummyB"
 };
 
 #define Ni	64

+ 1 - 0
examples/tag_example/tag_restartable.c

@@ -136,6 +136,7 @@ int main(int argc __attribute__((unused)) , char **argv __attribute__((unused)))
 	cl.cuda_funcs[0] = cpu_codelet;
 	cl.opencl_funcs[0] = cpu_codelet;
 	cl.nbuffers = 0;
+	cl.name = "dummy";
 
 	FPRINTF(stderr, "ITER : %u\n", nk);