5 llvmc - The LLVM Compiler Driver (WIP)
9 B<llvmc> [I<options>] I<filenames...>
13 B<llvmc> is a configurable driver for invoking other LLVM (and non-LLVM) tools
14 in order to compile, optimize and link software for multiple languages. For
15 those familiar with FSF's B<gcc> tool, it is very similar. Please note that
16 B<llvmc> is considered an experimental tool.
20 =head2 Built-in Options
22 LLVMC has some built-in options that can't be overridden in the
23 configuration libraries.
27 =item B<-o> I<filename>
31 =item B<-x> I<language>
33 Specify the language of the following input files until the next B<-x>
36 =item B<-load> I<plugin_name>
38 Load the specified plugin DLL. Example:
39 S<-load $LLVM_DIR/Release/lib/LLVMCSimple.so>.
41 =item B<-v> or B<--verbose>
43 Enable verbose mode, i.e. print out all executed commands.
45 =item B<--check-graph>
47 Check the compilation for common errors like mismatched output/input
48 language names, multiple default edges and cycles. Hidden option,
53 Show a graphical representation of the compilation graph. Requires
54 that you have I<dot> and I<gv> programs installed. Hidden option,
57 =item B<--write-graph>
59 Write a I<compilation-graph.dot> file in the current directory with
60 the compilation graph description in the Graphviz format. Hidden
61 option, useful for debugging.
65 Write temporary files to the current directory and do not delete them
66 on exit. Hidden option, useful for debugging.
70 Print a summary of command-line options and exit.
72 =item B<--help-hidden>
74 Print a summary of command-line options and exit. Print help even for
75 options intended for developers.
79 Print version information and exit.
83 =head2 Control Options
85 By default, LLVMC is built with some standard configuration libraries
86 that define the following options:
92 Use Clang instead of llvm-gcc.
96 Enable optimization with B<opt>.
98 =item B<-I> I<directory>
100 Add a directory to the header file search path. This option can be
103 =item B<-L> I<directory>
105 Add I<directory> to the library search path. This option can be
110 Link in the library libI<name>.[bc | a | so]. This library should
111 be a bitcode library.
115 Make the output be LLVM bitcode (with B<-c>) or assembly (with B<-S>) instead
116 of native object (or assembly). If B<-emit-llvm> is given without either B<-c>
117 or B<-S> it has no effect.
121 Pass options to assembler.
125 Pass options to linker.
135 If B<llvmc> succeeds, it will exit with code 0. Otherwise, if an
136 error occurs, it will exit with a non-zero value. If one of the
137 compilation tools returns a non-zero status, pending actions will be
138 discarded and B<llvmc> will return the same result code as the failing
143 L<llvm-gcc|llvmgcc>, L<llvm-g++|llvmgxx>, L<llvm-as|llvm-as>,
144 L<llvm-dis|llvm-dis>, L<llc|llc>, L<llvm-link|llvm-link>
148 Maintained by the LLVM Team (L<http://llvm.org>).