[LTO API] add lto_codegen_set_module to help ld64 debug LTO issues

Manman Ren mren at apple.com
Thu Feb 19 17:22:30 PST 2015


Hi Rafael and others,

When debugging LTO issues with ld64, I sometimes use -save-temps to save the merged optimized bitcode file, then invoke ld64 again on the single bitcode file.

I found out that llvm linking a single bitcode file via lto_codegen_add_module will generate a different bitcode file from the single input.
This makes debugging hard. With the newly-added lto_codegen_set_module, we can make sure the destination module is the same as the input.

The patch is attached. Let me know your thoughts,

Thanks,
Manman

-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm_set_module2.patch
Type: application/octet-stream
Size: 3892 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150219/5f4a6726/attachment.obj>
-------------- next part --------------




More information about the llvm-commits mailing list