-
Recent Posts
Categories
- AltDevBlogADay
- Bugs
- Chromium
- Code analysis
- Code Reliability
- Commuting
- Computers and Internet
- Debugging
- Documentation
- Drinks
- Environment
- Floating Point
- Fractals
- Fun
- Gaming
- Investigative Reporting
- Linux
- Math
- memory
- Performance
- Programming
- Quadratic
- Rants
- Security
- Symbols
- Travel
- uiforetw
- Uncategorized
- Unicycling
- Visual Studio
- WLPG
- Xbox 360
- xperf
Follow me on Twitter
My TweetsMeta
Category Archives: Visual Studio
Delete an inline function, save 794 kB
In the previous episode of “Simple Changes to Shrink Chrome” I discussed how deleting ‘const’ from a few key locations could lead to dramatic size savings, due to a VC++ compiler quirk. In this episode I’ll show how deleting an … Continue reading
Add a const here, delete a const there…
Update, February 2019: Two years later the VC++ bug I reported here still exists, even in VS 2019 preview. However Chromium no longer builds with VC++ so I’m reverting the changes where I deleted const in order to make some … Continue reading
VC++ /arch:AVX option – unsafe at any speed
Microsoft’s VC++ compiler has an option to generate instructions for new instruction sets such as AVX and AVX2, which can lead to more efficient code when running on compatible CPUs. So, an obvious tactic is to compile critical math-heavy functions … Continue reading
Zeroing Memory is Hard (VC++ 2015 arrays)
Quick, what’s the difference between these two C/C++ definitions of initialized local variables? char buffer[32] = { 0 };char buffer[32] = {}; One difference is that the first is legal in C and C++, whereas the second is only legal … Continue reading
Compiler Bugs Found When Porting Chromium to VC++ 2015
Moving a big software project to a new compiler can be a lot of work, and few projects are bigger than Chromium. In addition to the main Chromium repository, which includes all of Blink, there are over a hundred other … Continue reading
Posted in Programming, Visual Studio
Tagged Chromium, code generation, VC++ 2015, visual studio
29 Comments
Thread Naming in Windows: Time for Something Better
Windows lets you give names to the threads in your process which can then be displayed by debuggers. This is a great idea, but the implementation is showing its age – it’s time for some fixes, or something better. Update, … Continue reading
Posted in Debugging, Programming, Visual Studio
Tagged debuggers, threading, Threads, Windows
16 Comments
Programming is Puzzles
When I’m describing what I do for a living to non-programmers I sometimes say that I solve puzzles. I solve fascinating puzzles that are different every day, and there’s no answer key, and very often nobody else knows the solution. … Continue reading
Posted in Investigative Reporting, Performance, Programming, Visual Studio
Tagged fastlink, linking, VC++, visual studio
11 Comments
Self Inflicted Denial of Service in Visual Studio Search
After upgrading to Visual Studio 2013 I noticed that find-in-files had a problem when searching directories. The VS IDE would repeatedly hang, rendering it completely useless for the duration of the search. I filed a bug, complete with ETW traces … Continue reading
Posted in Investigative Reporting, Performance, Programming, Visual Studio, xperf
Tagged denial of service, native command queuing
11 Comments
You Got Your Web Browser in my Compiler!
I recently discovered that Microsoft’s VC++ compiler loads mshtml.dll – also known as Internet Explorer. The compiler does this whenever the /analyze option (requesting static code analysis) is used. I’m no compiler architecture expert, but a compiler that loads Internet … Continue reading
Posted in Code analysis, Investigative Reporting, Performance, Visual Studio, xperf
Tagged carl sagan, nuclear testing, peanut butter, rhetoric
84 Comments
Make VC++ Compiles Fast Through Parallel Compilation
The free lunch is over and our CPUs are not getting any faster so if you want faster builds then you have to do parallel builds. Visual Studio supports parallel compilation but it is poorly understood and often not even … Continue reading
Posted in Performance, Visual Studio, xperf
Tagged cl.exe, ETW, VC++, visual studio, xperf
50 Comments