[PATCH] D121100: [clang][DebugInfo] clang should not generate DW_TAG_subprogram entry without DW_AT_name
Alok Kumar Sharma via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 7 02:32:58 PST 2022
alok created this revision.
alok added reviewers: aprantl, djtodoro, jini.susan.
alok added a project: debug-info.
Herald added a project: All.
alok requested review of this revision.
Herald added a project: clang.
Herald added a subscriber: cfe-commits.
Currently Clang is generating subprograms without DW_AT_name. which is fine for LLDB but other debuggers (GNU gdb) can not be forced to accept such DWARF due to DWARF standard mandating DW_AT_name attribute for subprograms.
As per DWARF standard Subroutine must have DW_AT_name attribute.
Please consider below lines from DWARF(5) document
3.3.1 General Subroutine and Entry Point Information
The subroutine or entry point entry has a DW_AT_name attribute whose value is
a null-terminated string containing the subroutine or entry point name. It may
also have a DW_AT_linkage_name attribute as described in Section 2.22 on
page 56.
Current behavior of Clang prevents gdb to show variables in shared/private clause of Openmp task construct.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D121100
Files:
clang/lib/CodeGen/CGDebugInfo.cpp
clang/test/CodeGen/constructor-attribute.c
clang/test/CodeGen/debug-info-oslog.c
clang/test/CodeGenCXX/aix-static-init-debug-info.cpp
clang/test/CodeGenCXX/debug-info-blocks.cpp
clang/test/CodeGenCXX/debug-info-thunk.cpp
clang/test/CodeGenCXX/difile_entry.cpp
clang/test/CodeGenCXX/globalinit-loc.cpp
clang/test/CodeGenObjC/block-byref-debuginfo.m
clang/test/CodeGenObjC/debug-info-block-helper.m
clang/test/CodeGenObjC/debug-info-blocks.m
clang/test/CodeGenObjC/nontrivial-c-struct-exception.m
clang/test/OpenMP/master_taskloop_reduction_codegen.cpp
clang/test/OpenMP/master_taskloop_simd_reduction_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_reduction_codegen.cpp
clang/test/OpenMP/parallel_master_taskloop_simd_reduction_codegen.cpp
clang/test/OpenMP/simd_codegen.cpp
clang/test/OpenMP/taskgroup_task_reduction_codegen.cpp
clang/test/OpenMP/taskloop_reduction_codegen.cpp
clang/test/OpenMP/taskloop_simd_reduction_codegen.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D121100.413391.patch
Type: text/x-patch
Size: 24038 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220307/7b3e4cca/attachment-0001.bin>
More information about the cfe-commits
mailing list