tblah wrote: I also don't understand what __kmpc_cancel_barrier is for or why we only generate it for omp parallel. I did ask about this on the flang slack and nobody responded. I have kept it here just in case. https://github.com/llvm/llvm-project/pull/164586