I\'m attempting to profile some c++ code on my mac (os x Lion) and I haven\'t been able to find anything useful. I\'m looking for a profiler that will tell me what functions
Instruments really is the right answer, but if you can't figure out how to use it then another option is the profiler in the built-in Activity Monitor application. In Activity Monitor you can get info on any running process and there's a button to sample its execution for a while. You'll have to start your program, switch to Activity Monitor, find the process, and then sample it.
Additionally you can do 'poor man's profiling' simply by running the program in a debugger and pausing it manually half a dozen times or so and noting the call stack at those times. It's very simple but it works surprisingly well as a first pass for a significant fraction of programs.
There is also a command line sample
program which samples the callstack like the others do.