There's some excellent official documentation on backend writing (http://llvm.org/docs/subsystems.html and http://llvm.org/docs/WritingAnLLVMBackend.html). From my previous experience, it isn't as straightforward as in the docs, but you can use the other backends as reference.