Run llc with -debug flag

I want to check debug output of “PrologEpilogInserter” machine pass, and I have seen in the code that there are various DEBUG macros added.

However, there is no -debug option present for llc like it is for opt. Closest option I saw after seeing output of llc --help-list is -verify-debug-info but that does not give any output.

Regards,

Meet.

llc accepts all the -debug variants when built with asserts (or debug build). It will accept -debug as well as -debug=prologepilog for your case.

I later realised that it wasn’t enabled by default and I will have to rebuild a debug version of LLVM.

It would probably help to mention that somewhere on this page: https://llvm.org/docs/CommandGuide/llc.html

Thanks Nemanja!

Regards,

Meet.