I see that we do not inline a function marked as "always-inline" if it contains indirect branches ? what are the reasons behind this criterion ? Thanks Trent -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150129/92bf577a/attachment.html>
Because we can't reliably inline functions with indirect branches. -eric On Thu Jan 29 2015 at 11:32:42 AM Xin Tong <trent.tong at gmail.com> wrote:> I see that we do not inline a function marked as "always-inline" if it > contains indirect branches ? what are the reasons behind this criterion ? > > Thanks > Trent > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150129/cfcf0f02/attachment.html>
There have been extensive discussions about this on about 8 month ago on the mailing list. You’ll also find some comments in the code. We first have to improve points-to analysis before we think about revisiting inlining functions with indirect branches. Always-inline just means inline when the compiler can determine that it is safe to so. -Gerolf ].> On Jan 29, 2015, at 11:27 AM, Xin Tong <trent.tong at gmail.com> wrote: > > I see that we do not inline a function marked as "always-inline" if it contains indirect branches ? what are the reasons behind this criterion ? > > Thanks > Trent > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20150129/87ce0f8c/attachment.html>