Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

debug release

Posted on 1999-07-12
9
Medium Priority
?
212 Views
Last Modified: 2013-11-20
hi all !
i have release mode, and i want to debug through it.
i put a breakpoint but it doesn't stop...

help
0
Comment
Question by:Shay050799
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
  • +3
9 Comments
 
LVL 3

Expert Comment

by:danny_pav
ID: 1309680
the release mode does not have all this debug information.  if it did, then anyone could debug (and reverse engineer) your code.  also optimization and inlining can make it almost impossible to match up 1 to 1 source with machine code.  If you are having problems in release mode that is not happening in debug mode, then you should:
1. Tiughten up your debug settings to include all warnings and liberally sprinkle your code with ASSERT's.  THis may help you find the error during a run of the debug version
2. Use a tool like boundschecker on your debug build.  
3. Try using the CrashGuard utility from MSJ which will allow a map to be saved and then you can pinpoint where in the code a crash occurred.
Try these
0
 
LVL 3

Author Comment

by:Shay050799
ID: 1309681
the thing is that the application does not crush !
it gives me 2 different resolts in debug and release, it seems that in release it ignore of some return statments :)
0
 
LVL 2

Expert Comment

by:cpopin
ID: 1309682
It would help if you told us what platform/operating system you're using?

I'll assume VC++ 5.0 and Windows 95/98/NT.  Place the following line in your source code before the area that you want to start debugging:

    _asm int 3

However, now you'll be stepping through the assembly code.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 3

Author Comment

by:Shay050799
ID: 1309683
dear cpopin, i don't understand you, what help gives me the assembly code ?????? :-(
0
 
LVL 30

Accepted Solution

by:
SteveGTR earned 20 total points
ID: 1309684
See http://www.codeguru.com/debug/release_ver.shtml for information debugging in release mode.

Good Luck,
Steve
0
 
LVL 7

Expert Comment

by:leflon
ID: 1309685
check the c++ tab of your project settings in release mode
in the category 'general' set the combobox for debug info to another value than NONE
next on the link tab check 'generate debug info'
now rebuild your program, and you should be able to set breakpoints

0
 
LVL 23

Expert Comment

by:naveenkohli
ID: 1309686
In your release builds project settings...
goto C++ tab...
Set Debug info to Program Databse
Set optimizations to default

goto Link tab..
Check Generate debug info check box...

and you r ready to rock n roll :))


0
 
LVL 2

Expert Comment

by:cpopin
ID: 1309687
>> Set optimizations to default

Do NOT set optimizations to default!  You don't want to change the code generation.  Most likely Shay's discovered an optimizer discrepency.

>> dear cpopin, i don't understand you, what help gives me the assembly code ?????? :-(

Well, I was going to tell you about setting the debug info once you got tired of staring at assembly code...LOL!
0
 
LVL 3

Expert Comment

by:danny_pav
ID: 1309688
you may get different results because of an uninitialized variable.  set the warnings to level 4.  This will find things in your code you may not have been aware of.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question