Knowing the backend libraries

The llc non-shared code is quite small (see tools/llc/llc.cpp) and most of its functionality is implemented as reusable libraries, in the same way as other LLVM tools. In the case of llc, its functionality is provided by the code generator libraries. This set of libraries is composed of a target-dependent part and a target-independent one. The code generator target-dependent libraries are in different files from the target-independent ones, allowing you to link with a restricted set of desired target backends. For instance, by using --enable-targets=x86,arm during the LLVM configuration, only the x86 and the ARM backend libraries are linked into llc.

Recall that all LLVM libraries are prefixed with libLLVM. We omit ...

Get Getting Started with LLVM Core Libraries now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.