MCPcopy Create free account
hub / github.com/bloomberg/pystack / dwarfGetScopesDie

Method dwarfGetScopesDie

src/pystack/_pystack/unwinder.cpp:167–179  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

165// AbstractUnwinder
166
167std::pair<int, AbstractUnwinder::Scopes>
168AbstractUnwinder::dwarfGetScopesDie(Dwarf_Die* die) const
169{
170 const auto elem = d_dwarf_getscopes_die_cache.find(die->addr);
171 if (elem == d_dwarf_getscopes_die_cache.cend()) {
172 Dwarf_Die* the_scopes;
173 int nscopes = dwarf_getscopes_die(die, &the_scopes);
174 auto pair = std::make_pair(nscopes, Scopes(the_scopes, std::free));
175 d_dwarf_getscopes_die_cache.emplace(die->addr, pair);
176 return pair;
177 }
178 return elem->second;
179}
180
181std::pair<int, AbstractUnwinder::Scopes>
182AbstractUnwinder::dwarfGetScopes(Dwarf_Die* cudie, Dwarf_Addr pc) const

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected