From: Chris Lattner Date: Sun, 16 Oct 2005 17:03:22 +0000 (+0000) Subject: Update this significantly, mention subtarget and isel generation support. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=c3b05403b753996f6b1db4914df586e4b6b54d3a;p=oota-llvm.git Update this significantly, mention subtarget and isel generation support. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23760 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/docs/WritingAnLLVMBackend.html b/docs/WritingAnLLVMBackend.html index c215fc62a3f..ea5cd9c3da5 100644 --- a/docs/WritingAnLLVMBackend.html +++ b/docs/WritingAnLLVMBackend.html @@ -68,21 +68,21 @@ convert the LLVM representation to machine assembly code or other languages.

implement the following:

- -

You also need to write an instruction selector for your platform. The -recommended method is the pattern-matching instruction selector, -examples of which you can see in other targets: -lib/Target/*/*ISelPattern.cpp. The former method for writing -instruction selectors (not recommended for new targets) is evident in -lib/Target/*/*ISelSimple.cpp, which are InstVisitor-based -translators, generating code for an LLVM instruction at a time. Creating an -instruction selector is perhaps the most time-consuming part of creating a -back-end.

- -

To create a JIT for your platform:

- +
  • Implement the assembly printer for the architecture. + +
  • +
  • Implement an instruction selector for the architecture. + +
  • +
  • Optionally, add subtarget support. +
  • Optionally, add JIT support. + - -

    Note that lib/target/Skeleton is a clean skeleton for a new target, -so you might want to start with that and adapt it for your target, and if you -are wondering how things are done, peek in the X86 or PowerPC target.

    - -

    The Skeleton target is non-functional but provides the basic building blocks -you will need for your endeavor.

    -