|Home > Iris APIs > Resources API > ElfDwarf scheme for canonical register numbers|
The ElfDwarf scheme is used for the
RegisterInfo.canonicalRn field if the instance property
register.canonicalRnScheme has the string value
The ElfDwarf scheme uses the DWARF register numbers defined for a specific architecture, combined with the value of the ELF header field,
e_machine, which defines the architecture and is used as a namespace for the DWARF register numbers. This results in unique canonical register numbers across all architectures that ELF supports. The ElfDwarf scheme is defined for all architectures supported by ELF that define DWARF register numbers. See
/usr/include/elf.h for a list of all possible values for
Only a subset of the registers of an instance have an assigned DWARF register number. All other registers do not have a
RegisterInfo.canonicalRn field and therefore cannot be discovered through the canonical register number. Instead, they can be discovered by inspecting
ResourceInfo.tags, for instance
ResourceInfo.name, which contains the architectural register name, if available.
RegisterInfo.canonicalRn value is a 64-bit value with the following structure:
EM_*constant for the architecture, as defined by the ELF header field
e_machine. This is the namespace for the DWARF register number specified in bits[15:0].