aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/Support/ErrorTest.cpp
diff options
context:
space:
mode:
authorKareem Ergawy <kareem.ergawy@amd.com>2025-02-06 11:45:40 +0100
committerGitHub <noreply@github.com>2025-02-06 11:45:40 +0100
commit84c3b05e5e2776af51a2791bccfaa954bc8e2bcd (patch)
tree979e0a293efacf1e0899c62f304a3ab78e4e3e4c /llvm/unittests/Support/ErrorTest.cpp
parent39be2d0266f1aa229a79c47d81b004c8c2079362 (diff)
downloadllvm-84c3b05e5e2776af51a2791bccfaa954bc8e2bcd.zip
llvm-84c3b05e5e2776af51a2791bccfaa954bc8e2bcd.tar.gz
llvm-84c3b05e5e2776af51a2791bccfaa954bc8e2bcd.tar.bz2
[OpenMP][flang][MLIR] Decouple alloc, init, and copy regions for `omp.private|declare_reduction` ops (#125699)
This PR changes the emitted block structure of alloc, init, and copy regions for `omp.private` and `omp.declare_reduction` ops a little bit. In particular, this decouples init and copy regions from the alloca insertion-point. The main motivation is fix "Instruction does not dominate all uses!" errors that happen specially when an init region uses a value from the OpenMP region it is being inlined into. The issue happens because, previous to this PR, we inline the init region right after the latest alloc block (since we used the alloca IP); which in some cases (see exmaple below), is too early and causes the use dominance issue. Example that would break without this PR (when delayed privatization is enabled for `omp.wsloop`s): ```fortran subroutine test2 (xyz) integer :: i integer :: xyz(:) !$omp target map(from:xyz) !$omp do private(xyz) do i = 1, 10 xyz(i) = i end do !$omp end target end subroutine ```
Diffstat (limited to 'llvm/unittests/Support/ErrorTest.cpp')
0 files changed, 0 insertions, 0 deletions