c-microblaze.texi revision 1.1.1.8 1 1.1.1.8 christos @c Copyright (C) 2009-2024 Free Software Foundation, Inc.
2 1.1 christos @c This is part of the GAS manual.
3 1.1 christos @c For copying conditions, see the file as.texinfo.
4 1.1 christos @ifset GENERIC
5 1.1 christos @page
6 1.1 christos @node MicroBlaze-Dependent
7 1.1 christos @chapter MicroBlaze Dependent Features
8 1.1 christos @end ifset
9 1.1 christos @ifclear GENERIC
10 1.1 christos @node Machine Dependencies
11 1.1 christos @chapter MicroBlaze Dependent Features
12 1.1 christos @end ifclear
13 1.1 christos
14 1.1 christos @cindex MicroBlaze architectures
15 1.1.1.3 christos The Xilinx MicroBlaze processor family includes several variants, all using
16 1.1.1.3 christos the same core instruction set. This chapter covers features of the @sc{gnu}
17 1.1.1.3 christos assembler that are specific to the MicroBlaze architecture. For details about
18 1.1 christos the MicroBlaze instruction set, please see the @cite{MicroBlaze Processor
19 1.1 christos Reference Guide (UG081)} available at www.xilinx.com.
20 1.1 christos
21 1.1 christos @cindex MicroBlaze support
22 1.1 christos @menu
23 1.1 christos * MicroBlaze Directives:: Directives for MicroBlaze Processors.
24 1.1.1.2 christos * MicroBlaze Syntax:: Syntax for the MicroBlaze
25 1.1.1.8 christos * MicroBlaze Options:: Options for MicroBlaze Processors.
26 1.1 christos @end menu
27 1.1 christos
28 1.1 christos @node MicroBlaze Directives
29 1.1 christos @section Directives
30 1.1.1.3 christos @cindex MicroBlaze directives
31 1.1.1.3 christos A number of assembler directives are available for MicroBlaze.
32 1.1 christos
33 1.1 christos @table @code
34 1.1 christos @item .data8 @var{expression},...
35 1.1.1.3 christos This directive is an alias for @code{.byte}. Each expression is assembled
36 1.1 christos into an eight-bit value.
37 1.1 christos
38 1.1 christos @item .data16 @var{expression},...
39 1.1.1.3 christos This directive is an alias for @code{.hword}. Each expression is assembled
40 1.1 christos into an 16-bit value.
41 1.1 christos
42 1.1 christos @item .data32 @var{expression},...
43 1.1.1.3 christos This directive is an alias for @code{.word}. Each expression is assembled
44 1.1 christos into an 32-bit value.
45 1.1 christos
46 1.1 christos @item .ent @var{name}[,@var{label}]
47 1.1.1.3 christos This directive is an alias for @code{.func} denoting the start of function
48 1.1.1.3 christos @var{name} at (optional) @var{label}.
49 1.1 christos
50 1.1 christos @item .end @var{name}[,@var{label}]
51 1.1.1.3 christos This directive is an alias for @code{.endfunc} denoting the end of function
52 1.1 christos @var{name}.
53 1.1 christos
54 1.1 christos @item .gpword @var{label},...
55 1.1 christos This directive is an alias for @code{.rva}. The resolved address of @var{label}
56 1.1 christos is stored in the data section.
57 1.1 christos
58 1.1 christos @item .weakext @var{label}
59 1.1 christos Declare that @var{label} is a weak external symbol.
60 1.1 christos
61 1.1 christos @item .rodata
62 1.1 christos Switch to .rodata section. Equivalent to @code{.section .rodata}
63 1.1 christos
64 1.1 christos @item .sdata2
65 1.1 christos Switch to .sdata2 section. Equivalent to @code{.section .sdata2}
66 1.1 christos
67 1.1 christos @item .sdata
68 1.1 christos Switch to .sdata section. Equivalent to @code{.section .sdata}
69 1.1 christos
70 1.1 christos @item .bss
71 1.1 christos Switch to .bss section. Equivalent to @code{.section .bss}
72 1.1 christos
73 1.1 christos @item .sbss
74 1.1 christos Switch to .sbss section. Equivalent to @code{.section .sbss}
75 1.1 christos @end table
76 1.1.1.2 christos
77 1.1.1.2 christos @node MicroBlaze Syntax
78 1.1.1.2 christos @section Syntax for the MicroBlaze
79 1.1.1.2 christos @menu
80 1.1.1.2 christos * MicroBlaze-Chars:: Special Characters
81 1.1.1.2 christos @end menu
82 1.1.1.2 christos
83 1.1.1.2 christos @node MicroBlaze-Chars
84 1.1.1.2 christos @subsection Special Characters
85 1.1.1.2 christos
86 1.1.1.2 christos @cindex line comment character, MicroBlaze
87 1.1.1.2 christos @cindex MicroBlaze line comment character
88 1.1.1.2 christos The presence of a @samp{#} on a line indicates the start of a comment
89 1.1.1.2 christos that extends to the end of the current line.
90 1.1.1.2 christos
91 1.1.1.2 christos If a @samp{#} appears as the first character of a line, the whole line
92 1.1.1.2 christos is treated as a comment, but in this case the line can also be a
93 1.1.1.2 christos logical line number directive (@pxref{Comments}) or a
94 1.1.1.2 christos preprocessor control command (@pxref{Preprocessing}).
95 1.1.1.2 christos
96 1.1.1.2 christos @cindex line separator, MicroBlaze
97 1.1.1.2 christos @cindex statement separator, MicroBlaze
98 1.1.1.2 christos @cindex MicroBlaze line separator
99 1.1.1.2 christos The @samp{;} character can be used to separate statements on the same
100 1.1.1.2 christos line.
101 1.1.1.8 christos
102 1.1.1.8 christos @node MicroBlaze Options
103 1.1.1.8 christos @section Options
104 1.1.1.8 christos
105 1.1.1.8 christos MicroBlaze processors support the following options:
106 1.1.1.8 christos
107 1.1.1.8 christos @cindex MicroBlaze Options
108 1.1.1.8 christos
109 1.1.1.8 christos @table @code
110 1.1.1.8 christos @item -mbig-endian
111 1.1.1.8 christos Build for MicroBlaze in Big Endian configuration.
112 1.1.1.8 christos
113 1.1.1.8 christos @item -mlittle-endian
114 1.1.1.8 christos Build for MicroBlaze in Little Endian configuration.
115 1.1.1.8 christos @end table
116