Section 1: General Information
21
TI
-
89 / TI
-
92 Plus Sierra C Assembler Reference Manual Not for Distribution
Beta Version February 2, 2001
1.4.7.3. Symbols and Functions
For each function, a special symbol .bf is put between the function name and the
first local symbol of the function name in the symbol table. Correspondingly, a
special symbol .ef is put immediately after the last symbol of the function in the
symbol table. Associated with the .bf and .ef symbols (as defined by their
auxiliary symbol table entries) are the absolute line numbers of the function's
open brace ' { ' and close brace ' } ', respectively. The example in Table 1.15 (in
addition to showing nested inner blocks) shows a pair of C language functions
and the associated symbol table.
1.4.8. Symbol Table Entries
All symbols, regardless of their type and storage class, use the same symbol
table format. Every symbol table entry occupies 18 bytes. Table 1.16 describes
the fields within a symbol table entry. It should be noted that the indices for
symbol table entries begin with 0 (not 1). Also, auxiliary entries count as symbol
entries for purposes of indexing into the symbol table. Defined in file_fmt.txt are
SYM_ENT and SYM_ENT_SIZE, the typedefs for the symbol table entry
structure and symbol table entry size, respectively.
Bytes Declaration Name Description
0-7 char sym_name 8-character null padded symbol name
0-3 unsigned long sym_zeroes Zero in this field indicates the name is in the
string table
4-7 unsigned long sym_offset Offset of the name in the string table
8-11 unsigned long sym_value Symbol value (storage class dependent)
12-13 unsigned short sym_sec_nbr Section number of symbol
14-15 unsigned short sym_type Basic and derived type information
16 char sym_sclass Storage class of symbol
17 char sym_nbr_aux Number of auxiliary entries
Table 1.16: Symbol Table Entry