[PATCH] D130726: [clang][dataflow] Handle multiple context-sensitive calls to the same function

Gábor Horváth via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 29 09:54:52 PDT 2022


xazax.hun accepted this revision.
xazax.hun added a comment.
This revision is now accepted and ready to land.

I'd love to see some comments in the source code to make sure one will not sue these facilities for other purposes that this was not designed to do. Alternatively, `ContextSensitive` option could be renamed to `NonRecursiveContextSensitive`.



================
Comment at: clang/lib/Analysis/FlowSensitive/Transfer.cpp:512-513
       // have the callee body available in the translation unit.
       if (!Options.ContextSensitive || F->getBody() == nullptr)
         return;
 
----------------
Since we do not support recursion (and only do inlining with the depth of one), I think we should have a check here to avoid a inlining recursive call. 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D130726/new/

https://reviews.llvm.org/D130726



More information about the cfe-commits mailing list