[cfe-dev] From LLVM Bytecode to C source

Eli Friedman eli.friedman at gmail.com
Tue Jan 13 02:56:00 PST 2009


On Tue, Jan 13, 2009 at 2:08 AM, Simone Pellegrini
<spellegrini at dps.uibk.ac.at> wrote:
> I wonder to know if there is any chance to convert back emitted LLVM
> bytecode into a C source file using clang (or any other existing tool)

clang definitely isn't going to help you here.  One thing you can do
is use the LLVM C backend, which can be invoked using "llc -march=c";
the result isn't pretty, but if the original code is C code, the
output is usually accurate enough that the result can be compiled and
run with gcc.

-Eli



More information about the cfe-dev mailing list