Shark vs Instruments (can I run Shark on Yosemite?)

Discussion in 'Mac Programming' started by asiga, Jul 21, 2015.

  1. asiga macrumors 6502a

    Nov 4, 2012
    Short version of the question: Can I run Shark in Yosemite? How?

    Larger explanation:
    Is Instruments really meant to offer all the Shark functionality? I keep one of my Macs at Snow Leopard, and I always prefer to profile my code with that Mac instead of the other ones running Yosemite and ML, because Shark lets me do stuff that Instruments won't.

    For example, with Instruments I always find it very difficult to get to the functions causing bottlenecks: I've to manually unfold the call tree level by level. Even if I reverse the tree, I always find it uncomfortable, because there're tons and tons of internal OSX functions I don't care about (even if I disable the option to see system functions, I always get a lot of undesired functions from UI code).

    With Shark, it's always a pleasure: you run it, you get a perfect list of candidate functions to optimize. No need to unfold infinite call trees, you don't get undesired functions... everything perfect.

    Another point is that Shark lets me select several lines of the profiled code, and it sums their self time, displaying at the bottom of the window. This is very convenient, because let's you choose the best set of lines to optimize. Instruments can't do this, it won't add the time spent in several selected lines.

    Alternatively, if it's really impossible to use Shark on Yosemite, is there any commercial profiler that you'd recommend, for getting the Shark functionality on Yosemite?

  2. szymczyk macrumors regular

    Mar 5, 2006
    I don't know of any way to run Shark in Yosemite or any alternatives to Instruments. I can provide a tip to make Instruments less painful. Option-clicking a disclosure triangle in the call tree expands the whole call tree so you don't have to unfold the call tree level by level.
  3. asiga thread starter macrumors 6502a

    Nov 4, 2012
    Thanks a lot for this tip. IMHO, Instruments is a step backwards compared to Shark. Yes, Instruments has more measuring modes. But in the subject of time profiling, Shark beats Instruments out of the water (pun intended).

    It's sad there's nothing comparable to Shark on Yosemite.

Share This Page