I am working on a project where I have to a write code for converting LLVM-IR into a C-like language. This language has constructs very similar to C. After doing a little survey, I found that upto version 3.0 of LLVM there existed a file named CBackend.cpp responsible for conversion of LLVM-IR into C code. What I want to check is run this CBackend.cpp file on my input file of LLVM-IR and generate C code.
The command for this is: llc -march=c -o code.c code.ll
where the code.ll file is the input file containing the input llvm-ir and code.c is the output file containing the resultant C code.
What I am facing is, I have LLVM version 3.4svn installed on my ubuntu system and there is no CBackend.cpp file in this version as the file has been upgraded to CppBackend.cpp (which converts LLVM-IR to C++). Which command can I use to run this CBackend.cpp file on my LLVM-IR input file to get the corresponding C code in version 3.4svn of LLVM ?
Thanks in advance.