If you are a Windows developer and want to see how much system resources your designed application is consuming than you can make use of a freeware tool called PerfView. It is a free performance analysis tool from Microsoft. It can be used to view and log the usage of your PC resources by an individual process.
Mainly used by the application developers, PerfView is a portable tool and is now open-source. Microsoft has released its source code through their Github page. its source code is written using the Microsoft C# language. You can download the source code yourself and compile using Microsoft Visual Studio – Community Edition.
PerfView can be used for CPU usage investigation. It can track Windows Events to see how each of the instructions from an application is affecting the CPU usage. It can isolate the CPU instructions and show you the usage information only from a particular program.
Similarly, it can also be used to investigate unmanaged memory allocations. It can show the details of the events when a program allocates some memory on the heap, when this memory is re-allocated, and when this memory is freed. This way you can track if a program is leaking the data into memory that was not freed. If the program is using .NET garbage collector, then PerfView can also track the managed memory allocation from the .NET GC heap.
If your target program has become very slow but at the same time it is not consuming the CPU, then we can use PerfView to find out what is making the program stop or take too much time. For example, it can show you if the program is waiting for some response from a network or online connection.
PerfView can help you diagnose the problems in a program that you are developing using system resource analysis. Microsoft also offers many tutorial videos for learning how to use PerfView properly.
You can download Microsoft PerfView tool from https://github.com/microsoft/perfview.