[llvm-bugs] [Bug 36720] New: Tasking: assertion failure in kmp_runtime.c

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Mar 13 19:13:10 PDT 2018


            Bug ID: 36720
           Summary: Tasking: assertion failure in kmp_runtime.c
           Product: OpenMP
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: Runtime Library
          Assignee: unassignedbugs at nondot.org
          Reporter: grokos at us.ibm.com
                CC: llvm-bugs at lists.llvm.org

Tested on x86_64 and ppc64le, RHEL.

The following code triggers an assertion failure:

#define N 1024
int main()
  #pragma omp task
    #pragma omp parallel for
    for (int i=0; i<N; i++)
      (void) 0;

  #pragma omp task
    #pragma omp parallel for
    for(int i=0; i<N; ++i)
      (void) 0;

  #pragma omp taskwait

  return 0;

Assertion failure at kmp_runtime.cpp(1715): nthreads > 0.
OMP: Error #13: Assertion failure at kmp_runtime.cpp(1715).

The assertion fails even with OMP_NUM_THREADS=1. If I remove the second task,
everything runs to completion. If I remove the "omp parallel for" directives
from inside the tasks, once again everything runs fine.

You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180314/4b1299af/attachment.html>

More information about the llvm-bugs mailing list