Commit 2533b05
committed
[RemoteInspection] Read ContextDescriptor from symbol if available
If the MemoryReader can provide a symbol for the context descriptor, use
that instead of building the mangle tree from metadata. This shouldn't
hurt other clients, and would have a few benefits for LLDB:
- Small but numerous memory reads can be expensive for LLDB, building
the mangle tree from a string should be much faster.
- For types with private discriminators, this allows LLDB to provide the
same private discriminator that's in DWARF and in the swiftmodule (as
opposed to using the memory address where the context descriptor lives
at). This means that these private types would have the same mangled
name in every run. LLDB persistently caches field descriptors by name,
but since private discriminators aren't guaranteed to have the same
mangled name over multiple runs, LLDB would often need to invalidate
its entire cache and rebuild it. Using the stable UUID would solve
that issue.
rdar://165950673
(cherry picked from commit e3c67c9)1 parent c7847e1 commit 2533b05
1 file changed
+12
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2690 | 2690 | | |
2691 | 2691 | | |
2692 | 2692 | | |
| 2693 | + | |
| 2694 | + | |
| 2695 | + | |
| 2696 | + | |
| 2697 | + | |
| 2698 | + | |
| 2699 | + | |
| 2700 | + | |
| 2701 | + | |
| 2702 | + | |
| 2703 | + | |
| 2704 | + | |
2693 | 2705 | | |
2694 | 2706 | | |
2695 | 2707 | | |
| |||
0 commit comments