Changes between Version 9 and Version 10 of Commentary/Compiler/Backends/LLVM/Installing


Ignore:
Timestamp:
Mar 30, 2010 5:46:56 AM (5 years ago)
Author:
dterei
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Commentary/Compiler/Backends/LLVM/Installing

    v9 v10  
    88'''Update (24/03/2010)''': The changes required to LLVM for it to work with the back-end have been accepted upstream. You now just need to grab a recent 2.7 (since Pre-release1) build of LLVM or build your own copy from SVN.
    99
    10 = Installing =
     10== Installing ==
    1111
    1212Apply the darcs patch linked above to GHC head. This will make some changes across GHC, with the bulk of the new code ending up in 'compiler/llvmGen'.
     
    2121The LLVM code generator doesn't support at this time the {{{TABLES_NEXT_TO_CODE}}} optimisation due to limitations with LLVM.
    2222
    23 == LLVM ==
     23=== LLVM ===
    2424
    2525You will also need LLVM installed on your computer to use the back-end. If you wish to simply use an unregistered build of GHC, then the back-end should work with any standard LLVM version. If you wish to use a registered build of GHC however, then you may need to apply a patch to LLVM and build it yourself:
     
    4646
    4747
    48 = Using =
     48== Using ==
    4949
    5050Once GHC is built, you can trigger GHC to use the LLVM back-end with the {{{-fllvm}}} flag. There is also a new {{{-ddump-llvm}}} which will dump out the LLVM IR code generated (must be used in combination with the {{{-fllvm}}} flag. (or use the {{{-keep-tmp-files}}} flag).
     
    5555
    5656
    57 = Supported Platforms & Correctness =
     57== Supported Platforms & Correctness ==
    5858
    5959 * Linux x86-32/x86-64 are currently well supported. The back-end can pass the test suite and build a working version of GHC (bootstrap test).
     
    6262
    6363
    64 = Performance =
     64== Performance ==
    6565
    6666(All done on linux/x86-32)
     
    7474A nice demonstration of the improvements the LLVM back-end can bring to some code though can be see at http://donsbot.wordpress.com/2010/02/21/smoking-fast-haskell-code-using-ghcs-new-llvm-codegen/
    7575
    76 = Validate =
     76== Validate ==
    7777
    7878The GHC patch has been validated to make sure it won't break anything. This is just compiling and running GHC normally but with the LLVM back-end code included. It doesn't actually test the LLVM code generator, just makes sure it hasn't broken the NCG or C code generator.