[LLVMdev] Can llvm-2.5 work with "-O1 -g"?

hc2428 at columbia.edu hc2428 at columbia.edu
Sat Jun 6 08:56:12 PDT 2009


Dear staff,

     I need to get the line number and file name information of the  
source code for each instruction in *.bc file. I find that llvm-2.4  
can not support "-O1 -g", which means if we are at O1 to O3  
optimization level, we can not get any dbg.stoppoint inserted into the  
LLVM IR.

     However, our project requires us to get the line number and file  
name information of the source code for each instruction in *.bc file  
at any Ox level. I have built and run llvm-2.5 and found that it still  
can not support "-Ox -g".

     If we are not using "-g", do we have other ways to get the line  
number and file name information for each instruction in *.bc file?

Best,
Heming



More information about the llvm-dev mailing list