Cross-procedural data-flow analysis

RU / Day 1 / 14:00 / Track 3

In this session, using real-world examples, Andrey will tell how to write cross-procedural code analysis and why it is now necessary for C# code analyzers, no matter what they're based on — ReSharper, Roslyn or custom code model.

As an example, Andrey will give a general overview of data-flow analysis in ReSharper: how it works and how it was influenced by local functions introduced in C# 7. He will iteratively explore algorithm of collecting data for cross-procedural analysis without reference to specific Roslyn/ReSharper APIs and evaluate how hard it is to build model of memory/time on each stage. Andrey will also give a few examples of using this model beyond the original case.

This talk would be especially interesting and useful to people keen to write their own code analyzer, notably for C#, but the concept shown in this talk can be applied for any language. Besides, iterative complicating, evaluating and optimizing algorithm of building data model, and working with call graph might serve as examples of real-life algorithmic problems.


Download presentation