What would you suggest the best tool to profile C/C++ code and determine which parts are taking the most time. Currently, I'm just relying on logs but ofcourse the information is not accurate since unnecessary delays are introduced.
Preferrably, the tool would also be able to detect/suggest areas which could be optimized, if such tool exist.
Platform: Linux
The application shall be used on an embedded environment so it should be lightweight and external (not a plugin on some IDE).