C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !






Differences between Debug Assembly and Release Assembly


Posted Date: 24 Sep 2008    Resource Type: Articles    Category: .NET Framework

Posted By: Prafulla S Shimpi       Member Level: Gold
Rating:     Points: 7



Differences between Debug Assembly and Release Assembly




For compiling project., Debug and Release modes are different configurations

we generally use the Debug mode while debugging project.
But while releasing code into production environment i.e. for final build, we should compile it in Release mode for end users deployment.

If you compile in debug (/debug+), the Debuggable attribute is added to the assembly.

The main difference is that Debug mode does not optimize the binary it produces, as it is debugging quite complicate , and generates additional data to aid debugging.
i.e. it generates pdb file (program debug database), which holds all debug related information like breakpoints, assertions etc, and maps breakpoints to the execution addresses.

While, Release mode enables optimizations and generates less or possible not, extra debug data.

In the debug assembly, the IsJitOptimizerEnabled property is True, in the release assembly it is False.
we can check this attribute using ILDASM.exe utility in assembly manifest.
JIT compiler uses this attribute to disable optimizations for debug mode.


If you wish check assembly version, please add this code in the AssemblyInfo.cs file:

#if DEBUG
[assembly: AssemblyDescription("Debug")]
#else
[assembly: AssemblyDescription("Release")]
#endif

It will specify whether its DEBUG assembly or RELEASE assembly.


After compiled to Assembly file (.dll or .exe), right-click the file and check its version property:
Comments item is Dubug or Release.









Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Differences between Debug Assembly and Release Assembly  .  

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: OOPS concenpts in .Net, inheritance, Abstraction and Polymorphism
Previous Resource: Globalization and Localization
Return to Discussion Resource Index
Post New Resource
Category: .NET Framework


Post resources and earn money!
 
Related Resources



dotNet Slackers   BizTalk Adaptors    Web Design

doors in nj

Contact Us    Privacy Policy    Terms Of Use