Open InMatrix opened 1 year ago
@bkonyi
Maybe we should get some support from the tech writers on this as I'm not sure how to make this more descriptive.
The exclusive column represents how many allocations of an object were made when that frame was at the top of the stack (e.g, allocations exclusive to the stack frame). The inclusive column represents the number of allocations made when the frame was at the top of the stack, including allocations made by functions called from the same frame. In general, exclusive counts <= inclusive counts.
See this article from the Visual Studio Profiler Team: What are Exclusive and Inclusive?!.
@bkonyi The article from the VSP team was helpful. Thanks for sharing that. I guess a better question to ask is: who should care about this distinction and when should they care? If these two statistics are useful for app developers, can we provide an example where the distinction matters in https://docs.flutter.dev/development/tools/devtools/memory?
In the Trace Instances view, there was an Inclusive column and Exclusive column. However, it's unclear when the distinction is important. The tooltips for the two columns don't provide sufficient information (see the screenshots below). I wasn’t sure when I should pay attention to the difference between the Inclusive column and the Exclusive column. I also didn't find documentation about these two columns at https://docs.flutter.dev/development/tools/devtools/memory#trace-tab.
Recommendations: