[llvm-dev] IR -> source pretty printing?

Stephen Thomas via llvm-dev llvm-dev at lists.llvm.org
Wed Jul 13 07:00:08 PDT 2016


Hi,

I often find myself staring at IR and wanting to look at the C source code
it corresponds to. To do so, I look up the debug identifier for the given
IR line, scroll to the bottom of the IR file to find the debug identifier,
look at the debug location (source and column), and then look at the source
file. Too many steps. What would be great is a tool that took two files,
i.e., a .c file and a .bc file, and printed out the IR with the
corresponding C source right beneath each IR line.

It wouldn't be too hard for me to write such a tool, but I thought I'd
check to see if something already exists before I reinvent the wheel. Is
there anything out there?

Thanks,
Steve
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160713/b8b52f2c/attachment.html>


More information about the llvm-dev mailing list