https://bugs.llvm.org/show_bug.cgi?id=50519
Bug ID: 50519
Summary: Segfault when running nested parallels
Product: OpenMP
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: Runtime Library
Assignee: unassignedb...@nondot.org
Reporter: rpena...@bsc.es
CC: llvm-bugs@lists.llvm.org
I've got a segfault when running the following code. It does not always fail
though.
int main() {
int j_size = 20;
int k_size = 20;
#pragma omp parallel num_threads(4)
{
#pragma omp parallel num_threads(2)
for(int j=0; j<j_size; j++){
#pragma omp task
for(int k=0; k<k_size; k++){
}
}
}
}
I've compiled with 59a4ee97288b commit with Debug.
To compile: clang -fopenmp t1.c -o t1
To execute:
export OMP_MAX_ACTIVE_LEVELS=2
for i in {0..100}; do ./t1 ; done
And I see one thread is freeing a team in
https://github.com/llvm/llvm-project/blob/main/openmp/runtime/src/kmp_runtime.cpp#L2496
that is being used by other thread in
https://github.com/llvm/llvm-project/blob/main/openmp/runtime/src/kmp_tasking.cpp#L2788
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs