LLI(1)

๐Ÿ’– LLI(1) โ€” the girlies are executing bitcode directly ๐Ÿ’–

okay so bestie, welcome to the LLI(1) page, from the LLVM manual, section 1. sit down, grab a strawberry ๐Ÿ“, we're about to execute some programs.


โœจ NAME โœจ

lli โ€” directly execute programs from LLVM bitcode. no cap.


โœจ SYNOPSIS โœจ

lli [options] [filename] [program args]

โœจ DESCRIPTION โœจ

So like, lli directly executes programs that are in LLVM bitcode format. you hand it a program in LLVM bitcode format and it runs it โ€” either with a just-in-time compiler or with an interpreter. two paths, one icon. ๐Ÿ‘‘

But listen. lli is not an emulator, okay? it will not execute IR of different architectures, and it can only interpret (or JIT-compile) for the host architecture. it's giving "stay in your lane" and honestly? valid.

The JIT compiler takes the same arguments as other tools, like llc, but heads up โ€” they don't necessarily work for the interpreter. ๐Ÿ’€

If filename is not specified, then lli reads the LLVM bitcode for the program from standard input. yes bestie, it'll just vibe with stdin.

The optional args specified on the command line are passed to the program as arguments. simple as that. ๐Ÿซถ


โœจ GENERAL OPTIONS โœจ

  • -fake-argv0=executable โ€” override the argv[0] value that gets passed into the executing program. little identity crisis moment, but make it intentional. ๐Ÿ™ˆ
  • -force-interpreter={false,true} โ€” if you set this to true, it uses the interpreter even if a just-in-time compiler is available for this architecture. defaults to false. โœจ
  • -help โ€” prints a summary of command line options. your little map. ๐ŸŽ€
  • -load=pluginfilename โ€” causes lli to load the plugin (shared object) named pluginfilename and use it for optimization. plug it in, plug it in ๐Ÿ’…
  • -stats โ€” prints statistics from the code-generation passes. ngl this is only meaningful for the just-in-time compiler, at present. ๐Ÿ”ฅ
  • -time-passes โ€” records the amount of time needed for each code-generation pass and prints it to standard error. clocking the tea โฑ๏ธ
  • -version โ€” prints out the version of lli and exits without doing anything else. bye bestie, love u, no further notes. ๐Ÿ‘‹

โœจ TARGET OPTIONS โœจ

  • -mtriple=target triple โ€” overrides the target triple specified in the input bitcode file with the string you give it. โš ๏ธ this may result in a crash if you pick an architecture which is not compatible with the current system. choose wisely, queen.
  • -march=arch โ€” specify the architecture for which to generate assembly, overriding the target encoded in the bitcode file. for a list of valid architectures, see the output of llc -help. by default this is inferred from the target triple or autodetected to the current architecture. ๐Ÿฆ‹
  • -mcpu=cpuname โ€” specify a specific chip in the current architecture to generate code for. by default this is inferred from the target triple and autodetected to the current architecture. for a list of available CPUs, use:
llvm-as < /dev/null | llc -march=xyz -mcpu=help
  • -mattr=a1,+a2,-a3,... โ€” override or control specific attributes of the target, like whether SIMD operations are enabled or not. the default set of attributes is set by the current CPU. for a list of available attributes, use:
llvm-as < /dev/null | llc -march=xyz -mattr=help

โœจ FLOATING POINT OPTIONS โœจ

  • -disable-excess-fp-precision โ€” disables optimizations that may increase floating point precision. ๐Ÿงฎ
  • -enable-no-infs-fp-math โ€” enables optimizations that assume no Inf values.
  • -enable-no-nans-fp-math โ€” enables optimizations that assume no NAN values.
  • -soft-float โ€” causes lli to generate software floating point library calls instead of equivalent hardware instructions. soft launch, but for math. ๐ŸŒธ

โœจ CODE GENERATION OPTIONS โœจ

  • -code-model=model โ€” choose the code model from:
   default: Target default code model
   tiny: Tiny code model
   small: Small code model
   kernel: Kernel code model
   medium: Medium code model
   large: Large code model
  • -disable-post-RA-scheduler โ€” disables scheduling after register allocation.
  • -disable-spill-fusing โ€” disables fusing of spill code into instructions.
  • -jit-enable-eh โ€” exception handling should be enabled in the just-in-time compiler. ๐Ÿšจ
  • -join-liveintervals โ€” coalesce copies (default=true).
  • -nozero-initialized-in-bss โ€” don't place zero-initialized symbols into the BSS section.
  • -pre-RA-sched=scheduler โ€” instruction schedulers available (before register allocation):
   =default: Best scheduler for the target
   =none: No scheduling: breadth first sequencing
   =simple: Simple two pass scheduling: minimize critical path and maximize processor utilization
   =simple-noitin: Simple two pass scheduling: Same as simple except using generic latency
   =list-burr: Bottom-up register reduction list scheduling
   =list-tdrr: Top-down register reduction list scheduling
   =list-td: Top-down list scheduler
  • -regalloc=allocator โ€” register allocator to use (default=linearscan)
   =bigblock: Big-block register allocator
   =linearscan: linear scan register allocator
   =local: local register allocator
   =simple: simple register allocator
  • -relocation-model=model โ€” choose relocation model from:
   =default: Target default relocation model
   =static: Non-relocatable code
   =pic: Fully relocatable, position independent code
   =dynamic-no-pic: Relocatable external references, non-relocatable code
  • -spiller โ€” spiller to use (default=local)
   =simple: simple spiller
   =local: local spiller
  • -x86-asm-syntax=syntax โ€” choose style of code to emit from X86 backend:
   =att: Emit AT&T-style assembly
   =intel: Emit Intel-style assembly

โœจ EXIT STATUS โœจ

If lli fails to load the program, it will exit with an exit code of 1. otherwise, it will return the exit code of the program it executes. so like, it's not doing its own thing, it's just relaying the vibes. ๐Ÿ“ฌ


โœจ SEE ALSO โœจ


โœจ Author โœจ

Maintained by the LLVM Team (https://llvm.org/). ๐Ÿ’œ


2003-2026, LLVM Project


okay that's the whole page bestie, you ate ๐Ÿ’…โœจ this was the LLI(1) page from LLVM, dated 2026-07-16, and it's page 22 of the manual โ€” mwah, go forth and JIT-compile something iconic ๐ŸŽ€๐Ÿฆ‹

๐Ÿ“ฆ where this page comes from