class CompileUnit

Defined at line 25 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

Represents a DWARF "unit" DIE, both regular ones and the "skeleton" ones (skeleton units are

in the main binary and refer to a .dwo file containing the unit info). This is the root of all

other Debug Information Entries (DIEs) in the unit, and is contained inside the DwarfUnit object.

See the DwarfUnit object which contains the other unit-related stuff like line tables (see that

class for a longer discussion). Usually "unit" offsets are relative to the DwarfUnit and NOT this

class.

Public Methods

const fxl::WeakPtr<ModuleSymbols> & module ()

Module. This can be null if the module was unloaded while somebody held onto this symbol. It

is also null in many unit testing situations where mock symbols are created.

Defined at line 29 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

bool is_skeleton ()

Skeleton units refer a .dwo file containing the debug symbols. But they have the same basic

attributes as a regular compilation unit.

Defined at line 33 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

DwarfUnit * dwarf_unit ()

See class comment above. Can be null for synthetic symbols and for testing.

Defined at line 36 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

DwarfLang language ()

Defined at line 38 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

const std::string & name ()

The file name that generated this unit.

Defined at line 41 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

const std::optional<uint64_t> & addr_base ()

Returns the DW_AT_addr_base attribute on the unit, if given. This attribute points to the

beginning of the compilation unit's contribution to the .debug_addr section of the module. It

is used for evaluating some DWARF expressions.

Defined at line 46 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

Protected Methods

const CompileUnit * AsCompileUnit ()

Symbol protected overrides.

Defined at line 53 of file ../../src/developer/debug/zxdb/symbols/compile_unit.h

Friends

class MakeRefCountedHelper
class RefCountedThreadSafe