Syminfo Table Section

The syminfo section contains multiple entries of the type Elf32_Syminfo or Elf64_Syminfo. The .SUNW_syminfo section contains one entry for every entry in the associated symbol table (sh_link).

If this section is present in an object, additional symbol information is to be found by taking the symbol index from the associated symbol table and using that to find the corresponding Elf32_Syminfo entry or Elf64_Syminfo entry in this section. The associated symbol table and the Syminfo table will always have the same number of entries.

Index 0 is used to store the current version of the Syminfo table, which is SYMINFO_CURRENT. Since symbol table entry 0 is always reserved for the UNDEF symbol table entry, this usage does not pose any conflicts.

An Syminfo entry has the following format. See sys/link.h.

typedef struct {
        Elf32_Half      si_boundto;
        Elf32_Half      si_flags;
} Elf32_Syminfo;

typedef struct {
        Elf64_Half      si_boundto;
        Elf64_Half      si_flags;
} Elf64_Syminfo;
si_boundto

An index to an entry in the .dynamic section, identified by the sh_info field, which augments the Syminfo flags. For example, a DT_NEEDED entry identifies a dynamic object associated with the Syminfo entry. The entries that follow are reserved values for si_boundto.

Name Value Meaning

SYMINFO_BT_SELF

0xffff

Symbol bound to self.

SYMINFO_BT_PARENT

0xfffe

Symbol bound to parent. The parent is the first object to cause this dynamic object to be loaded.

SYMINFO_BT_NONE

0xfffd

Symbol has no special symbol binding.

SYMINFO_BT_EXTERN

0xfffc

Symbol definition is external.

si_flags

This bit-field can have flags set, as shown in the following table.

Name Value Meaning

SYMINFO_FLG_DEPEND

0x01

Symbol reference has an association to the object containing the definition.

SYMINFO_FLG_FILTER

0x02

Symbol definition acts as a standard filter.

SYMINFO_FLG_COPY

0x04

Symbol definition is the result of a copy-relocation.

SYMINFO_FLG_LAZYLOAD

0x08

Symbol reference is to an object that should be lazily loaded.

SYMINFO_FLG_DIRECTBIND

0x10

Symbol reference should be bound directly to the definition.

SYMINFO_FLG_NOEXTDIRECT

0x20

Do not allow an external reference to directly bind to this symbol definition.

SYMINFO_FLG_AUXILIARY

0x40

Symbol definition acts as an auxiliary filter.

SYMINFO_FLG_INTERPOSE

0x80

Symbol definition acts as an interposer. This attribute is only applicable for executables.

SYMINFO_FLG_CAP

0x100

Symbol is associated with capabilities.

SYMINFO_FLG_DEFERRED

0x200

Symbol is associated with a deferred reference, and should not be included in BIND_NOW relocations.

SYMINFO_FLG_WEAKFILTER

0x400

Set in conjunction with SYMINFO_FLG_FILTER to specify a weak standard filter. At runtime, the behavior is identical to SYMINFO_FLG_FILTER. At link-edit time, if unused dependency processing is active, a weak filter symbol can be ignored in favor of the same symbol from the target filtee. See Generating Weak Filters