[llvm] [Analysis]: Allow inlining recursive call IF recursion depth is 1. (PR #119677)
Hassnaa Hamdi via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 12 23:42:56 PST 2024
hassnaaHamdi wrote:
Hi @nikic
Thanks for your comment.
In general I agree with you.
But I think that the correct place could be visitCallBase? because the simplification will depend on the arguments of the next iteration of the function, which are the arguments of the CallBase.
So I think the flow could start from visitCallBase and then simplifyCallSite(..) which will check if this callsite is guarded by a ComInst that is using one of the arguments, and then the flow ends by calling visitCmpInstWithOps, because I need the CmpInst to work on the new argument of the next iteration.
What do you think ?
https://github.com/llvm/llvm-project/pull/119677
More information about the llvm-commits
mailing list