diff options
author | agozillon <Andrew.Gozillon@amd.com> | 2025-01-30 17:33:36 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-01-30 17:33:36 +0100 |
commit | 2428b6ec40bc60bfcdf1d481f92f34f7279fb5f3 (patch) | |
tree | 1fd74ad409262f556910897543eba2c91dfd49d4 /lldb/source/Interpreter/CommandInterpreter.cpp | |
parent | 4186805060bb06dc3362707d45e6f0f826208a8f (diff) | |
download | llvm-2428b6ec40bc60bfcdf1d481f92f34f7279fb5f3.zip llvm-2428b6ec40bc60bfcdf1d481f92f34f7279fb5f3.tar.gz llvm-2428b6ec40bc60bfcdf1d481f92f34f7279fb5f3.tar.bz2 |
[Flang][MLIR][OpenMP] Fix Target Data if (present(...)) causing LLVM-IR branching error (#123771)
Currently if we generate code for the below target data map that uses an
optional mapping:
!$omp target data if(present(a)) map(alloc:a)
do i = 1, 10
a(i) = i
end do
!$omp end target data
We yield an LLVM-IR error as the branch for the else path is not
generated. This occurs because we enter the NoDupPriv path of the call
back function when generating the else branch, however, the emitBranch
function needs to be set to a block for it to functionally generate and
link in a follow up branch. The NoDupPriv path currently doesn't do
this, while it's not supposed to generate anything (as far as I am
aware) we still need to at least set the builders placement back so that
it emits the appropriate follow up branch. This avoids the missing
terminator LLVM-IR verification error by correctly generating the follow
up branch.
Diffstat (limited to 'lldb/source/Interpreter/CommandInterpreter.cpp')
0 files changed, 0 insertions, 0 deletions