annotate clang/www/get_started.html @ 180:680fa57a2f20

fix compile errors.
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Sat, 30 May 2020 17:44:06 +0900
parents 1d019706d866
children 2e18cbf3894f
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
150
anatofuz
parents:
diff changeset
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
anatofuz
parents:
diff changeset
2 "http://www.w3.org/TR/html4/strict.dtd">
anatofuz
parents:
diff changeset
3 <html>
anatofuz
parents:
diff changeset
4 <head>
anatofuz
parents:
diff changeset
5 <META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
anatofuz
parents:
diff changeset
6 <title>Clang - Getting Started</title>
anatofuz
parents:
diff changeset
7 <link type="text/css" rel="stylesheet" href="menu.css">
anatofuz
parents:
diff changeset
8 <link type="text/css" rel="stylesheet" href="content.css">
anatofuz
parents:
diff changeset
9 </head>
anatofuz
parents:
diff changeset
10 <body>
anatofuz
parents:
diff changeset
11
anatofuz
parents:
diff changeset
12 <!--#include virtual="menu.html.incl"-->
anatofuz
parents:
diff changeset
13
anatofuz
parents:
diff changeset
14 <div id="content">
anatofuz
parents:
diff changeset
15
anatofuz
parents:
diff changeset
16 <h1>Getting Started: Building and Running Clang</h1>
anatofuz
parents:
diff changeset
17
anatofuz
parents:
diff changeset
18 <p>This page gives you the shortest path to checking out Clang and demos a few
anatofuz
parents:
diff changeset
19 options. This should get you up and running with the minimum of muss and fuss.
anatofuz
parents:
diff changeset
20 If you like what you see, please consider <a href="get_involved.html">getting
anatofuz
parents:
diff changeset
21 involved</a> with the Clang community. If you run into problems, please file
anatofuz
parents:
diff changeset
22 bugs in <a href="https://bugs.llvm.org/">LLVM Bugzilla</a>.</p>
anatofuz
parents:
diff changeset
23
anatofuz
parents:
diff changeset
24 <h2 id="download">Release Clang Versions</h2>
anatofuz
parents:
diff changeset
25
anatofuz
parents:
diff changeset
26 <p>Clang is released as part of regular LLVM releases. You can download the release versions from <a href="https://llvm.org/releases/">https://llvm.org/releases/</a>.</p>
anatofuz
parents:
diff changeset
27 <p>Clang is also provided in all major BSD or GNU/Linux distributions as part of their respective packaging systems. From Xcode 4.2, Clang is the default compiler for Mac OS X.</p>
anatofuz
parents:
diff changeset
28
anatofuz
parents:
diff changeset
29 <h2 id="build">Building Clang and Working with the Code</h2>
anatofuz
parents:
diff changeset
30
anatofuz
parents:
diff changeset
31 <h3 id="buildNix">On Unix-like Systems</h3>
anatofuz
parents:
diff changeset
32
anatofuz
parents:
diff changeset
33 <p>If you would like to check out and build Clang, the current procedure is as
anatofuz
parents:
diff changeset
34 follows:</p>
anatofuz
parents:
diff changeset
35
anatofuz
parents:
diff changeset
36 <ol>
anatofuz
parents:
diff changeset
37 <li>Get the required tools.
anatofuz
parents:
diff changeset
38 <ul>
anatofuz
parents:
diff changeset
39 <li>See
anatofuz
parents:
diff changeset
40 <a href="https://llvm.org/docs/GettingStarted.html#requirements">
anatofuz
parents:
diff changeset
41 Getting Started with the LLVM System - Requirements</a>.</li>
anatofuz
parents:
diff changeset
42 <li>Note also that Python is needed for running the test suite.
anatofuz
parents:
diff changeset
43 Get it at: <a href="https://www.python.org/downloads/">
anatofuz
parents:
diff changeset
44 https://www.python.org/downloads/</a></li>
anatofuz
parents:
diff changeset
45 <li>Standard build process uses CMake. Get it at:
anatofuz
parents:
diff changeset
46 <a href="https://cmake.org/download/">
anatofuz
parents:
diff changeset
47 https://cmake.org/download/</a></li>
anatofuz
parents:
diff changeset
48 </ul>
anatofuz
parents:
diff changeset
49
anatofuz
parents:
diff changeset
50 <li>Check out the LLVM project:
anatofuz
parents:
diff changeset
51 <ul>
anatofuz
parents:
diff changeset
52 <li>Change directory to where you want the llvm directory placed.</li>
anatofuz
parents:
diff changeset
53 <li><tt>git clone https://github.com/llvm/llvm-project.git</tt></li>
anatofuz
parents:
diff changeset
54 </ul>
anatofuz
parents:
diff changeset
55 </li>
anatofuz
parents:
diff changeset
56 <li>Build LLVM and Clang:
anatofuz
parents:
diff changeset
57 <ul>
anatofuz
parents:
diff changeset
58 <li><tt>cd llvm-project</tt></li>
anatofuz
parents:
diff changeset
59 <li><tt>mkdir build</tt> (in-tree build is not supported)</li>
anatofuz
parents:
diff changeset
60 <li><tt>cd build</tt></li>
anatofuz
parents:
diff changeset
61 <li><tt>cmake -DLLVM_ENABLE_PROJECTS=clang -G "Unix Makefiles" ../llvm</tt></li>
anatofuz
parents:
diff changeset
62 <li><tt>make</tt></li>
anatofuz
parents:
diff changeset
63 <li>This builds both LLVM and Clang for debug mode.</li>
anatofuz
parents:
diff changeset
64 <li>Note: For subsequent Clang development, you can just run
anatofuz
parents:
diff changeset
65 <tt>make clang</tt>.</li>
anatofuz
parents:
diff changeset
66 <li>CMake allows you to generate project files for several IDEs: Xcode,
anatofuz
parents:
diff changeset
67 Eclipse CDT4, CodeBlocks, Qt-Creator (use the CodeBlocks generator),
anatofuz
parents:
diff changeset
68 KDevelop3. For more details see
anatofuz
parents:
diff changeset
69 <a href="https://llvm.org/docs/CMake.html">Building LLVM with CMake</a>
anatofuz
parents:
diff changeset
70 page.</li>
anatofuz
parents:
diff changeset
71 </ul>
anatofuz
parents:
diff changeset
72 </li>
anatofuz
parents:
diff changeset
73
anatofuz
parents:
diff changeset
74 <li>If you intend to use Clang's C++ support, you may need to tell it how
anatofuz
parents:
diff changeset
75 to find your C++ standard library headers. In general, Clang will detect
anatofuz
parents:
diff changeset
76 the best version of libstdc++ headers available and use them - it will
anatofuz
parents:
diff changeset
77 look both for system installations of libstdc++ as well as installations
anatofuz
parents:
diff changeset
78 adjacent to Clang itself. If your configuration fits neither of these
anatofuz
parents:
diff changeset
79 scenarios, you can use the <tt>-DGCC_INSTALL_PREFIX</tt> cmake option
anatofuz
parents:
diff changeset
80 to tell Clang where the gcc containing the desired libstdc++ is installed.
anatofuz
parents:
diff changeset
81 </li>
anatofuz
parents:
diff changeset
82 <li>Try it out (assuming you add llvm/build/bin to your path):
anatofuz
parents:
diff changeset
83 <ul>
anatofuz
parents:
diff changeset
84 <li><tt>clang --help</tt></li>
anatofuz
parents:
diff changeset
85 <li><tt>clang file.c -fsyntax-only</tt> (check for correctness)</li>
anatofuz
parents:
diff changeset
86 <li><tt>clang file.c -S -emit-llvm -o -</tt> (print out unoptimized llvm code)</li>
anatofuz
parents:
diff changeset
87 <li><tt>clang file.c -S -emit-llvm -o - -O3</tt></li>
anatofuz
parents:
diff changeset
88 <li><tt>clang file.c -S -O3 -o -</tt> (output native machine code)</li>
anatofuz
parents:
diff changeset
89 </ul>
anatofuz
parents:
diff changeset
90 </li>
anatofuz
parents:
diff changeset
91 <li>Run the testsuite:
anatofuz
parents:
diff changeset
92 <ul>
anatofuz
parents:
diff changeset
93 <li><tt>make check-clang</tt></li>
anatofuz
parents:
diff changeset
94 </ul>
anatofuz
parents:
diff changeset
95 </li>
anatofuz
parents:
diff changeset
96 </ol>
anatofuz
parents:
diff changeset
97
anatofuz
parents:
diff changeset
98 <h3 id="buildWindows">Using Visual Studio</h3>
anatofuz
parents:
diff changeset
99
anatofuz
parents:
diff changeset
100 <p>The following details setting up for and building Clang on Windows using
anatofuz
parents:
diff changeset
101 Visual Studio:</p>
anatofuz
parents:
diff changeset
102
anatofuz
parents:
diff changeset
103 <ol>
anatofuz
parents:
diff changeset
104 <li>Get the required tools:
anatofuz
parents:
diff changeset
105 <ul>
anatofuz
parents:
diff changeset
106 <li><b>Git</b>. Source code control program. Get it from:
anatofuz
parents:
diff changeset
107 <a href="https://git-scm.com/download">
anatofuz
parents:
diff changeset
108 https://git-scm.com/download</a></li>
anatofuz
parents:
diff changeset
109 <li><b>CMake</b>. This is used for generating Visual Studio solution and
anatofuz
parents:
diff changeset
110 project files. Get it from:
anatofuz
parents:
diff changeset
111 <a href="https://cmake.org/download/">
anatofuz
parents:
diff changeset
112 https://cmake.org/download/</a></li>
anatofuz
parents:
diff changeset
113 <li><b>Visual Studio 2017 or later</b></li>
anatofuz
parents:
diff changeset
114 <li><b>Python</b>. It is used to run the clang test suite. Get it from:
anatofuz
parents:
diff changeset
115 <a href="https://www.python.org/download/">
anatofuz
parents:
diff changeset
116 https://www.python.org/download/</a></li>
anatofuz
parents:
diff changeset
117 <li><b>GnuWin32 tools</b>
anatofuz
parents:
diff changeset
118 The Clang and LLVM test suite use various GNU core utilities, such as
anatofuz
parents:
diff changeset
119 <tt>grep</tt>, <tt>sed</tt>, and <tt>find</tt>. The gnuwin32 packages
anatofuz
parents:
diff changeset
120 are the oldest and most well-tested way to get these tools. However, the
anatofuz
parents:
diff changeset
121 MSys utilities provided by git for Windows have been known to work.
anatofuz
parents:
diff changeset
122 Cygwin has worked in the past, but is not well tested.
anatofuz
parents:
diff changeset
123 If you don't already have the core utilies from some other source, get
anatofuz
parents:
diff changeset
124 gnuwin32 from <a href="http://getgnuwin32.sourceforge.net/">
anatofuz
parents:
diff changeset
125 http://getgnuwin32.sourceforge.net/</a>.</li>
anatofuz
parents:
diff changeset
126 </ul>
anatofuz
parents:
diff changeset
127 </li>
anatofuz
parents:
diff changeset
128
anatofuz
parents:
diff changeset
129 <li>Check out LLVM and Clang:
anatofuz
parents:
diff changeset
130 <ul>
anatofuz
parents:
diff changeset
131 <li><tt>git clone https://github.com/llvm/llvm-project.git</tt></li>
anatofuz
parents:
diff changeset
132 </ul>
anatofuz
parents:
diff changeset
133 <p><em>Note</em>: Some Clang tests are sensitive to the line endings. Ensure
anatofuz
parents:
diff changeset
134 that checking out the files does not convert LF line endings to CR+LF. If
anatofuz
parents:
diff changeset
135 you're using git on Windows, make sure your <tt>core.autocrlf</tt> setting
anatofuz
parents:
diff changeset
136 is false.</p>
anatofuz
parents:
diff changeset
137 </li>
anatofuz
parents:
diff changeset
138 <li>Run CMake to generate the Visual Studio solution and project files:
anatofuz
parents:
diff changeset
139 <ul>
anatofuz
parents:
diff changeset
140 <li><tt>cd ..\..</tt> (back to where you started)</li>
anatofuz
parents:
diff changeset
141 <li><tt>mkdir build</tt> (for building without polluting the source dir)</li>
anatofuz
parents:
diff changeset
142 <li><tt>cd build</tt></li>
anatofuz
parents:
diff changeset
143 <li>
anatofuz
parents:
diff changeset
144 If you are using Visual Studio 2017:
anatofuz
parents:
diff changeset
145 <tt>cmake -DLLVM_ENABLE_PROJECTS=clang -G "Visual Studio 15 2017" -A x64 -Thost=x64 ..\llvm</tt><br/>
anatofuz
parents:
diff changeset
146 <tt>-Thost=x64</tt> is required, since the 32-bit linker will run out of memory.
anatofuz
parents:
diff changeset
147 </li>
anatofuz
parents:
diff changeset
148 <li>To generate x86 binaries instead of x64, pass <tt>-A Win32</tt>.</li>
anatofuz
parents:
diff changeset
149 <li>See the <a href="https://www.llvm.org/docs/CMake.html">LLVM CMake guide</a> for
anatofuz
parents:
diff changeset
150 more information on other configuration options for CMake.</li>
anatofuz
parents:
diff changeset
151 <li>The above, if successful, will have created an LLVM.sln file in the
anatofuz
parents:
diff changeset
152 <tt>build</tt> directory.
anatofuz
parents:
diff changeset
153 </ul>
anatofuz
parents:
diff changeset
154 </li>
anatofuz
parents:
diff changeset
155 <li>Build Clang:
anatofuz
parents:
diff changeset
156 <ul>
anatofuz
parents:
diff changeset
157 <li>Open LLVM.sln in Visual Studio.</li>
anatofuz
parents:
diff changeset
158 <li>Build the "clang" project for just the compiler driver and front end, or
anatofuz
parents:
diff changeset
159 the "ALL_BUILD" project to build everything, including tools.</li>
anatofuz
parents:
diff changeset
160 </ul>
anatofuz
parents:
diff changeset
161 </li>
anatofuz
parents:
diff changeset
162 <li>Try it out (assuming you added llvm/debug/bin to your path). (See the
anatofuz
parents:
diff changeset
163 running examples from above.)</li>
anatofuz
parents:
diff changeset
164 <li>See <a href="hacking.html#testingWindows">
anatofuz
parents:
diff changeset
165 Hacking on clang - Testing using Visual Studio on Windows</a> for information
anatofuz
parents:
diff changeset
166 on running regression tests on Windows.</li>
anatofuz
parents:
diff changeset
167 </ol>
anatofuz
parents:
diff changeset
168
anatofuz
parents:
diff changeset
169 <h3 id="buildWindowsNinja">Using Ninja alongside Visual Studio</h3>
anatofuz
parents:
diff changeset
170
anatofuz
parents:
diff changeset
171 <p>We recommend that developers who want the fastest incremental builds use the
anatofuz
parents:
diff changeset
172 <a href="https://ninja-build.org/">Ninja build system</a>. You can use the
anatofuz
parents:
diff changeset
173 generated Visual Studio project files to edit Clang source code and generate a
anatofuz
parents:
diff changeset
174 second build directory next to it for running the tests with these steps:</p>
anatofuz
parents:
diff changeset
175
anatofuz
parents:
diff changeset
176 <ol>
anatofuz
parents:
diff changeset
177 <li>Check out clang and LLVM as described above</li>
anatofuz
parents:
diff changeset
178 <li>Open a developer command prompt with the appropriate environment.
anatofuz
parents:
diff changeset
179 <ul>
anatofuz
parents:
diff changeset
180 <li>If you open the start menu and search for "Command Prompt", you should
anatofuz
parents:
diff changeset
181 see shortcuts created by Visual Studio to do this. To use native x64
anatofuz
parents:
diff changeset
182 tools, choose the one titled "x64 Native Tools Command Prompt for VS
anatofuz
parents:
diff changeset
183 2017".</li>
anatofuz
parents:
diff changeset
184 <li> Alternatively, launch a regular <tt>cmd</tt> prompt and run the
anatofuz
parents:
diff changeset
185 appropriate vcvarsall.bat incantation. To get the 2017 x64 tools, this
anatofuz
parents:
diff changeset
186 would be:<br/>
anatofuz
parents:
diff changeset
187 <tt>"C:\Program Files (x86)\Microsoft Visual
anatofuz
parents:
diff changeset
188 Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x64</tt>
anatofuz
parents:
diff changeset
189 </li>
anatofuz
parents:
diff changeset
190 </ul>
anatofuz
parents:
diff changeset
191 </li>
anatofuz
parents:
diff changeset
192 <li><tt>mkdir build_ninja</tt> (or <tt>build</tt>, or use your own
anatofuz
parents:
diff changeset
193 organization)</li>
anatofuz
parents:
diff changeset
194 <li><tt>cd build_ninja</tt></li>
anatofuz
parents:
diff changeset
195 <li><tt>set CC=cl</tt> (necessary to force CMake to choose MSVC over mingw GCC
anatofuz
parents:
diff changeset
196 if you have it installed)</li>
anatofuz
parents:
diff changeset
197 <li><tt>set CXX=cl</tt></li>
anatofuz
parents:
diff changeset
198 <li><tt>cmake -GNinja ..\llvm</tt></li>
anatofuz
parents:
diff changeset
199 <li><tt>ninja clang</tt> This will build just clang.</li>
anatofuz
parents:
diff changeset
200 <li><tt>ninja check-clang</tt> This will run the clang tests.</li>
anatofuz
parents:
diff changeset
201 </ol>
anatofuz
parents:
diff changeset
202
anatofuz
parents:
diff changeset
203 <h2 id="driver">Clang Compiler Driver (Drop-in Substitute for GCC)</h2>
anatofuz
parents:
diff changeset
204
anatofuz
parents:
diff changeset
205 <p>The <tt>clang</tt> tool is the compiler driver and front-end, which is
anatofuz
parents:
diff changeset
206 designed to be a drop-in replacement for the <tt>gcc</tt> command. Here are
anatofuz
parents:
diff changeset
207 some examples of how to use the high-level driver:
anatofuz
parents:
diff changeset
208 </p>
anatofuz
parents:
diff changeset
209
anatofuz
parents:
diff changeset
210 <pre class="code">
anatofuz
parents:
diff changeset
211 $ <b>cat t.c</b>
anatofuz
parents:
diff changeset
212 #include &lt;stdio.h&gt;
anatofuz
parents:
diff changeset
213 int main(int argc, char **argv) { printf("hello world\n"); }
anatofuz
parents:
diff changeset
214 $ <b>clang t.c</b>
anatofuz
parents:
diff changeset
215 $ <b>./a.out</b>
anatofuz
parents:
diff changeset
216 hello world
anatofuz
parents:
diff changeset
217 </pre>
anatofuz
parents:
diff changeset
218
anatofuz
parents:
diff changeset
219 <p>The 'clang' driver is designed to work as closely to GCC as possible to
anatofuz
parents:
diff changeset
220 maximize portability. The only major difference between the two is that
anatofuz
parents:
diff changeset
221 Clang defaults to gnu99 mode while GCC defaults to gnu89 mode. If you see
anatofuz
parents:
diff changeset
222 weird link-time errors relating to inline functions, try passing -std=gnu89
anatofuz
parents:
diff changeset
223 to clang.</p>
anatofuz
parents:
diff changeset
224
anatofuz
parents:
diff changeset
225 <h2>Examples of using Clang</h2>
anatofuz
parents:
diff changeset
226
anatofuz
parents:
diff changeset
227 <!-- Thanks to
anatofuz
parents:
diff changeset
228 http://shiflett.org/blog/2006/oct/formatting-and-highlighting-php-code-listings
anatofuz
parents:
diff changeset
229 Site suggested using pre in CSS, but doesn't work in IE, so went for the <pre>
anatofuz
parents:
diff changeset
230 tag. -->
anatofuz
parents:
diff changeset
231
anatofuz
parents:
diff changeset
232 <pre class="code">
anatofuz
parents:
diff changeset
233 $ <b>cat ~/t.c</b>
anatofuz
parents:
diff changeset
234 typedef float V __attribute__((vector_size(16)));
anatofuz
parents:
diff changeset
235 V foo(V a, V b) { return a+b*a; }
anatofuz
parents:
diff changeset
236 </pre>
anatofuz
parents:
diff changeset
237
anatofuz
parents:
diff changeset
238
anatofuz
parents:
diff changeset
239 <h3>Preprocessing:</h3>
anatofuz
parents:
diff changeset
240
anatofuz
parents:
diff changeset
241 <pre class="code">
anatofuz
parents:
diff changeset
242 $ <b>clang ~/t.c -E</b>
anatofuz
parents:
diff changeset
243 # 1 "/Users/sabre/t.c" 1
anatofuz
parents:
diff changeset
244
anatofuz
parents:
diff changeset
245 typedef float V __attribute__((vector_size(16)));
anatofuz
parents:
diff changeset
246
anatofuz
parents:
diff changeset
247 V foo(V a, V b) { return a+b*a; }
anatofuz
parents:
diff changeset
248 </pre>
anatofuz
parents:
diff changeset
249
anatofuz
parents:
diff changeset
250
anatofuz
parents:
diff changeset
251 <h3>Type checking:</h3>
anatofuz
parents:
diff changeset
252
anatofuz
parents:
diff changeset
253 <pre class="code">
anatofuz
parents:
diff changeset
254 $ <b>clang -fsyntax-only ~/t.c</b>
anatofuz
parents:
diff changeset
255 </pre>
anatofuz
parents:
diff changeset
256
anatofuz
parents:
diff changeset
257
anatofuz
parents:
diff changeset
258 <h3>GCC options:</h3>
anatofuz
parents:
diff changeset
259
anatofuz
parents:
diff changeset
260 <pre class="code">
anatofuz
parents:
diff changeset
261 $ <b>clang -fsyntax-only ~/t.c -pedantic</b>
anatofuz
parents:
diff changeset
262 /Users/sabre/t.c:2:17: <span style="color:magenta">warning:</span> extension used
anatofuz
parents:
diff changeset
263 <span style="color:darkgreen">typedef float V __attribute__((vector_size(16)));</span>
anatofuz
parents:
diff changeset
264 <span style="color:blue"> ^</span>
anatofuz
parents:
diff changeset
265 1 diagnostic generated.
anatofuz
parents:
diff changeset
266 </pre>
anatofuz
parents:
diff changeset
267
anatofuz
parents:
diff changeset
268
anatofuz
parents:
diff changeset
269 <h3>Pretty printing from the AST:</h3>
anatofuz
parents:
diff changeset
270
anatofuz
parents:
diff changeset
271 <p>Note, the <tt>-cc1</tt> argument indicates the compiler front-end, and
anatofuz
parents:
diff changeset
272 not the driver, should be run. The compiler front-end has several additional
anatofuz
parents:
diff changeset
273 Clang specific features which are not exposed through the GCC compatible driver
anatofuz
parents:
diff changeset
274 interface.</p>
anatofuz
parents:
diff changeset
275
anatofuz
parents:
diff changeset
276 <pre class="code">
anatofuz
parents:
diff changeset
277 $ <b>clang -cc1 ~/t.c -ast-print</b>
anatofuz
parents:
diff changeset
278 typedef float V __attribute__(( vector_size(16) ));
anatofuz
parents:
diff changeset
279 V foo(V a, V b) {
anatofuz
parents:
diff changeset
280 return a + b * a;
anatofuz
parents:
diff changeset
281 }
anatofuz
parents:
diff changeset
282 </pre>
anatofuz
parents:
diff changeset
283
anatofuz
parents:
diff changeset
284
anatofuz
parents:
diff changeset
285 <h3>Code generation with LLVM:</h3>
anatofuz
parents:
diff changeset
286
anatofuz
parents:
diff changeset
287 <pre class="code">
anatofuz
parents:
diff changeset
288 $ <b>clang ~/t.c -S -emit-llvm -o -</b>
anatofuz
parents:
diff changeset
289 define &lt;4 x float&gt; @foo(&lt;4 x float&gt; %a, &lt;4 x float&gt; %b) {
anatofuz
parents:
diff changeset
290 entry:
anatofuz
parents:
diff changeset
291 %mul = mul &lt;4 x float&gt; %b, %a
anatofuz
parents:
diff changeset
292 %add = add &lt;4 x float&gt; %mul, %a
anatofuz
parents:
diff changeset
293 ret &lt;4 x float&gt; %add
anatofuz
parents:
diff changeset
294 }
anatofuz
parents:
diff changeset
295 $ <b>clang -fomit-frame-pointer -O3 -S -o - t.c</b> <i># On x86_64</i>
anatofuz
parents:
diff changeset
296 ...
anatofuz
parents:
diff changeset
297 _foo:
anatofuz
parents:
diff changeset
298 Leh_func_begin1:
anatofuz
parents:
diff changeset
299 mulps %xmm0, %xmm1
anatofuz
parents:
diff changeset
300 addps %xmm1, %xmm0
anatofuz
parents:
diff changeset
301 ret
anatofuz
parents:
diff changeset
302 Leh_func_end1:
anatofuz
parents:
diff changeset
303 </pre>
anatofuz
parents:
diff changeset
304
anatofuz
parents:
diff changeset
305 </div>
anatofuz
parents:
diff changeset
306 </body>
anatofuz
parents:
diff changeset
307 </html>