[llvm-dev] [llvm] The difference of passes order between FunctionSimplificationPipeline and LTODefaultPipeline

liren peng via llvm-dev llvm-dev at lists.llvm.org
Tue Oct 12 00:07:30 PDT 2021


Hi, ALL

  As we know, the order of compiler passes has a great influence on the results of program optimization.

  While I using llvm to compiler my test code, I changed the order of Loop Deletion pass and DSE pass(First time Loop Deletion is before DSE, the default order of FunctionSimplificationPipeline. Second time, I used DSE before Loop Deletion),  the compilation method of these two sequences has produced a big performance gap, because without DSE, a variable inside loop could not be optimized for the default order of FunctionSimplificationPipeline, but the second order(DSE before Loop Deletion) works well.  And I noticed that in  LTODefaultPipeline , DSE is before Loop Deletion.

So , Why there is difference of passes order between FunctionSimplificationPipeline and LTODefaultPipeline?

And why should use Loop Deletion before DSE(or other great optimization passes) as default?

Anyone’s answers are precious to me. Thank you all.

 

Peakulorain

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20211012/8771d202/attachment.html>


More information about the llvm-dev mailing list