<div dir="ltr"><div>In attempting to add a backend I came across the documentation here: <a href="http://llvm.org/docs/WritingAnLLVMBackend.html">http://llvm.org/docs/WritingAnLLVMBackend.html</a></div><div><br></div><div>The section on the build system seems to be out of date, or maybe I don't understand it.  I copied the Sparc target to a directory (Foo for the example), added Foo to the subdirectories list in llvm\lib\Target\LLVMBuild.txt and to LLVM_ALL_TARGETS in llvm\CMakeLists.txt.  I removed the files except for FooTargetMachine.cpp and FooTargetMachine.h.</div><div><br></div><div>FooTargetMachine is not completed yet, but I was trying to compile and get linker errors about _LLVMInitializeFooTargetMC referenced in function void llvm::InitializeAllTargetMCs(void).  I do not see anything about how to implement this function.</div><div><br></div><div>Is there additional documentation about how to implement a backend that I am missing?</div></div>