Alexander Ermachenko via llvm-dev
2021-Aug-15 14:46 UTC
[llvm-dev] Some questions about pointers analysis
Hi,1. Function PointerMayBeCaptured take an argument StoreCaptures. Some call sites pass true to this argument(for example in LICM and AliasAnalysis). As far as I understand, PointerMayBeCaptured must always be conservative, therefore it can't produce wrong results even if StoreCaptures is false. Why StoreCaptures is not always false? In which cases it must be true?2. Alias analyses contains getModRefInfo methods to retrieve function call sites ModRef information, but I have not found any alias analysis, which actually use pointers assignments and pointers modifications information and examine load/store instructions of analyzed function. As far as I see, there are no suitable alias analysis implemented, because no one alias analysis examine both functions inside and pointers passed as arguments. It is not trivial to create the data structure required for this analysis, because it has to check if an modification of certain memory location exists in a function or in some other function, that can be called from it, and the data structure should not take more than near linear time in total to construction and responding to queries. But with some loss of analyze precision, it can be implemented. Have there been researches that have shown ineffectiveness of such analysis or it simply have not been implemented? -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20210815/1297c1f8/attachment.html>