Question:
Visual Studio .NET - Debug vs Release?
zerohourx
2007-07-18 08:06:50 UTC
Im using Visual Studio 2003 .NET. I flip between Debug and Release mode when testing locally and then moving modules to production. Thge debug content comes as a .DLL and a releated .PDB file.

I've copied the debug .DLL to production and havent discovered any problems. When i perform a release compile the .DLL produced appears to be identical to debug's DLL. Is theer an advantage to flicking to release mode over directly using the debug's .DLL? From what i can see there is no difference. The debug code seems to be all located in the .PDB file which i never copy.

Tx
Three answers:
Smutty
2007-07-18 11:54:38 UTC
Yes there are differences and the proof for that is, when built under release mode, some statements such as Debug.WriteLine () or Debug.Assert() will be removed from the assembly.



In your case perhaps the two assemblies are similar but this not always the case.



Hope this helps.
SharpCoder
2007-07-18 09:50:03 UTC
A Visual Studio project has separate configurations for Release and Debug versions of your program. As the names imply, you build the Debug version for debugging and the Release version for the final release distribution.



If you create your program in Visual Studio, Visual Studio automatically creates these configurations and sets appropriate default options and other settings. With the default settings:



The Debug configuration of your program is compiled with full symbolic debug information and no optimization. Optimization complicates debugging, since the relationship between source code and generated instructions is more complex.



The Release configuration of your program is fully optimized and contains no symbolic debug information. Debug information may be generated in PDB Files (C++) depending on the compiler options used. Creating PDB files can be very useful if you later need to debug your release version. But performance is increased in Release mode.
?
2016-05-21 22:43:59 UTC
You shouldn't be installing 2012 on the same machine as 2010. They both install to the same file locations and when you installed 2012, you overwrote all the 2010 files. If you were testing out 2012, you should have installed it on a virtual PC. At this point, you need to uninstall 2012 and 2010, and then just install 2010. Edit: For someone who's suppose to be a programmer, you aren't very bright. I figured you should have known you have to delete the debug folder. Also why aren't you just calling MSDN? You do get tech support with your MSDN subscription that comes with the purchase of VS 2010 Ultimate. @Canta; If you look, he has 2 completely different version of VS. 2010 ultimate and 2012 Test Professional. I had the same type of conflict when I had 2008 Team System Team Suite and tried to install 2010 Professional


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...