blob: 879814067a731578076f6420b69ce724236b46d8 [file] [log] [blame]
Dan Gohmanf17a25c2007-07-18 16:29:46 +00001=pod
2
3=head1 NAME
4
5lli - directly execute programs from LLVM bitcode
6
7=head1 SYNOPSIS
8
9B<lli> [I<options>] [I<filename>] [I<program args>]
10
11=head1 DESCRIPTION
12
13B<lli> directly executes programs in LLVM bitcode format. It takes a program
14in LLVM bitcode format and executes it using a just-in-time compiler, if one is
15available for the current architecture, or an interpreter. B<lli> takes all of
16the same code generator options as L<llc|llc>, but they are only effective when
17B<lli> is using the just-in-time compiler.
18
19If I<filename> is not specified, then B<lli> reads the LLVM bitcode for the
20program from standard input.
21
22The optional I<args> specified on the command line are passed to the program as
23arguments.
24
25=head1 OPTIONS
26
27=over
28
29=item B<-help>
30
31Print a summary of command line options.
32
33=item B<-stats>
34
35Print statistics from the code-generation passes. This is only meaningful for
36the just-in-time compiler, at present.
37
38=item B<-time-passes>
39
40Record the amount of time needed for each code-generation pass and print it to
41standard error.
42
43=item B<-mtriple>=I<target triple>
44
45Override the target triple specified in the input bitcode file with the
46specified string. This may result in a crash if you pick an
47architecture which is not compatible with the current system.
48
49=item B<-march>=I<arch>
50
51Specify the architecture for which to generate assembly, overriding the target
52encoded in the bitcode file. See the output of B<llc --help> for a list of
53valid architectures. By default this is inferred from the target triple or
54autodetected to the current architecture.
55
56=item B<-mcpu>=I<cpuname>
57
58Specify a specific chip in the current architecture to generate code for.
59By default this is inferred from the target triple and autodetected to
60the current architecture. For a list of available CPUs, use:
61B<llvm-as E<lt> /dev/null | llc -march=xyz -mcpu=help>
62
63=item B<-mattr>=I<a1,+a2,-a3,...>
64
65Override or control specific attributes of the target, such as whether SIMD
66operations are enabled or not. The default set of attributes is set by the
67current CPU. For a list of available attributes, use:
68B<llvm-as E<lt> /dev/null | llc -march=xyz -mattr=help>
69
Reid Spencer666dcb52007-08-07 16:11:57 +000070=item B<-fake-argv0>=I<executable>
71
72Override the C<argv[0]> value passed into the executing program.
73
Dan Gohmanf17a25c2007-07-18 16:29:46 +000074=item B<-force-interpreter>=I<{false,true}>
75
76If set to true, use the interpreter even if a just-in-time compiler is available
77for this architecture. Defaults to false.
78
Reid Spencer666dcb52007-08-07 16:11:57 +000079=item B<-load>=I<puginfilename>
Dan Gohmanf17a25c2007-07-18 16:29:46 +000080
Reid Spencer666dcb52007-08-07 16:11:57 +000081Causes B<lli> to load the plugin (shared object) named I<pluginfilename> and use
82it for optimization.
83
84=item B<-soft-float>
85
86Causes B<lli> to generate software floating point library calls instead of
87equivalent hardware instructions.
Dan Gohmanf17a25c2007-07-18 16:29:46 +000088
Reid Spencer26817692007-08-07 16:21:52 +000089=item B<-enable-unsafe-fp-math>
90
91Causes B<lli> to enable optimizations that may decrease floating point
92precision.
93
Reid Spencer98044742007-08-07 16:23:42 +000094=item B<-disable-excess-fp-precision>
95
96Disable optimizations that may increase floating point precision.
97
Dan Gohmanf17a25c2007-07-18 16:29:46 +000098=back
99
100=head1 EXIT STATUS
101
102If B<lli> fails to load the program, it will exit with an exit code of 1.
103Otherwise, it will return the exit code of the program it executes.
104
105=head1 SEE ALSO
106
107L<llc|llc>
108
109=head1 AUTHOR
110
111Maintained by the LLVM Team (L<http://llvm.org>).
112
113=cut