I'm trying to hunt down some performance issues in my ASP.NET (Nancy, OWIN/System.Web hosted) app.
Through profiling, (namely Stackify tools), i've noticed some 'gaps' at the end of certain requests, that aren't non-obvious calls (e.g not Database, HTTP, Redis, etc).
Here's an example: (taken from Stackify's Prefix tool)
Summary:
- Request took 1289ms
- 'Most' (hot path) was taken by a SQL query. (i'm fine with this for now, could be optimized but is not the focus of this question)
- Couple of 'Untracked Application Code' gaps, taking over 500ms.
Particulary, the last gap (340ms) i've seen a lot and is the focus of my investigations.
Prefix allows custom code configuration that allows to get more info on these 'gaps' by whitelisting an assembly, but the problem is i don't know which assembly this time is being spent. My gut feeling is Nancy/OWIN/some dependency injection lib, etc. (i've tried whitelisting all of these, to no avail). I just know it's not my immediate code in this URL.
So my questions are:
- Any ideas on how i can find out the full and ordered call stack of this request, to then use as whitelisting for Prefix? Tools i can use?
- Any 'left of centre' ideas on how to track down this gap? Another tool instead of Prefix that tells me where time is spent?
Thanks!