Tag Archives: profiling

Knowing Where to Type ‘Zero’

Some code optimizations requires complex data structures and thousands lines of code. But, in a surprising number of cases, significant improvements can be made by simple changes – sometimes as simple as typing a single zero. It’s like the old … Continue reading

Posted in Performance | Tagged , , , | 18 Comments

Summarizing Xperf CPU Usage with Flame Graphs

Xperf is a powerful (and free) Windows profiler that provides amazing insights into what is constraining the performance of Windows programs. Xperf includes a sampling profiler and a very capable viewer of the sampled call stacks (see below for UIforETW … Continue reading

Posted in Performance, xperf | Tagged , , , | 29 Comments

Counting to Ten on Linux

I recently discovered a Linux shell script that was running slowly due to an inefficiently implemented loop. This innocent investigation ended up uncovering misleading information from time and a bad interaction between the Linux thread scheduler and its CPU power … Continue reading

Posted in Investigative Reporting, Linux, Performance | Tagged , , , , | 38 Comments

Visual Studio Single Step Performance Fixes

Single-stepping through code in Visual Studio is usually fast, but sometimes it is torturously painfully slow. When I ran into this recently – twice – I used xperf to find the sources of the slowdowns, and then work around them. … Continue reading

Posted in Investigative Reporting, Visual Studio, xperf | Tagged , , , , , | 15 Comments

WPA–Xperf Trace Analysis Reimagined

For many years xperfview.exe has been the main tool for analyzing xperf/ETW traces. However starting in fall 2011 the Windows Performance Toolkit started including wpa.exe as an alternative. While the early versions had some significant rough edges, the latest version … Continue reading

Posted in AltDevBlogADay, Performance, Programming, xperf | Tagged , , , | 20 Comments