Commit 9982f8e
authored
[lldb][SymbolFileDWARF][NFC] Remove unnecessary calls to GetDWARFDeclContext (llvm#74523)
The function FindDefinitionTypeForDWARFDeclContext loops over all DIEs
corresponding to types with a certain name and compares the context of
each found DIE with the context of a target DIE. However, the target DIE
never changes throughout this search, and yet we recompute its
DeclContext on every iteration of the search. This is wasteful because
the method is not exactly free (see
DWARFDebugInfoEntry::GetDWARFDeclContextStatic).1 parent 45e7b41 commit 9982f8e
1 file changed
+3
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3120 | 3120 | | |
3121 | 3121 | | |
3122 | 3122 | | |
3123 | | - | |
| 3123 | + | |
| 3124 | + | |
3124 | 3125 | | |
3125 | 3126 | | |
3126 | 3127 | | |
| |||
3184 | 3185 | | |
3185 | 3186 | | |
3186 | 3187 | | |
3187 | | - | |
| 3188 | + | |
3188 | 3189 | | |
3189 | 3190 | | |
3190 | 3191 | | |
| |||
0 commit comments