[c++] What's the best free C++ profiler for Windows?

I'm looking for a profiler in order to find the bottleneck in my C++ code. I'd like to find a free, non-intrusive, and good profiling tool. I'm a game developer, and I use PIX for Xbox 360 and found it very good, but it's not free. I know the Intel VTune, but it's not free either.

This question is related to c++ windows profile

The answer is


Another profiler is Shiny.

?????


Please try my profiler, called cRunWatch. It is just two files, so it is easy to integrate with your projects, and requires adding exactly one line to instrument a piece of code.

http://ravenspoint.wordpress.com/2010/06/16/timing/

Requires the Boost library.


Very Sleepy is a C/C++ CPU profiler for Windows systems (free).


I highly recommend Windows Performance Toolkit (WPT) or XPERF

The command line xperf command line tool records Event Tracing for Windows (ETW) logs that can be analyzed using the GUI xperfview tool.

Using stacktrace command line arguement has proven to be an invaluable tool for my company as it profiles and troubleshoots bottlenecks. One of the most compelling things is that the WPT can be installed in any environment even on the venerable Windows XP.

On Windows 8 the Windows Performance Analyzer takes xperf to an even higher level.

The hard numbers and stats provided in ETW logs are unparalleled in detail except for visual studio profiler (2010/2012) which is also great but not free AFAIK.

If you have never used xperf...you do not know what you are missing


I've used "TrueTime - part of Compuware's DevPartner suite for years. There's a [free version](you could try Compuware DevPartner Performance Analysis Community Edition.) available.


You can use EmbeddedProfiler, it's free for both Linux and Windwos.

The profiler is intrusive (by functionality) but it doens't require any code modifications. Just add a specific compiler flag (-finstrument-functios for gcc/MinGW or /GH for MSVC) and link the profiler's library. It can provide you a full call tree or just a funciton list. It has it's own analyzer GUI.


Microsoft has the Windows Performance Toolkit.

It does require Windows Vista, Windows Server 2008, or Windows 7.


I use AQTime, it is one of the best profiling tools I've ever used. It isn't free but you can get a 30 day trial, so if you plan on a optimizing and profiling only one project and 30 days are enough for you then I would recommend using this application. (http://www.automatedqa.com/downloads/aqtime/index.asp)


I used Luke Stackwalker and it did the job for my Visual Studio project.

Other interesting projects are:


Very Sleepy is a C/C++ CPU profiler for Windows systems (free).


Proffy is quite cool: http://pauldoo.com/proffy/

Disclaimer: I wrote this.


There is an instrumenting (function-accurate) profiler for MS VC 7.1 and higher called MicroProfiler. You can get it here (x64) or here (x86). It doesn't require any modifications or additions to your code and is able of displaying function statistics with callers and callees in real-time without the need of closing application/stopping the profiling process.

It integrates with VisualStudio, so you can easily enable/disable profiling for a project. It is also possible to install it on the clean machine, it only needs the symbol information be located along with the executable being profiled.

This tool is useful when statistical approximation from sampling profilers like Very Sleepy isn't sufficient.

Rough comparison shows, that it beats AQTime (when it is invoked in instrumenting, function-level run). The following program (full optimization, inlining disabled) runs three times faster with micro-profiler displaying results in real-time, than with AQTime simply collecting stats:

void f()
{
    srand(time(0));

    vector<double> v(300000);

    generate_n(v.begin(), v.size(), &random);
    sort(v.begin(), v.end());
    sort(v.rbegin(), v.rend());
    sort(v.begin(), v.end());
    sort(v.rbegin(), v.rend());
}

Another profiler is Shiny.

?????


Proffy is quite cool: http://pauldoo.com/proffy/

Disclaimer: I wrote this.


I use AQTime, it is one of the best profiling tools I've ever used. It isn't free but you can get a 30 day trial, so if you plan on a optimizing and profiling only one project and 30 days are enough for you then I would recommend using this application. (http://www.automatedqa.com/downloads/aqtime/index.asp)


I've used "TrueTime - part of Compuware's DevPartner suite for years. There's a [free version](you could try Compuware DevPartner Performance Analysis Community Edition.) available.


Microsoft has the Windows Performance Toolkit.

It does require Windows Vista, Windows Server 2008, or Windows 7.


I use VSPerfMon which is the StandAlone Visual Studio Profiler. I wrote a GUI tool to help me run it and look at the results.

http://code.google.com/p/vsptree/


Please try my profiler, called cRunWatch. It is just two files, so it is easy to integrate with your projects, and requires adding exactly one line to instrument a piece of code.

http://ravenspoint.wordpress.com/2010/06/16/timing/

Requires the Boost library.


I used Luke Stackwalker and it did the job for my Visual Studio project.

Other interesting projects are:


I use VSPerfMon which is the StandAlone Visual Studio Profiler. I wrote a GUI tool to help me run it and look at the results.

http://code.google.com/p/vsptree/


There is an instrumenting (function-accurate) profiler for MS VC 7.1 and higher called MicroProfiler. You can get it here (x64) or here (x86). It doesn't require any modifications or additions to your code and is able of displaying function statistics with callers and callees in real-time without the need of closing application/stopping the profiling process.

It integrates with VisualStudio, so you can easily enable/disable profiling for a project. It is also possible to install it on the clean machine, it only needs the symbol information be located along with the executable being profiled.

This tool is useful when statistical approximation from sampling profilers like Very Sleepy isn't sufficient.

Rough comparison shows, that it beats AQTime (when it is invoked in instrumenting, function-level run). The following program (full optimization, inlining disabled) runs three times faster with micro-profiler displaying results in real-time, than with AQTime simply collecting stats:

void f()
{
    srand(time(0));

    vector<double> v(300000);

    generate_n(v.begin(), v.size(), &random);
    sort(v.begin(), v.end());
    sort(v.rbegin(), v.rend());
    sort(v.begin(), v.end());
    sort(v.rbegin(), v.rend());
}

I use AQTime, it is one of the best profiling tools I've ever used. It isn't free but you can get a 30 day trial, so if you plan on a optimizing and profiling only one project and 30 days are enough for you then I would recommend using this application. (http://www.automatedqa.com/downloads/aqtime/index.asp)


You can use EmbeddedProfiler, it's free for both Linux and Windwos.

The profiler is intrusive (by functionality) but it doens't require any code modifications. Just add a specific compiler flag (-finstrument-functios for gcc/MinGW or /GH for MSVC) and link the profiler's library. It can provide you a full call tree or just a funciton list. It has it's own analyzer GUI.


I highly recommend Windows Performance Toolkit (WPT) or XPERF

The command line xperf command line tool records Event Tracing for Windows (ETW) logs that can be analyzed using the GUI xperfview tool.

Using stacktrace command line arguement has proven to be an invaluable tool for my company as it profiles and troubleshoots bottlenecks. One of the most compelling things is that the WPT can be installed in any environment even on the venerable Windows XP.

On Windows 8 the Windows Performance Analyzer takes xperf to an even higher level.

The hard numbers and stats provided in ETW logs are unparalleled in detail except for visual studio profiler (2010/2012) which is also great but not free AFAIK.

If you have never used xperf...you do not know what you are missing


I've used "TrueTime - part of Compuware's DevPartner suite for years. There's a [free version](you could try Compuware DevPartner Performance Analysis Community Edition.) available.


Examples related to c++

Method Call Chaining; returning a pointer vs a reference? How can I tell if an algorithm is efficient? Difference between opening a file in binary vs text How can compare-and-swap be used for a wait-free mutual exclusion for any shared data structure? Install Qt on Ubuntu #include errors detected in vscode Cannot open include file: 'stdio.h' - Visual Studio Community 2017 - C++ Error How to fix the error "Windows SDK version 8.1" was not found? Visual Studio 2017 errors on standard headers How do I check if a Key is pressed on C++

Examples related to windows

"Permission Denied" trying to run Python on Windows 10 A fatal error occurred while creating a TLS client credential. The internal error state is 10013 How to install OpenJDK 11 on Windows? I can't install pyaudio on Windows? How to solve "error: Microsoft Visual C++ 14.0 is required."? git clone: Authentication failed for <URL> How to avoid the "Windows Defender SmartScreen prevented an unrecognized app from starting warning" XCOPY: Overwrite all without prompt in BATCH Laravel 5 show ErrorException file_put_contents failed to open stream: No such file or directory how to open Jupyter notebook in chrome on windows Tensorflow import error: No module named 'tensorflow'

Examples related to profile

Missing Push Notification Entitlement Spring profiles and testing How to add /usr/local/bin in $PATH on Mac Do you know the Maven profile for mvnrepository.com? A valid provisioning profile for this executable was not found for debug mode Getting the "real" Facebook profile picture URL from graph API How to reload .bashrc settings without logging out and back in again? What's the best free C++ profiler for Windows?