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

Method findDie

src/pystack/_pystack/unwinder.cpp:38–50  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36}
37
38Dwarf_Die*
39ModuleCuDieRanges::CuDieRanges::findDie(Dwarf_Addr addr, Dwarf_Addr* bias) const
40{
41 auto it = std::find_if(d_ranges.begin(), d_ranges.end(), [addr](const CuDieRange& range) {
42 return range.contains(addr);
43 });
44 if (it == d_ranges.end()) {
45 return nullptr;
46 }
47
48 *bias = it->bias;
49 return it->cuDie;
50}
51
52Dwarf_Die*
53ModuleCuDieRanges::moduleAddrDie(Dwfl_Module* mod, Dwarf_Addr addr, Dwarf_Addr* bias)

Callers 1

moduleAddrDieMethod · 0.80

Calls 1

containsMethod · 0.45

Tested by

no test coverage detected