I'm primarily evaluation the ANTS profiler as an alternative to dotTrace; hence, my comments are bit dotTrace-centric.

* Whenever I start a new profiler project, ANTS displays a wizard that lets me configure the profiler settings. This is initially helpful, but ultimately annoying. ANTS should remember my settings, and use them as a default for each subsequent run of the ANTS program (with an option to change the settings later, of course)

* The "Slowest Methods" and "Slowest Lines" views are great, but it would be nice to see a tree view of these slowest methods, along with their timings displayed at a glance, and to open each node in the tree individually, re-normalizing the statistics for the node -- this is dotTrace's default behavior.

For example, I have a method that looks something like this:
public void DoStuff(int a, string b, object etc) {
  Result result = PerformNetworkOperation(a, b, etc);
  return ComplexCalculation(a, b, etc, result);
}
The PerformNetworkOperation takes a long time to execute; I know this, and I'm working on optimizing that code. But, currently, I'm interested in the ComplexCalculation method. What I'd like to see is a display similar to the following:
+ 75% DoStuff
(I click the "+" sign)
- 75% DoStuff
  + 60% PerformNetworkOperation
  + 15% ComplexCalculation
(I double-click "ComplexCalculation", and a new tab opens up)
- 100% ComplexCalculation
  + 80% DoStringTransformationForNoReason
  + 12% DoActualWork
  +  8% ConstructWrapperClasses
Thus, I can conclude that I need to eliminate the DoStringTransformationForNoReason method. Note that all the timings above are shown in percent, as in, "percent of time my program spends in this method". I think this is a more useful metric than absolute timings.

Hopefully, this wasn't too confusing...

* When I try to close ANTS, it prompts me to save the project, then to save each snapshot individually. This is excessive. Instead, ANTS should prompt me to save the project, and automatically save all snapshots. Later on, I could open up a special "Snapshot Management Window" that will let me delete the snapshots I don't want to keep.

* As someone mentioned previously, Visual Studio integration is a bit clunky. The popup menu gets auto-extended, and there seems to be no way to undo this. Once I profile some code, the results are shown in ANTS, not in VS, and ANTS uses its own internal code browser instead of using VS.

* NUnit integration doesn't seem to work. ANTS cannot profile NUnit test methods (but dotTrace can).
Bugmaster
0

Comments

3 comments

  • richardjm
    You can turn off the wizard on startup by using the /nowizard command line argument. You can modify the shortcut to the program so that it will do this
    everytime you load. The add-in will always go via the wizard so that you can check the settings created automatically.

    I prefer the All methods tab with it's grouping, filtering and sorting abilities. There is also the hierarchy view where you can see calling functions and time spent and 'drill down' that way (ooooo marketing-speak). As I've commented elsewhere on the forum we're looking into doing a much more graphical ui for the next version so the tree view is certainly something we'll be looking at closely.

    I totally agree about the way it asked you to save two different things, I'm leaning towards a more solution based saving mechanism for the next version but it's still early days yet. It's an annoyance but at least you're reminded that you've got a project and results unsaved. Oleg commented elsewhere about a save button on the toolbar for the settings but it's a bit too cluttered as it is ( the UI designers and documenters would commit GBH if I added a button at this stage :) )

    Other people have commented on the popup menu getting auto-extended at the top. We're looking into fixes for this for the final release - that's what betas are for after all.

    NUnit - you're the first person to even mention it's support as far as i know. It's easy enough to run the nunit gui from ants - that's likely what the startup of an nunit dll is anyway to it would just work from the box via add-in. If we supported one testing mechanism ( and we use nunit extensively within Red Gate) we'd clutter up the wizard even further and GBH would be committed upon me once more.

    Other than that I hope it's working well for you. We do after all allow line-level timings :D
    richardjm
    0
  • Bugmaster
    richardjm wrote:
    The add-in will always go via the wizard so that you can check the settings created automatically.
    I was with you until this last part... where are the settings created ? Is it an XML file somewhere ?
    ( the UI designers and documenters would commit GBH if I added a button at this stage :) )
    I don't know what a GBH is, but it sounds pretty severe, so please don't let them do it :-) Anyway, I think a "Save" function that saves the entire solution at once is a good approach, as you said.
    If we supported one testing mechanism ( and we use nunit extensively within Red Gate) we'd clutter up the wizard even further and GBH would be committed upon me once more.
    No no, what I meant was, support it as dotTrace supports it. With dotTrace, when I'm looking at code in the VS IDE, I see little buttons on the left margin next to each method which has the [Test] attribute. The buttons, when clicked, show a popup menu: "Debug Test" and "Profile Test". When I click "Profile Test", dotTrace launches NUnit for me, and begins profiling the method, without going through wizards or configuration setups or anything like that. I do like this feature a lot.
    Other than that I hope it's working well for you. We do after all allow line-level timings
    Is there a way to switch them into a percentage view ? As in, "your program spends 50% of its time in this line", vs., "Your program has spent this many milliseconds in this line".
    Bugmaster
    0
  • richardjm
    Bugmaster wrote:
    richardjm wrote:
    The add-in will always go via the wizard so that you can check the settings created automatically.
    I was with you until this last part... where are the settings created ? Is it an XML file somewhere ?
    The settings for the .NET Thing you're going to be evaluating are set automatically like the exe and the method filters. These you view in the wizard.
    Bugmaster wrote:
    If we supported one testing mechanism ( and we use nunit extensively within Red Gate) we'd clutter up the wizard even further and GBH would be committed upon me once more.
    No no, what I meant was, support it as dotTrace supports it. With dotTrace, when I'm looking at code in the VS IDE, I see little buttons on the left margin next to each method which has the [Test] attribute. The buttons, when clicked, show a popup menu: "Debug Test" and "Profile Test". When I click "Profile Test", dotTrace launches NUnit for me, and begins profiling the method, without going through wizards or configuration setups or anything like that. I do like this feature a lot.

    I don't imagine this happening for this version unless we get more people requesting it. It's easy enough to fire up Nunit using the VS Addin. It's most likely the startup project for the test cases anyway so doesn't involve any setting up. OK you do have to locate the test in your test cases and click play but it's hardly a hardship. We'll certainly look into it for future versions though as I can see that it would get a bit of a bind if you were doing it repetitively.
    Bugmaster wrote:
    Other than that I hope it's working well for you. We do after all allow line-level timings
    Is there a way to switch them into a percentage view ? As in, "your program spends 50% of its time in this line", vs., "Your program has spent this many milliseconds in this line".

    Simply - no, not at the moment, we're going to updating the facilities to visualise the problems soon though.
    richardjm
    0

Add comment

Please sign in to leave a comment.