Directives that Initialize Values

Several directives assemble values for the current section. For example:

Figure 5-1 The .field DirectiveTMS320C6000 field1_pru186.gif

NOTE

Directives that Initialize Constants When Used in a .struct/.endstruct Sequence

The .bits, .byte, .char, .int, .long, .word, .double, .half, .short, .string, .ubyte, .uchar, .uhalf, .uint, .ulong, .ushort, .uword, .float, and .field directives do not initialize memory when they are part of a .struct/ .endstruct sequence; rather, they define a member’s size. For more information, see the .struct/.endstruct directives.

Figure 5-2 compares the .byte, .half, .word, and .string directives using the following assembled code:

1 00000000 000000AB .byte 0ABh 2 .align 4 3 00000004 0000CDEF .half 0CDEFh 4 00000008 89ABCDEF .word 089ABCDEFh 5 0000000c 00000068 .string "help" 0000000d 00000065 0000000e 0000006C 0000000f 00000070
Figure 5-2 Initialization DirectivesTMS320C6000 initdirs_pru186.gif