is there a non-jitting interpreter for the LLVM IR?

Is there a non-jitting interpreter for the LLVM IR? I'm tired of
hunting around in your source code looking for it.

I want to write a dynamic analysis and if your interpreter is clean
enough it will be easier to hack on it than to write my own. I want a
"naive" interpreter that just does each instruction one at a time.
Again, my goal is not performance, but semantics. When you JIT it
makes augmenting what each instruction does a pain. I hacked on
Vagrind a bit and that was the primary problem.

Daniel

Hi Daniel,

Is there a non-jitting interpreter for the LLVM IR?

There is. It lives under lib/ExecutionEngine/Interpreter and is
usually invoked with "lli -force-interpreter".

It's a fairly minor component of LLVM though (less rigorously tested
and less actively maintained). There certainly have been correctness
issues there in the past (I think it didn't handle vector types for a
while), though I'm not personally aware of any at the moment.

Cheers.

Tim.