d17747ef806c8ac256cfb3ad82e774d1d473f770
[oota-llvm.git] / docs / ReleaseNotes.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
2                       "http://www.w3.org/TR/html4/strict.dtd">
3 <html>
4 <head>
5   <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
6   <meta encoding="utf8">
7   <link rel="stylesheet" href="llvm.css" type="text/css">
8   <title>LLVM 2.9 Release Notes</title>
9 </head>
10 <body>
11
12 <h1 class="doc_title">LLVM 2.9 Release Notes</h1>
13
14 <img align=right src="http://llvm.org/img/DragonSmall.png"
15     width="136" height="136" alt="LLVM Dragon Logo">
16
17 <ol>
18   <li><a href="#intro">Introduction</a></li>
19   <li><a href="#subproj">Sub-project Status Update</a></li>
20   <li><a href="#externalproj">External Projects Using LLVM 2.9</a></li>
21   <li><a href="#whatsnew">What's New in LLVM 2.9?</a></li>
22   <li><a href="GettingStarted.html">Installation Instructions</a></li>
23   <li><a href="#knownproblems">Known Problems</a></li>
24   <li><a href="#additionalinfo">Additional Information</a></li>
25 </ol>
26
27 <div class="doc_author">
28   <p>Written by the <a href="http://llvm.org">LLVM Team</a></p>
29 </div>
30
31 <h1 style="color:red">These are in-progress notes for the upcoming LLVM 2.9
32 release.<br>
33 You may prefer the
34 <a href="http://llvm.org/releases/2.8/docs/ReleaseNotes.html">LLVM 2.8
35 Release Notes</a>.</h1>
36
37 <!-- *********************************************************************** -->
38 <h1>
39   <a name="intro">Introduction</a>
40 </h1>
41 <!-- *********************************************************************** -->
42
43 <div class="doc_text">
44
45 <p>This document contains the release notes for the LLVM Compiler
46 Infrastructure, release 2.9.  Here we describe the status of LLVM, including
47 major improvements from the previous release and significant known problems.
48 All LLVM releases may be downloaded from the <a
49 href="http://llvm.org/releases/">LLVM releases web site</a>.</p>
50
51 <p>For more information about LLVM, including information about the latest
52 release, please check out the <a href="http://llvm.org/">main LLVM
53 web site</a>.  If you have questions or comments, the <a
54 href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev">LLVM Developer's
55 Mailing List</a> is a good place to send them.</p>
56
57 <p>Note that if you are reading this file from a Subversion checkout or the
58 main LLVM web page, this document applies to the <i>next</i> release, not the
59 current one.  To see the release notes for a specific release, please see the
60 <a href="http://llvm.org/releases/">releases page</a>.</p>
61
62 </div>
63    
64 <!-- Features that need text if they're finished for 3.1:
65   ARM EHABI
66   combiner-aa?
67   strong phi elim
68   loop dependence analysis
69   CorrelatedValuePropagation
70   lib/Transforms/IPO/MergeFunctions.cpp => consider for 3.1.
71  -->
72  
73 <!-- *********************************************************************** -->
74 <h1>
75   <a name="subproj">Sub-project Status Update</a>
76 </h1>
77 <!-- *********************************************************************** -->
78
79 <div class="doc_text">
80 <p>
81 The LLVM 2.9 distribution currently consists of code from the core LLVM
82 repository (which roughly includes the LLVM optimizers, code generators
83 and supporting tools), the Clang repository and the llvm-gcc repository.  In
84 addition to this code, the LLVM Project includes other sub-projects that are in
85 development.  Here we include updates on these subprojects.
86 </p>
87
88 </div>
89
90
91 <!--=========================================================================-->
92 <h2>
93 <a name="clang">Clang: C/C++/Objective-C Frontend Toolkit</a>
94 </h2>
95
96 <div class="doc_text">
97
98 <p><a href="http://clang.llvm.org/">Clang</a> is an LLVM front end for the C,
99 C++, and Objective-C languages. Clang aims to provide a better user experience
100 through expressive diagnostics, a high level of conformance to language
101 standards, fast compilation, and low memory use. Like LLVM, Clang provides a
102 modular, library-based architecture that makes it suitable for creating or
103 integrating with other development tools. Clang is considered a
104 production-quality compiler for C, Objective-C, C++ and Objective-C++ on x86
105 (32- and 64-bit), and for darwin/arm targets.</p>
106
107 <p>In the LLVM 2.9 time-frame, the Clang team has made many improvements in C,
108 C++ and Objective-C support.  C++ support is now generally rock solid, has
109 been exercised on a broad variety of code, and has several new <a 
110 href="http://clang.llvm.org/cxx_status.html#cxx0x">C++'0x features</a>
111 implemented (such as rvalue references and variadic templates).  LLVM 2.9 has
112 also brought in a large range of bug fixes and minor features (e.g. __label__
113 support), and is much more compatible with the Linux Kernel.</p>  
114   
115 <p>If Clang rejects your code that is built with another compiler, please take a
116 look at the <a href="http://clang.llvm.org/compatibility.html">language
117 compatibility</a> guide to make sure the issue isn't intentional or a known
118 issue.
119 </p>
120
121 <ul>
122 </ul>
123 </div>
124
125 <!--=========================================================================-->
126 <h2>
127 <a name="dragonegg">DragonEgg: GCC front-ends, LLVM back-end</a>
128 </h2>
129
130 <div class="doc_text">
131 <p>
132 <a href="http://dragonegg.llvm.org/">DragonEgg</a> is a
133 <a href="http://gcc.gnu.org/wiki/plugins">gcc plugin</a> that replaces GCC's
134 optimizers and code generators with LLVM's.
135 Currently it requires a patched version of gcc-4.5.
136 The plugin can target the x86-32 and x86-64 processor families and has been
137 used successfully on the Darwin, FreeBSD and Linux platforms.
138 The Ada, C, C++ and Fortran languages work well.
139 The plugin is capable of compiling plenty of Obj-C, Obj-C++ and Java but it is
140 not known whether the compiled code actually works or not!
141 </p>
142
143 <p>
144 The 2.9 release has the following notable changes:
145 <ul>
146 <li>The plugin is much more stable when compiling Fortran.</li>
147 <li>Inline assembly where an asm output is tied to an input of a different size
148 is now supported in many more cases.</li>
149 <li>Basic support for the __float128 type was added.  It is now possible to
150 generate LLVM IR from programs using __float128 but code generation does not
151 work yet.</li>
152 <li>Compiling Java programs no longer systematically crashes the plugin.</li>
153 </ul>
154
155 </div>
156
157 <!--=========================================================================-->
158 <h2>
159 <a name="compiler-rt">compiler-rt: Compiler Runtime Library</a>
160 </h2>
161
162 <div class="doc_text">
163 <p>
164 The new LLVM <a href="http://compiler-rt.llvm.org/">compiler-rt project</a>
165 is a simple library that provides an implementation of the low-level
166 target-specific hooks required by code generation and other runtime components.
167 For example, when compiling for a 32-bit target, converting a double to a 64-bit
168 unsigned integer is compiled into a runtime call to the "__fixunsdfdi"
169 function. The compiler-rt library provides highly optimized implementations of
170 this and other low-level routines (some are 3x faster than the equivalent
171 libgcc routines).</p>
172
173 <p>In the LLVM 2.9 timeframe, compiler_rt has had several minor changes for
174   better ARM support, and a fairly major license change.  All of the code in the
175   compiler-rt project is now <a href="DeveloperPolicy.html#license">dual
176   licensed</a> under MIT and UIUC license, which allows you to use compiler-rt
177   in applications without the binary copyright reproduction clause.  If you
178   prefer the LLVM/UIUC license, you are free to continue using it under that
179   license as well.</p>
180
181 </div>
182
183 <!--=========================================================================-->
184 <h2>
185 <a name="lldb">LLDB: Low Level Debugger</a>
186 </h2>
187
188 <div class="doc_text">
189 <p>
190 <a href="http://lldb.llvm.org/">LLDB</a> is a brand new member of the LLVM
191 umbrella of projects. LLDB is a next generation, high-performance debugger. It
192 is built as a set of reusable components which highly leverage existing
193 libraries in the larger LLVM Project, such as the Clang expression parser, the
194 LLVM disassembler and the LLVM JIT.</p>
195
196 <p>
197 LLDB is has advanced by leaps and bounds in the 2.9 timeframe.  It is
198 dramatically more stable and useful, and includes both a new <a 
199 href="http://lldb.llvm.org/tutorial.html">tutorial</a> and a <a
200 href="http://lldb.llvm.org/lldb-gdb.html">side-by-side comparison with 
201 GDB</a>.</p>
202
203 </div>
204
205 <!--=========================================================================-->
206 <h2>
207 <a name="libc++">libc++: C++ Standard Library</a>
208 </h2>
209
210 <div class="doc_text">
211 <p>
212 <a href="http://libcxx.llvm.org/">libc++</a> is another new member of the LLVM
213 family.  It is an implementation of the C++ standard library, written from the
214 ground up to specifically target the forthcoming C++'0X standard and focus on
215 delivering great performance.</p>
216
217 <p>
218 In the LLVM 2.9 timeframe, libc++ has had numerous bugs fixed, and is now being
219 co-developed with Clang's C++'0x mode.</p>
220   
221 <p>
222 Like compiler_rt, libc++ is now <a href="DeveloperPolicy.html#license">dual
223   licensed</a> under the MIT and UIUC license, allowing it to be used more
224   permissively.
225 </p>
226
227 </div>
228
229
230
231 <!--=========================================================================-->
232 <!--
233 <h2>
234 <a name="klee">KLEE: A Symbolic Execution Virtual Machine</a>
235 </h2>
236
237 <div class="doc_text">
238 <p>
239 <a href="http://klee.llvm.org/">KLEE</a> is a symbolic execution framework for
240 programs in LLVM bitcode form. KLEE tries to symbolically evaluate "all" paths
241 through the application and records state transitions that lead to fault
242 states. This allows it to construct testcases that lead to faults and can even
243 be used to verify some algorithms.
244 </p>
245
246 <p>UPDATE!</p>
247 </div>-->
248
249
250 <!-- *********************************************************************** -->
251 <h1>
252   <a name="externalproj">External Open Source Projects Using LLVM 2.9</a>
253 </h1>
254 <!-- *********************************************************************** -->
255
256 <div class="doc_text">
257
258 <p>An exciting aspect of LLVM is that it is used as an enabling technology for
259    a lot of other language and tools projects.  This section lists some of the
260    projects that have already been updated to work with LLVM 2.9.</p>
261 </div>
262
263
264 <!--=========================================================================-->
265 <h2>Crack Programming Language</h2>
266
267 <div class="doc_text">
268 <p>
269 <a href="http://code.google.com/p/crack-language/">Crack</a> aims to provide the
270 ease of development of a scripting language with the performance of a compiled
271 language. The language derives concepts from C++, Java and Python, incorporating
272 object-oriented programming, operator overloading and strong typing.</p>
273 </div>
274   
275   
276 <!--=========================================================================-->
277 <h2>TTA-based Codesign Environment (TCE)</h2>
278   
279 <div class="doc_text">
280 <p>TCE is a toolset for designing application-specific processors (ASP) based on
281 the Transport triggered architecture (TTA). The toolset provides a complete
282 co-design flow from C/C++ programs down to synthesizable VHDL and parallel
283 program binaries. Processor customization points include the register files,
284 function units, supported operations, and the interconnection network.</p>
285   
286 <p>TCE uses Clang and LLVM for C/C++ language support, target independent
287 optimizations and also for parts of code generation. It generates new LLVM-based
288 code generators "on the fly" for the designed TTA processors and loads them in
289 to the compiler backend as runtime libraries to avoid per-target recompilation
290 of larger parts of the compiler chain.</p>
291 </div>
292
293
294   
295 <!--=========================================================================-->
296 <h2>PinaVM</h2>
297   
298 <div class="doc_text">
299 <p><a href="http://gitorious.org/pinavm/pages/Home">PinaVM</a> is an open
300 source, <a href="http://www.systemc.org/">SystemC</a> front-end. Unlike many
301 other front-ends, PinaVM actually executes the elaboration of the
302 program analyzed using LLVM's JIT infrastructure. It later enriches the
303 bitcode with SystemC-specific information.</p>
304 </div>
305
306 <!--=========================================================================-->
307 <h2>Pure</h2>
308   
309 <div class="doc_text">
310 <p><a href="http://pure-lang.googlecode.com/">Pure</a> is an
311   algebraic/functional
312   programming language based on term rewriting. Programs are collections
313   of equations which are used to evaluate expressions in a symbolic
314   fashion. The interpreter uses LLVM as a backend to JIT-compile Pure
315   programs to fast native code. Pure offers dynamic typing, eager and lazy
316   evaluation, lexical closures, a hygienic macro system (also based on
317   term rewriting), built-in list and matrix support (including list and
318   matrix comprehensions) and an easy-to-use interface to C and other
319   programming languages (including the ability to load LLVM bitcode
320   modules, and inline C, C++, Fortran and Faust code in Pure programs if
321   the corresponding LLVM-enabled compilers are installed).</p>
322   
323 <p>Pure version 0.47 has been tested and is known to work with LLVM 2.9
324   (and continues to work with older LLVM releases &gt;= 2.5).</p>
325 </div>
326
327 <!--=========================================================================-->
328 <h2 id="icedtea">IcedTea Java Virtual Machine Implementation</h2>
329
330 <div class="doc_text">
331 <p>
332 <a href="http://icedtea.classpath.org/wiki/Main_Page">IcedTea</a> provides a
333 harness to build OpenJDK using only free software build tools and to provide
334 replacements for the not-yet free parts of OpenJDK.  One of the extensions that
335 IcedTea provides is a new JIT compiler named <a
336 href="http://icedtea.classpath.org/wiki/ZeroSharkFaq">Shark</a> which uses LLVM
337 to provide native code generation without introducing processor-dependent
338 code.
339 </p>
340
341 <p> OpenJDK 7 b112, IcedTea6 1.9 and IcedTea7 1.13 and later have been tested
342 and are known to work with LLVM 2.9 (and continue to work with older LLVM
343 releases &gt;= 2.6 as well).</p>
344 </div>
345
346 <!--=========================================================================-->
347 <h2>Glasgow Haskell Compiler (GHC)</h2>
348   
349 <div class="doc_text">
350 <p>GHC is an open source, state-of-the-art programming suite for Haskell,
351 a standard lazy functional programming language. It includes an
352 optimizing static compiler generating good code for a variety of
353 platforms, together with an interactive system for convenient, quick
354 development.</p>
355
356 <p>In addition to the existing C and native code generators, GHC 7.0 now
357 supports an LLVM code generator. GHC supports LLVM 2.7 and later.</p>
358 </div>
359
360 <!--=========================================================================-->
361 <h2>Polly - Polyhedral optimizations for LLVM</h2>
362   
363 <div class="doc_text">
364 <p>Polly is a project that aims to provide advanced memory access optimizations
365 to better take advantage of SIMD units, cache hierarchies, multiple cores or
366 even vector accelerators for LLVM. Built around an abstract mathematical
367 description based on Z-polyhedra, it provides the infrastructure to develop
368 advanced optimizations in LLVM and to connect complex external optimizers. In
369 its first year of existence Polly already provides an exact value-based
370 dependency analysis as well as basic SIMD and OpenMP code generation support.
371 Furthermore, Polly can use PoCC(Pluto) an advanced optimizer for data-locality
372 and parallelism.</p>
373 </div>
374
375
376 <!-- *********************************************************************** -->
377 <h1>
378   <a name="whatsnew">What's New in LLVM 2.9?</a>
379 </h1>
380 <!-- *********************************************************************** -->
381
382 <div class="doc_text">
383
384 <p>This release includes a huge number of bug fixes, performance tweaks and
385 minor improvements.  Some of the major improvements and new features are listed
386 in this section.
387 </p>
388
389 </div>
390
391 <!--=========================================================================-->
392 <h2>
393 <a name="majorfeatures">Major New Features</a>
394 </h2>
395
396 <div class="doc_text">
397
398 <p>LLVM 2.9 includes several major new capabilities:</p>
399
400 <ul>
401   
402 <li>
403   TBAA: On by default in clang.  Disable it with -fno-strict-aliasing.
404   Could be more aggressive for structs.
405 </li>
406
407 <li>New Nvidia PTX backend, not generally useful in 2.9 though.</li>
408   
409 <li>
410 Much better debug info generated, particularly in optimized code situations.
411 </li>
412
413 <li>
414 inline asm multiple alternative constraint support.
415 </li>  
416   
417 <li>
418   New naming rules in coding standards: CodingStandards.html#ll_naming
419 </li>
420
421 </ul>
422   
423 </div>
424
425 <!--=========================================================================-->
426 <h2>
427 <a name="coreimprovements">LLVM IR and Core Improvements</a>
428 </h2>
429
430 <div class="doc_text">
431 <p>LLVM IR has several new features for better support of new targets and that
432 expose new optimization opportunities:</p>
433
434 <ul>
435 <li>udiv, ashr, lshr, shl now have exact and nuw/nsw bits:
436   PR8862 / LangRef.html</li>
437   
438   unnamed_addr + PR8927
439
440   new 'hotpatch' attribute: LangRef.html#fnattrs
441
442 </ul>
443
444 </div>
445
446 <!--=========================================================================-->
447 <h2>
448 <a name="optimizer">Optimizer Improvements</a>
449 </h2>
450
451 <div class="doc_text">
452
453 <p>In addition to a large array of minor performance tweaks and bug fixes, this
454 release includes a few major enhancements and additions to the optimizers:</p>
455
456 <ul>
457   <li>LTO has been improved to use MC for parsing inline asm and now
458   can build large programs like Firefox 4 on both OS X and Linux.</li>
459   
460   
461  LoopIdiom: memset/memcpy formation and memset_pattern on darwin.  Build with
462   -ffreestanding or -fno-builtin if your memcpy is being compiled into infinite
463   recursion.
464   
465   TargetLibraryInfo
466     
467   EarlyCSE pass.
468   LoopInstSimplify pass.
469     
470 New <a href="WritingAnLLVMPass.html#RegionPass">RegionPass</a> infrastructure
471   for region-based optimizations.
472   
473   Can optimize printf to iprintf when no floating point is used, for embedded
474   targets with smaller iprintf implementation.
475
476 Speedups to various mid-level passes:
477   GVN is much faster on functions with deep dominator trees / lots of BBs.
478   DomTree and DominatorFrontier are much faster to compute, and preserved by
479     more passes (so they are computed less often)
480   SRoA is also much faster and doesn't use DominanceFrontier.
481   
482 DSE is more aggressive with stores of different types: e.g. a large store 
483   following a small one to the same address.
484   
485   
486 We now optimize various idioms for overflow detection into check of the flag
487   register on various CPUs, e.g.:
488    unsigned long t = a+b;
489    if (t &lt; a) ...
490   into:
491         addq    %rdi, %rbx
492         jno     LBB0_2
493
494   
495 </ul>
496
497 <!--
498 <p>In addition to these features that are done in 2.8, there is preliminary
499    support in the release for Type Based Alias Analysis 
500   Preliminary work on TBAA but not usable in 2.8.
501   New CorrelatedValuePropagation pass, not on by default in 2.8 yet.
502 -->
503
504 </div>
505
506 <!--=========================================================================-->
507 <h2>
508 <a name="mc">MC Level Improvements</a>
509 </h2>
510
511 <div class="doc_text">
512 <p>
513 The LLVM Machine Code (aka MC) subsystem was created to solve a number
514 of problems in the realm of assembly, disassembly, object file format handling,
515 and a number of other related areas that CPU instruction-set level tools work
516 in.</p>
517
518 <ul>
519   <li>MC is now used by default for ELF systems on x86 and
520   x86-64.</li>
521   <li>MC supports and CodeGen uses the <tt>.loc</tt> directives for
522   producing line number debug info. This produces more compact line
523   tables.</li>
524   <li>MC supports the <tt>.cfi_*</tt> directives for producing DWARF
525   frame information, but it is still not used by CodeGen by default.</li>
526   <li>COFF support?</li>
527   
528   
529   MC Assembler: X86 now generates much better diagnostics for common errors,
530   is much faster at matching instructions, is much more bug-compatible with
531   the GAS assembler, and is now generally useful for a broad range of X86
532   assembly.
533   
534   
535   ELF MC support: on by default in clang.  There are still known missing features
536   for human written assembly.
537   
538   
539   Some basic <a href="CodeGenerator.html#mc">internals documentation</a> for MC. 
540   
541   MC Assembler support for .file and .loc.
542   
543   tblgen support for assembler aliases: <a 
544     href="CodeGenerator.html#na_instparsing">MnemonicAlias and InstAlias</a>
545   
546   Win32 PE-COFF support in the MC assembler has made a lot of progress in the 2.9
547   timeframe, but is still not generally useful.  Please see 
548   "http://llvm.org/bugs/showdependencytree.cgi?id=9100&amp;hide_resolved=1" for open bugs?
549   
550   
551   lib/Object and llvm-objdump
552   Experimental format independent object file manipulation library.
553   * Supports PE/COFF and ELF.
554   * llvm-nm extended to work with object files. Exactly matches
555   binutils-nm for the files I've tested.
556   * llvm-objdump added with support for disassembly (no relocations displayed).
557   
558
559
560 </ul>
561
562 <p>For more information, please see the <a
563 href="http://blog.llvm.org/2010/04/intro-to-llvm-mc-project.html">Intro to the
564 LLVM MC Project Blog Post</a>.
565 </p>
566
567 </div>
568
569 <!--=========================================================================-->
570 <h2>
571 <a name="codegen">Target Independent Code Generator Improvements</a>
572 </h2>
573
574 <div class="doc_text">
575
576 <p>We have put a significant amount of work into the code generator
577 infrastructure, which allows us to implement more aggressive algorithms and make
578 it run faster:</p>
579
580 <ul>
581 <!-- SplitKit -->
582   
583 <li>The pre-register-allocation (preRA) instruction scheduler models register
584   pressure much more accurately in some cases. This allows the adoption of more
585     aggressive scheduling heuristics.
586 </li>
587   
588   LiveDebugVariables is a new pass that keeps track of debugging information for
589   user variables that are kept in registers in optimized builds.
590   
591
592 Scheduler now models operand latency and pipeline forwarding.
593   
594 Major regalloc rewrite, not on by default for 2.9 and not advised to use it.
595  * New basic register allocator that can be used as a safe fallback when
596    debugging. Enable with -regalloc=basic.
597  * New infrastructure for live range splitting. SplitKit can break a live
598    interval into smaller pieces while preserving SSA form, and SpillPlacement
599    can help find the best split points. This is a work in progress so the API
600    is changing quickly.
601  * The inline spiller has learned to clean up after live range splitting. It
602    can hoist spills out of loops, and it can eliminate redundant spills.
603    Rematerialization works with live range splitting.
604  * New greedy register allocator using live range splitting. This will be the
605    default register allocator in the next LLVM release, but it is not turned on
606    by default in 2.9.
607
608
609
610 </ul>
611 </div>
612
613 <!--=========================================================================-->
614 <h2>
615 <a name="x86">X86-32 and X86-64 Target Improvements</a>
616 </h2>
617
618 <div class="doc_text">
619 <p>New features and major changes in the X86 target include:
620 </p>
621
622 <ul>
623 <li>
624 X86: Reimplemented all of MMX to introduce a new LLVM IR x86_mmx type.  Now
625   random types like &lt;2 x i32&gt; are not iseld to mmx without emms.  The
626   -disable-mmx flag is gone now.
627 </li>
628   
629   <li>
630 X86 support for FS/GS relative loads and stores using address space 256/257 are
631   reliable now.
632   </li>
633   
634     <li>
635 X86: Much better codegen for several cases using adc/sbb instead of cmovs for
636   conditional increment and other idioms.
637     </li>
638
639   <li>
640   The X86 backend has adopted a new preRA scheduling
641   mode, "list-ilp", to shorten the height of instruction schedules
642   without inducing register spills.
643   </li>
644
645   MC assembler support for 3dNow! and 3DNowA instructions.
646   
647   <li>Several bugs have been fixed for Windows x64 code generator.</li>
648 </ul>
649
650 </div>
651
652 <!--=========================================================================-->
653 <h2>
654 <a name="ARM">ARM Target Improvements</a>
655 </h2>
656
657 <div class="doc_text">
658 <p>New features of the ARM target include:
659 </p>
660
661 <ul>
662 <li>ARM Fast ISel</li>
663 <li>ARM: New code placement pass.</li>
664 <li>ARM: Improved code generation for Cortex-A8 and Cortex-A9 CPUs.</li>
665 <li>ARM: __builtin_prefetch turns into prefetch instructions.</li>
666 <li>Countless ARM microoptimizations.</li>
667
668 <li>  The ARM backend preRA scheduler now models machine resources at cycle
669   granularity. This allows the scheduler to both accurately model
670   instruction latency and avoid overcommitting functional units.</li>
671
672
673 </ul>
674 </div>
675   
676 <!--=========================================================================-->
677 <h2>
678 <a name="OtherTS">Other Target Specific Improvements</a>
679 </h2>
680
681 <div class="doc_text">
682 <ul>
683   PPC: Switched to MCInstPrinter, and MCCodeEmitter.  Ready to implement support
684   for directly writing out mach-o object files, but noone seems interested.
685   
686   MicroBlaze: major updates for aggressive delay slot filler, MC-based assembly
687   printing, assembly instruction parsing, ELF .o file emission, and MC
688   instruction disassembler.
689   
690   SPARC: Many improvements, including using the Y registers for multiplications
691   and addition of a simple delay slot filler.
692   
693 </ul>
694 </div>
695
696 <!--=========================================================================-->
697 <h2>
698 <a name="changes">Major Changes and Removed Features</a>
699 </h2>
700
701 <div class="doc_text">
702
703 <p>If you're already an LLVM user or developer with out-of-tree changes based
704 on LLVM 2.8, this section lists some "gotchas" that you may run into upgrading
705 from the previous release.</p>
706
707 <ul>
708   last release for llvm-gcc
709
710 - DIBuilder provides simpler interface for front ends like Clang to encode debug info in LLVM IR.
711   - This interface hides implementation details (e.g. DIDerivedType, existence of compile unit etc..) that any front end should not know about.
712   For example, DIFactory DebugFactory;
713   Ty = DebugFactory.CreateDerivedType(DW_TAG_volatile_type,
714   findRegion(TYPE_CONTEXT(type)),
715   StringRef(),
716   getOrCreateFile(main_input_filename),
717   0 /*line no*/,
718   NodeSizeInBits(type),
719   NodeAlignInBits(type),
720   0 /*offset */,
721   0 /* flags */,
722   MainTy);
723   can be replaced by
724   DbgTy = DBuilder.createQualifiedType(DW_TAG_volatile_type, MainTy); 
725 DIFactory is gone now.
726   
727     
728
729
730
731   
732   LoopIndexSplit pass was removed, unmaintained.
733   LiveValues, SimplifyHalfPowrLibCalls, and GEPSplitter were removed.
734   Removed the PartialSpecialization pass, it was unmaintained and buggy.
735   
736   DIFactory removed, use DIBuilder instead.
737   
738   Triple::normalize is new, llvm triples are always stored in normalized form internally.
739   
740   Triple x86_64--mingw64 is obsoleted. Use x86_64--mingw32 instead.
741
742   PointerTracking has been removed from mainline, moved to ClamAV.
743
744 </ul>
745
746 </div>
747
748 <!--=========================================================================-->
749 <h2>
750 <a name="api_changes">Internal API Changes</a>
751 </h2>
752
753 <div class="doc_text">
754
755 <p>In addition, many APIs have changed in this release.  Some of the major
756   LLVM API changes are:</p>
757
758 <ul>
759   
760   include/llvm/System merged into include/llvm/Support.
761   
762   
763   APInt API changes, see PR5207.
764   
765   MVT::Flag renamed to MVT::Glue
766   
767   
768   error_code + libsystem + PathV2 changes
769   The system_error header from C++0x was added.
770   * Use if (error_code ec = function()) to check for error conditions
771   from functions which return it.
772   * error_code::message returns a human readable description of the error.
773   
774   PathV1 has been deprecated in favor of PathV2 (sorry I didn't finish
775   this before the release).
776   * No Path class, use a r-value convertible to a twine instead.
777   * Assumes all paths are UTF-8.
778   
779
780 </ul>
781 </div>
782
783 <!-- *********************************************************************** -->
784 <h1>
785   <a name="knownproblems">Known Problems</a>
786 </h1>
787 <!-- *********************************************************************** -->
788
789 <div class="doc_text">
790
791 <p>This section contains significant known problems with the LLVM system,
792 listed by component.  If you run into a problem, please check the <a
793 href="http://llvm.org/bugs/">LLVM bug database</a> and submit a bug if
794 there isn't already one.</p>
795
796 </div>
797
798 <!-- ======================================================================= -->
799 <h2>
800   <a name="experimental">Experimental features included with this release</a>
801 </h2>
802
803 <div class="doc_text">
804
805 <p>The following components of this LLVM release are either untested, known to
806 be broken or unreliable, or are in early development.  These components should
807 not be relied on, and bugs should not be filed against them, but they may be
808 useful to some people.  In particular, if you would like to work on one of these
809 components, please contact us on the <a
810 href="http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev">LLVMdev list</a>.</p>
811
812 <ul>
813 <li>The Alpha, Blackfin, CellSPU, MicroBlaze, MSP430, MIPS, PTX, SystemZ
814     and XCore backends are experimental.</li>
815 <li><tt>llc</tt> "<tt>-filetype=obj</tt>" is experimental on all targets
816     other than darwin-i386 and darwin-x86_64. FIXME: Not true on ELF anymore?</li>
817     
818 </ul>
819
820 </div>
821
822 <!-- ======================================================================= -->
823 <h2>
824   <a name="x86-be">Known problems with the X86 back-end</a>
825 </h2>
826
827 <div class="doc_text">
828
829 <ul>
830   <li>The X86 backend does not yet support
831     all <a href="http://llvm.org/PR879">inline assembly that uses the X86
832     floating point stack</a>.  It supports the 'f' and 't' constraints, but not
833     'u'.</li>
834   <li>The X86-64 backend does not yet support the LLVM IR instruction
835       <tt>va_arg</tt>. Currently, front-ends support variadic
836       argument constructs on X86-64 by lowering them manually.</li>
837   <li>Windows x64 (aka Win64) code generator has a few issues.
838     <ul>
839       <li>llvm-gcc cannot build the mingw-w64 runtime currently
840        due to lack of support for the 'u' inline assembly
841        constraint and for X87 floating point inline assembly.</li>
842       <li>On mingw-w64, you will see unresolved symbol <tt>__chkstk</tt>
843        due to <a href="http://llvm.org/bugs/show_bug.cgi?id=8919">Bug 8919</a>.
844        It is fixed in <a href="http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20110321/118499.html">r128206</a>.</li>
845       <li>Miss-aligned MOVDQA might crash your program. It is due to
846        <a href="http://llvm.org/bugs/show_bug.cgi?id=9483">Bug 9483</a>,
847        lack of handling aligned internal globals.</li>
848       </ul>
849   </li>
850
851 </ul>
852
853 </div>
854
855 <!-- ======================================================================= -->
856 <h2>
857   <a name="ppc-be">Known problems with the PowerPC back-end</a>
858 </h2>
859
860 <div class="doc_text">
861
862 <ul>
863 <li>The Linux PPC32/ABI support needs testing for the interpreter and static
864 compilation, and lacks support for debug information.</li>
865 </ul>
866
867 </div>
868
869 <!-- ======================================================================= -->
870 <h2>
871   <a name="arm-be">Known problems with the ARM back-end</a>
872 </h2>
873
874 <div class="doc_text">
875
876 <ul>
877 <li>Thumb mode works only on ARMv6 or higher processors. On sub-ARMv6
878 processors, thumb programs can crash or produce wrong
879 results (<a href="http://llvm.org/PR1388">PR1388</a>).</li>
880 <li>Compilation for ARM Linux OABI (old ABI) is supported but not fully tested.
881 </li>
882 </ul>
883
884 </div>
885
886 <!-- ======================================================================= -->
887 <h2>
888   <a name="sparc-be">Known problems with the SPARC back-end</a>
889 </h2>
890
891 <div class="doc_text">
892
893 <ul>
894 <li>The SPARC backend only supports the 32-bit SPARC ABI (-m32); it does not
895     support the 64-bit SPARC ABI (-m64).</li>
896 </ul>
897
898 </div>
899
900 <!-- ======================================================================= -->
901 <h2>
902   <a name="mips-be">Known problems with the MIPS back-end</a>
903 </h2>
904
905 <div class="doc_text">
906
907 <ul>
908 <li>64-bit MIPS targets are not supported yet.</li>
909 </ul>
910
911 </div>
912
913 <!-- ======================================================================= -->
914 <h2>
915   <a name="alpha-be">Known problems with the Alpha back-end</a>
916 </h2>
917
918 <div class="doc_text">
919
920 <ul>
921
922 <li>On 21164s, some rare FP arithmetic sequences which may trap do not have the
923 appropriate nops inserted to ensure restartability.</li>
924
925 </ul>
926 </div>
927
928 <!-- ======================================================================= -->
929 <h2>
930   <a name="c-be">Known problems with the C back-end</a>
931 </h2>
932
933 <div class="doc_text">
934
935 <p>The C backend has numerous problems and is not being actively maintained.
936 Depending on it for anything serious is not advised.</p>
937
938 <ul>
939 <li><a href="http://llvm.org/PR802">The C backend has only basic support for
940     inline assembly code</a>.</li>
941 <li><a href="http://llvm.org/PR1658">The C backend violates the ABI of common
942     C++ programs</a>, preventing intermixing between C++ compiled by the CBE and
943     C++ code compiled with <tt>llc</tt> or native compilers.</li>
944 <li>The C backend does not support all exception handling constructs.</li>
945 <li>The C backend does not support arbitrary precision integers.</li>
946 </ul>
947
948 </div>
949
950
951 <!-- ======================================================================= -->
952 <h2>
953   <a name="llvm-gcc">Known problems with the llvm-gcc front-end</a>
954 </h2>
955
956 <div class="doc_text">
957
958 <p>llvm-gcc is generally very stable for the C family of languages.  The only
959    major language feature of GCC not supported by llvm-gcc is the
960    <tt>__builtin_apply</tt> family of builtins.   However, some extensions
961    are only supported on some targets.  For example, trampolines are only
962    supported on some targets (these are used when you take the address of a
963    nested function).</p>
964
965 <p>Fortran support generally works, but there are still several unresolved bugs
966    in <a href="http://llvm.org/bugs/">Bugzilla</a>.  Please see the
967    tools/gfortran component for details.  Note that llvm-gcc is missing major
968    Fortran performance work in the frontend and library that went into GCC after
969    4.2.  If you are interested in Fortran, we recommend that you consider using
970    <a href="#dragonegg">dragonegg</a> instead.</p>
971
972 <p>The llvm-gcc 4.2 Ada compiler has basic functionality, but is no longer being
973 actively maintained.  If you are interested in Ada, we recommend that you
974 consider using <a href="#dragonegg">dragonegg</a> instead.</p>
975 </div>
976
977 <!-- *********************************************************************** -->
978 <h1>
979   <a name="additionalinfo">Additional Information</a>
980 </h1>
981 <!-- *********************************************************************** -->
982
983 <div class="doc_text">
984
985 <p>A wide variety of additional information is available on the <a
986 href="http://llvm.org">LLVM web page</a>, in particular in the <a
987 href="http://llvm.org/docs/">documentation</a> section.  The web page also
988 contains versions of the API documentation which is up-to-date with the
989 Subversion version of the source code.
990 You can access versions of these documents specific to this release by going
991 into the "<tt>llvm/doc/</tt>" directory in the LLVM tree.</p>
992
993 <p>If you have any questions or comments about LLVM, please feel free to contact
994 us via the <a href="http://llvm.org/docs/#maillist"> mailing
995 lists</a>.</p>
996
997 </div>
998
999 <!-- *********************************************************************** -->
1000
1001 <hr>
1002 <address>
1003   <a href="http://jigsaw.w3.org/css-validator/check/referer"><img
1004   src="http://jigsaw.w3.org/css-validator/images/vcss-blue" alt="Valid CSS"></a>
1005   <a href="http://validator.w3.org/check/referer"><img
1006   src="http://www.w3.org/Icons/valid-html401-blue" alt="Valid HTML 4.01"></a>
1007
1008   <a href="http://llvm.org/">LLVM Compiler Infrastructure</a><br>
1009   Last modified: $Date$
1010 </address>
1011
1012 </body>
1013 </html>