[all-commits] [llvm/llvm-project] 9e08db: [OpenMPIRBuilder] Don't drop debug info for target...
Abid Qadeer via All-commits
all-commits at lists.llvm.org
Wed Sep 4 02:16:35 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9e08db796b7fc1aa21ec0a0c16a0213229e02010
https://github.com/llvm/llvm-project/commit/9e08db796b7fc1aa21ec0a0c16a0213229e02010
Author: Abid Qadeer <haqadeer at amd.com>
Date: 2024-09-04 (Wed, 04 Sep 2024)
Changed paths:
M flang/lib/Optimizer/Transforms/AddDebugInfo.cpp
A flang/test/Integration/debug-target-region-vars.f90
M llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
M llvm/unittests/Frontend/OpenMPIRBuilderTest.cpp
A mlir/test/Target/LLVMIR/omptarget-debug.mlir
A mlir/test/Target/LLVMIR/omptarget-debug2.mlir
Log Message:
-----------
[OpenMPIRBuilder] Don't drop debug info for target region. (#80692)
When an outlined function is generated for omp target region, a
corresponding DISubprogram was not being generated. This resulted in all
the debug information for the target region being dropped.
This commit adds DISubprogram for the outlined function if there is one
available for the parent function. It also updates the current debug
location so that the right scope is used for the entries in the outlined
function.
There are places in the OpenMPIRBuilder which changes insertion point but
don't update the debug location accordingly. They cause issue when debug info
is enabled. I have fixed a few that I observed to cause issue. But there may be
more and a systematic cleanup may be required.
With this change in place, I can set source line breakpoint in target
region and run to them in debugger.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list