1 @c Copyright 2010, 2011 Free Software Foundation, Inc.
2 @c This is part of the GAS manual.
3 @c For copying conditions, see the file as.texinfo.
8 @chapter TIC6X Dependent Features
11 @node Machine Dependencies
12 @chapter TIC6X Dependent Features
16 @cindex TMS320C6X support
18 * TIC6X Options:: Options
19 * TIC6X Syntax:: Syntax
20 * TIC6X Directives:: Directives
24 @section TIC6X Options
26 @cindex options for TIC6X
31 @cindex @code{-march=} command line option, TIC6X
32 @item -march=@var{arch}
33 Enable (only) instructions from architecture @var{arch}. By default,
34 all instructions are permitted.
36 The following values of @var{arch} are accepted: @code{c62x},
37 @code{c64x}, @code{c64x+}, @code{c67x}, @code{c67x+}, @code{c674x}.
39 @cindex @code{-mdsbt} command line option, TIC6X
40 @cindex @code{-mno-dsbt} command line option, TIC6X
43 The @option{-mdsbt} option causes the assembler to generate the
44 @code{Tag_ABI_DSBT} attribute with a value of 1, indicating that the
45 code is using DSBT addressing. The @option{-mno-dsbt} option, the
46 default, causes the tag to have a value of 0, indicating that the code
47 does not use DSBT addressing. The linker will emit a warning if
48 objects of different type (DSBT and non-DSBT) are linked together.
50 @cindex @code{-mpid=} command line option, TIC6X
54 The @option{-mpid=} option causes the assembler to generate the
55 @code{Tag_ABI_PID} attribute with a value indicating the form of data
56 addressing used by the code. @option{-mpid=no}, the default,
57 indicates position-dependent data addressing, @option{-mpid=near}
58 indicates position-independent addressing with GOT accesses using near
59 DP addressing, and @option{-mpid=far} indicates position-independent
60 addressing with GOT accesses using far DP addressing. The linker will
61 emit a warning if objects built with different settings of this option
64 @cindex @code{-mpic} command line option, TIC6X
65 @cindex @code{-mno-pic} command line option, TIC6X
68 The @option{-mpic} option causes the assembler to generate the
69 @code{Tag_ABI_PIC} attribute with a value of 1, indicating that the
70 code is using position-independent code addressing, The
71 @code{-mno-pic} option, the default, causes the tag to have a value of
72 0, indicating position-dependent code addressing. The linker will
73 emit a warning if objects of different type (position-dependent and
74 position-independent) are linked together.
76 @cindex TIC6X big-endian output
77 @cindex TIC6X little-endian output
78 @cindex big-endian output, TIC6X
79 @cindex little-endian output, TIC6X
81 @itemx -mlittle-endian
82 Generate code for the specified endianness. The default is
91 @cindex line comment character, TIC6X
92 @cindex TIC6X line comment character
93 The presence of a @samp{;} on a line indicates the start of a comment
94 that extends to the end of the current line. If a @samp{#} or
95 @samp{*} appears as the first character of a line, the whole line is
96 treated as a comment. Note that if a line starts with a @samp{#}
97 character then it can also be a logical line number directive
98 (@pxref{Comments}) or a preprocessor control command
99 (@pxref{Preprocessing}).
101 @cindex line separator, TIC6X
102 @cindex statement separator, TIC6X
103 @cindex TIC6X line separator
104 The @samp{@@} character can be used instead of a newline to separate
107 Instruction, register and functional unit names are case-insensitive.
108 @command{@value{AS}} requires fully-specified functional unit names,
109 such as @samp{.S1}, @samp{.L1X} or @samp{.D1T2}, on all instructions
110 using a functional unit.
112 For some instructions, there may be syntactic ambiguity between
113 register or functional unit names and the names of labels or other
114 symbols. To avoid this, enclose the ambiguous symbol name in
115 parentheses; register and functional unit names may not be enclosed in
118 @node TIC6X Directives
119 @section TIC6X Directives
121 @cindex machine directives, TIC6X
122 @cindex TIC6X machine directives
124 Directives controlling the set of instructions accepted by the
125 assembler have effect for instructions between the directive and any
126 subsequent directive overriding it.
130 @cindex @code{.arch} directive, TIC6X
131 @item .arch @var{arch}
132 This has the same effect as @option{-march=@var{arch}}.
134 @cindex @code{.cantunwind} directive, TIC6X
136 Prevents unwinding through the current function. No personality routine
137 or exception table data is required or permitted.
139 If this is not specified then frame unwinding information will be
140 constructed from CFI directives. @pxref{CFI directives}.
142 @cindex @code{.c6xabi_attribute} directive, TIC6X
143 @item .c6xabi_attribute @var{tag}, @var{value}
144 Set the C6000 EABI build attribute @var{tag} to @var{value}.
146 The @var{tag} is either an attribute number or one of
147 @code{Tag_ISA}, @code{Tag_ABI_wchar_t},
148 @code{Tag_ABI_stack_align_needed},
149 @code{Tag_ABI_stack_align_preserved}, @code{Tag_ABI_DSBT},
150 @code{Tag_ABI_PID}, @code{Tag_ABI_PIC},
151 @code{TAG_ABI_array_object_alignment},
152 @code{TAG_ABI_array_object_align_expected},
153 @code{Tag_ABI_compatibility} and @code{Tag_ABI_conformance}. The
154 @var{value} is either a @code{number}, @code{"string"}, or
155 @code{number, "string"} depending on the tag.
157 @cindex @code{.ehtype} directive, TIC6X
158 @item .ehtype @var{symbol}
159 Output an exception type table reference to @var{symbol}.
161 @cindex @code{.endp} directive, TIC6X
163 Marks the end of and exception table or function. If preceeded by a
164 @code{.handlerdata} directive then this also switched back to the previous
167 @cindex @code{.handlerdata} directive, TIC6X
169 Marks the end of the current function, and the start of the exception table
170 entry for that function. Anything between this directive and the
171 @code{.endp} directive will be added to the exception table entry.
173 Must be preceded by a CFI block containing a @code{.cfi_lsda} directive.
176 @cindex @code{.nocmp} directive, TIC6X
178 Disallow use of C64x+ compact instructions in the current text
181 @cindex @code{.personalityindex} directive, TIC6X
182 @item .personalityindex @var{index}
183 Sets the personality routine for the current function to the ABI specified
184 compact routine number @var{index}
186 @cindex @code{.personality} directive, TIC6X
187 @item .personality @var{name}
188 Sets the personality routine for the current function to @var{name}.
190 @cindex @code{.scomm} directive, TIC6X
191 @item .scomm @var{symbol}, @var{size}, @var{align}
192 Like @code{.comm}, creating a common symbol @var{symbol} with size @var{size}
193 and alignment @var{align}, but unlike when using @code{.comm}, this symbol
194 will be placed into the small BSS section by the linker.