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

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.
llvm-bugs mailing list

Reply via email to