[Openmp-dev] Using taskyield to emulate a background service
Jim Cownie via Openmp-dev
openmp-dev at lists.llvm.org
Thu Jul 16 00:49:41 PDT 2020
> I am trying to emulate recurring service calls in OpenMP (similar to
> what OmpSs-2 offers) in order to progress outstanding MPI operations.
You may want to check out our IPDPS paper (Parallelizing MPI Using Tasks for Hybrid Programming Models <https://ieeexplore.ieee.org/document/8425570>)
on using OpenMP tasks in an MPI implementation, though I guess you may not be down inside the MPI library.
> Date: Wed, 15 Jul 2020 11:33:57 +0200
> From: Joseph Schuchart via Openmp-dev <openmp-dev at lists.llvm.org>
> To: openmp-dev <openmp-dev at lists.llvm.org>
> Subject: [Openmp-dev] Using taskyield to emulate a background service
> Message-ID: <b35cf7d0-751d-a45e-4112-0eca25ef1ad8 at hlrs.de>
> Content-Type: text/plain; charset=utf-8; format=flowed
>
> Dear devs,
>
> I am trying to emulate recurring service calls in OpenMP (similar to
> what OmpSs-2 offers) in order to progress outstanding MPI operations. My
> attempt is to have one task executed by some thread that invokes the
> progress service and calls taskyield to participate in the execution of
> tasks generated by any of the other threads. The task's code is similar
> to this snippet:
>
> #pragma omp task shared(do_progress)
> {
> while(do_progress) {
> call_progress();
> #pragma omp taskyield
> }
> }
> }
>
> The variable `do_progress` is a volatile flag that is unset by another
> thread once progress is not needed anymore.
>
> What I found is that the thread executing this service task does not
> participating in the execution of available tasks from the other
> threads. In other words, the yield does nothing. However, if I set
> KMP_TASK_STEALING_CONSTRAINT=0 then the thread does participate in the
> execution of tasks. All tasks are tied (because of issues with untied
> tasks).
>
> Can someone tell me why taskyield does not steal tasks by default? Is
> that related to the the fact that all tasks are tied?
>
> Many thanks!
>
> Cheers
> Joseph
>
> --
> Dipl.-Inf. Joseph Schuchart
> High Performance Computing Center Stuttgart (HLRS)
> Nobelstr. 19
> D-70569 Stuttgart
>
> Tel.: +49(0)711-68565890
> Fax: +49(0)711-6856832
> E-Mail: schuchart at hlrs.de
>
-- Jim
James Cownie <jcownie at gmail.com>
Mob: +44 780 637 7146
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20200716/4ef4fa39/attachment.html>
More information about the Openmp-dev
mailing list