Accéder au contenu.
Menu Sympa

starpu-devel - [Starpu-devel] OpenMP

Objet : Developers list for StarPU

Archives de la liste

[Starpu-devel] OpenMP


Chronologique Discussions 
  • From: Nathalie Furmento <nathalie.furmento@labri.fr>
  • To: "starpu-devel@lists.gforge.inria.fr" <starpu-devel@lists.gforge.inria.fr>
  • Subject: [Starpu-devel] OpenMP
  • Date: Sat, 24 Mar 2012 09:38:52 +0100
  • List-archive: <http://lists.gforge.inria.fr/pipermail/starpu-devel>
  • List-id: "Developers list. For discussion of new features, code changes, etc." <starpu-devel.lists.gforge.inria.fr>



-------- Original Message -------- Date: Sat, 24 Mar 2012 07:19:39 +0530 From: uma boregowda <umaboregowda@gmail.com> To: Nathalie Furmento <nathalie.furmento@labri.fr>


Hi,

 Thanks for the help, i am now able to further explore starpu.

 well, i did not understand openmp program.

 Within a task, few threads are created.



 void scal_cpu_func(void *buffers[], void *_args) {     unsigned i;     float *factor = _args, f = *factor;
    struct starpu_vector_interface *vector = buffers[0];     unsigned n = STARPU_VECTOR_GET_NX(vector);     float *val = (float *)STARPU_VECTOR_GET_PTR(vector);
    FPRINTF(stderr, "running task with %d CPUs.\n", starpu_combined_worker_get_size());
#pragma omp parallel for num_threads(starpu_combined_worker_get_size())     for (i = 0; i < n; i++) {
        float v = val[i];         int j;         for (j = 0; j < 100; j++)
            v = v * f;         val[i] = v;     } }


now, where will these threads be scheduled ?

What does the above function accomplishing ?

with best wishes
uma


2012/3/13 Ludovic Courtès <ludovic.courtes@inria.fr>
Hi,

uma boregowda <umaboregowda@gmail.com> skribis:
Instead do:

 cd examples
 make basic_examples/hello_world
 ./basic_examples/hello_world

Ludo’.






Archives gérées par MHonArc 2.6.19+.

Haut de le page