[all-commits] [llvm/llvm-project] 9fc54c: [clang][DebugInfo][gmodules] Set runtimeLang on Ob...
Michael Buch via All-commits
all-commits at lists.llvm.org
Tue Dec 17 08:40:31 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 9fc54c0e8049553a30c17a3698445d58800916c9
https://github.com/llvm/llvm-project/commit/9fc54c0e8049553a30c17a3698445d58800916c9
Author: Michael Buch <michaelbuch12 at gmail.com>
Date: 2024-12-17 (Tue, 17 Dec 2024)
Changed paths:
M clang/lib/CodeGen/CGDebugInfo.cpp
M clang/test/Modules/ExtDebugInfo.m
M clang/test/Modules/ModuleDebugInfo.m
A lldb/test/Shell/SymbolFile/DWARF/objc-gmodules-class-extension.test
Log Message:
-----------
[clang][DebugInfo][gmodules] Set runtimeLang on ObjC forward declarations (#120154)
In Objective-C, forward declarations are currently represented as:
```
DW_TAG_structure_type
DW_AT_name ("Foo")
DW_AT_declaration (true)
DW_AT_APPLE_runtime_class (DW_LANG_ObjC)
```
However, when compiling with `-gmodules`, when a class definition is
turned into a forward declaration within a `DW_TAG_module`, the DIE for
the forward declaration looks as follows:
```
DW_TAG_structure_type
DW_AT_name ("Foo")
DW_AT_declaration (true)
```
Note the absence of `DW_AT_APPLE_runtime_class`. With recent changes in
LLDB, not being able to differentiate between C++ and Objective-C
forward declarations has become problematic (see attached test-case and
explanation in https://github.com/llvm/llvm-project/pull/119860).
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