Through the new Attributor::checkForAllCallees we can look through
indirect calls and visit all potential callees if they are known.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/lib/Transforms/IPO/Attributor.cpp | ||
---|---|---|
1749 | Why the compare to 1 for a bool? |
llvm/lib/Transforms/IPO/Attributor.cpp | ||
---|---|---|
1749 | If we have more than 1 potential callee we don't know if it is a "must" callee anymore. I haven't thought enough about this to be sure we need or don't need it but there is the possibility we want to distinguish callees that may be called here from the one that certainly is. |
llvm/include/llvm/Transforms/IPO/Attributor.h | ||
---|---|---|
3306 | I thought the optimistic condition would be we don't have indirect calls such that the "callee" is required. | |
llvm/lib/Transforms/IPO/Attributor.cpp | ||
1749 | I kinda think the interface of the CB just looks a little weird. Essentially the best way is something like ArrayRef<Function *> Callees, and then we can have both information. However, checkForAll* interfaces itself mean doing the check one by one instead of passing an array to the CB. |
llvm/include/llvm/Transforms/IPO/Attributor.h | ||
---|---|---|
3306 | It's not about optimistic per se. This is a way to avoid creating AAs that will result in a pessimistic fixpoint right away. With this change, most AAs use checkForAllCallees via AACalleeToCallSite and therefore will be able to cope with "missing"/"non-unique" callees. |
I thought the optimistic condition would be we don't have indirect calls such that the "callee" is required.