Hacker News new | past | comments | ask | show | jobs | submit login
Debugging Optimized Code–New in Visual Studio 2012 (randomascii.wordpress.com)
36 points by ProgC on Sept 13, 2013 | hide | past | favorite | 3 comments



As I recently had to debug a nasty issue that only occurred in release builds in VS2010 I would definitely have liked to know about this earlier. Almost all the variables that were important in that case were inaccessible in the debugger which made finding out the root of the issue quite difficult.


Once upon a time back when Visual C++ 5 was the latest version, I had to convert a small application from C++ back to C, due to debugger issues.

The generated code made the debugger bork, and I really needed it for the type of project we were doing, in terms of productivity.

So after the effort it took me to convince our teacher to deliver the project in C++, I ended up doing it in C like everyone else in class.


You can globally enable this option without changing .vcxproj by adding it in the CL or _CL_ environment variables (the former prepends options, the latter appends)

Thanks to Geoff Chapel for it, there are plenty more undocumented options on his site too: http://www.geoffchappell.com/studies/msvc/cl/cl/options/




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: