It is my understanding - and please correct me if I'm wrong - that when
building a project in debug mode, I can deploy the .pdb file along with the
..exe and thereby have access to the specific line number of code that throws
an exception. Specifically, I can have an error logging routine that,
amongst other things parses the call stack and tells me the specific line of
code that choked.
It is also my understanding that if building in Release mode that I won't
get the .pdb file and/or have programmatic knowledge of the specific line of
code that threw an exception.
If the above is true, then that would seem to be a big advantage of building
in debug mode and putting that into production - rather than building in
release mode.
What do you think?
I'm looking for reasons to build in "Release mode" but can't seem to get
past the fact that I lose the knowledge of which line of code choked.
I would appreciate your perspective on this... and what is different about
building as Release vs. Debug. 3 1976
Never ever put debug builds into production. Your build process should emit
release builds, so all system testing is on production code.
You CAN create pdbs for release builds; in VS 2005, go to project
properties, Build, set the Configuration to Release, click Advanced, and set
Debug Info to pdb-only (not the default). Microsoft recommend not using full
info for release builds, as this impacts size, performance and code quality,
whereas pdb-only does not.
However you do not need a pdb to find out where an exception occurred - just
log Exception.ToStr ing(), which includes the stack trace.
The pdb is useful if you want to debug the production system, e.g., attach a
debugger to the running process (requires full info), or debug a crash dump.
You can do this using windbg, part of the Microsoft Debugging Tools for
Windows.
"Bob Johnson" wrote:
It is my understanding - and please correct me if I'm wrong - that when
building a project in debug mode, I can deploy the .pdb file along with the
..exe and thereby have access to the specific line number of code that throws
an exception. Specifically, I can have an error logging routine that,
amongst other things parses the call stack and tells me the specific line of
code that choked.
It is also my understanding that if building in Release mode that I won't
get the .pdb file and/or have programmatic knowledge of the specific line of
code that threw an exception.
If the above is true, then that would seem to be a big advantage of building
in debug mode and putting that into production - rather than building in
release mode.
What do you think?
I'm looking for reasons to build in "Release mode" but can't seem to get
past the fact that I lose the knowledge of which line of code choked.
I would appreciate your perspective on this... and what is different about
building as Release vs. Debug.
"Adrian" <Ad****@discuss ions.microsoft. comwrote in message
news:BD******** *************** ***********@mic rosoft.com...
However you do not need a pdb to find out where an exception occurred -
just
log Exception.ToStr ing(), which includes the stack trace.
But if you do deploy the pdb file, you will get much more detailed
information about the exception, even down to the number of the line which
threw it...
--
Mark Rae
ASP.NET MVP http://www.markrae.net
We've been deploying Release builds with PDB files for years now. It's just
an option in Visual Studio, and it's also easily set using MSBuild or NAnt.
Without the ability to do this, we would be screwed.
--
Chris Mullins
"Bob Johnson" <A@B.comwrote in message
news:%2******** **********@TK2M SFTNGP04.phx.gb l...
It is my understanding - and please correct me if I'm wrong - that when
building a project in debug mode, I can deploy the .pdb file along with
the .exe and thereby have access to the specific line number of code that
throws an exception. Specifically, I can have an error logging routine
that, amongst other things parses the call stack and tells me the specific
line of code that choked.
It is also my understanding that if building in Release mode that I won't
get the .pdb file and/or have programmatic knowledge of the specific line
of code that threw an exception.
If the above is true, then that would seem to be a big advantage of
building in debug mode and putting that into production - rather than
building in release mode.
What do you think?
I'm looking for reasons to build in "Release mode" but can't seem to get
past the fact that I lose the knowledge of which line of code choked.
I would appreciate your perspective on this... and what is different about
building as Release vs. Debug.
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: bnc mag |
last post by:
Hello,
Visual Studio 6 allows users to specify seperate post-build steps to
perform on Debug and Release builds. I am trying to do the same thing
in C#.NET 2003, but it appears as though I only get to specify *one* set
of post-build steps, regardless of whether I am building in Debug or
Release.
I would like to copy my resulting DLLs into respective "Debug" and
"Release" directories elsewhere on my machine, hence my need for such a
|
by: babyx |
last post by:
The release build class library can only work with msvcr71d.dll and
msvcp71d.dll exist. How to make this class library work on any
machine without using the debug dlls? What are the project settings
that i need to take note so that it will become a "real" release
build without depending on the debug dll?
Can anybody help?
Posted Via Usenet.com Premium Usenet Newsgroup Services
|
by: David++ |
last post by:
Hi there,
I have built a DLL in Visual C++ 6. When I build the DLL it builds fine for
the debug version of the DLL (and this DLL works fine), however, I seem
unable to build a Release version of the DLL. If I do a 'Batch Build' and
select both Debug and Relase versions for building it will build the debug
version but throws up errors for the Release version. For example, the output
I get for a Batch Build is this -
...
|
by: Tom |
last post by:
How can I make code not execute for a debug build, but do
execute for a production build?
I have code which prompts for an account and password when
the program starts up. It is a pain to have to answer that
when I repeatly run the program during debugging, but it
is desired by my client. Presently I just comment it out
when I am debugging, but I was wondering if there was a
more automatic way? Some type of conditional compilation...
|
by: Andrew Rowley |
last post by:
I am having trouble getting debug and release builds to work properly
with project references using C++ .NET and Visual Studio 2003.
I created a test solution, with a basic Windows form C++ project.
I then add a class library, and add a reference to this project in the
first project.
When I do a release build, I see the following in the output from the
DLL compile:
/OUT:"C:\Documents and Settings\Andrew\My Documents\Visual Studio
| |
by: Zytan |
last post by:
When I do this, all code in the middle turns gray. I assume this is
because DEBUG is not defined. But, I thought it was for debug mode.
Is there something I am missing, or do people manually add DEBUG to
the debug mode compilation? How do I tell the IDE which mode I am
currently in (debug / release), like VC++ allows me to (it says in a
toolbar which compilation mode you are currently in)? Perhaps I am
merely in release mode, and thus...
|
by: Bob Johnson |
last post by:
It is my understanding - and please correct me if I'm wrong - that when
building a project in debug mode, I can deploy the .pdb file along with the
..exe and thereby have access to the specific line number of code that throws
an exception. Specifically, I can have an error logging routine that,
amongst other things parses the call stack and tells me the specific line of
code that choked.
It is also my understanding that if building in...
|
by: =?Utf-8?B?SHVnaA==?= |
last post by:
Hi there
We are trying to build a C sharp solution in Visual Studio 2005 Professional.
We have a number of other assemblies, that do not form part of the solution.
Assemblies that do form part of the solution have been referenced using the
Projects tab in the Add Reference dialog.
Assemblies that do not form part of the solution have been added usingthe
|
by: Andy B |
last post by:
How do you tell vs2005 to keep debug info out of your release builds? When I
build a release and a debug version, there seems to be no difference in them
at all...The release builds still have the debug databases with them...
|
by: =?Utf-8?B?bG10dGFn?= |
last post by:
We have developed a number of different applications (ASP.NET web site,
Windows services, DLLs, Windows forms, etc.) in C# 2.0. We have developed
and unit tested all these applications/components using Debug mode. Now we
are ready to compile everything for release to production. However, we don’t
know whether we should compile all the applications/components/assemblies
using Release mode (or keep everything in Debug mode).
We’ve...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |