Re: managed c++ and native c++ interop

From: Ronald Laeremans [MSFT] (ronaldl_at_online.microsoft.com)
Date: 06/02/04


Date: Wed, 2 Jun 2004 16:31:04 -0700

Hi Jim,

There are know bugs in the debugger interop stepping code. The only thing in
general you can do it to try and avoid stepping over these points as much as
possible (e.g. by setting breakpoints rather than stepping).

Ronald Laeremans
Visual C++ team

"Jim" <jim@jim.com> wrote in message
news:%23tf$dOPSEHA.624@TK2MSFTNGP11.phx.gbl...
> Thanks for your quick response Gary,
>
> My program works find in both release and debug mode, it is only when I'm
> stepping through it in the debugger that the problems occour.
>
> "lots of the interop marshalling work across the managed/unmanaged
> boundary
> will squeeze out the capability of the debugger sometimes"
>
> I am running on a 3Ghz machine with a Gig of Ram. I understand that the
> interop marshalling can be expensive, but I would think my machine could
> handle it. When you say that lots of marshalling will squeeze out the
> capability of the debugger, what exactly do you mean by "lots"? Are there
> any papers or technical articles about this? It is very important for me
> to
> be able to step through my code in the debugger, and I am very interested
> in
> any known limitations of the debugger.
>
> Thanks again!
>
> -Jim
>
>
> "Gary Chang" <v-garych@online.microsoft.com> wrote in message
> news:TcZrpg8QEHA.3804@cpmsftngxa10.phx.gbl...
>> Hi Jim,
>>
>> > The problem is debugging. Visual Studio is having a very hard time
>> stepping
>> > through my project. It constantly hangs and/or crashes. I have never
>> > had
>> > problems like this before, and it seems to only be related to combining
>> > managed c++ and native c++ classes in the same project.
>>
>> Which caused the hangs/crashes of your program's debugging process?
>>
>> Does your program crash under release mode?
>>
>> If it is the heavy work load of the debugging process causes your
>> debugger
>> hang, it would be as expected; lots of the interop marshalling work
>> across
>> the managed/unmanaged boundary will squeeze out the capability of the
>> debugger sometimes.
>>
>>
>> Thanks for your understanding!
>>
>> Best regards,
>>
>> Gary Chang
>> Microsoft Online Partner Support
>>
>> Get Secure! - www.microsoft.com/security
>> This posting is provided "AS IS" with no warranties, and confers no
> rights.
>> --------------------
>>
>
>



Relevant Pages

  • Re: Learning C
    ... I stress that I talking about "stepping through an application". ... And how can stepping through an app be bad? ... I did not step through the code with a debugger. ... "examine", to me, means to study the source code. ...
    (comp.lang.c)
  • Re: Learning C
    ... with a debugger. ... I stress that I talking about "stepping through an application". ... But often loggers affect the app. ... "examine", to me, means to study the source code. ...
    (comp.lang.c)
  • Re: Good debugger?
    ... > Stepping through a script sequence, one line at a time, and watching ... > the variables change values as you do so is a much better approach to ... > think I've ever seen a debugger do that before). ... especially Tkcon) is a single step tool. ...
    (comp.lang.tcl)
  • RE: Step by Step skips large chunks of code
    ... Putting on SP1 the problem occurred. ... the debugger seems to work OK in the main thread ... let us monitor the threads in the Threads window. ... Then start stepping code. ...
    (microsoft.public.vsnet.debugging)
  • Changing source on the fly (Was: Lisp Book(s) in the K&R Style)
    ... Is it possible in CMUCL to change the source when stepping through the ... the source of the very function or loop you are ... curious when I will find it in any lisp debugger. ...
    (comp.lang.lisp)