[LLVMdev] About using mem2reg pass only for SSA form

Padefic padefic at 126.com
Wed Jul 30 07:59:13 PDT 2014


Hello,


I am using mem2reg to provide SSA form. However, I found that it also do some optimization work, e.g., remove some unnecessary code. May I ask is it possible to use mem2reg only to generate SSA form without any other changes to the code? Because the originial code is important to me. 


I have integrated a PromotePass pass to clang backend when generating IR, and need this to achieve the above goal, but I am not sure whether it is feasible to modify the source code of PromoteMemoryToRegister.cpp or Mem2Reg.cpp in llvm/Transforms/Utils directory.


Thanks!
Padefic
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20140730/9c7c13d0/attachment.html>


More information about the llvm-dev mailing list