Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual C++: memory debugger refresh while running

In Visual C++ 2015, the memory debugger window shows

"Unavailable when debuggee is running."

when the process is running.

Is it possible to show and reevaluate the memory at a certain address without pause the process, like a live view?

like image 864
Giovanni Cerretani Avatar asked Dec 10 '25 12:12

Giovanni Cerretani


1 Answers

Yes, it is possible. Place a breakpoint, open breakpoint settings button (gear) and set action to print log message containing the value of variable of interest such as {var_name}. Example:

auto i{0u};
for(;;)
{
   ++i;
}

enter image description here

will print the value of i into VS output window every 10000 iterations.

This screenshot if from VS2017, but it should probably work for VS2015 as well.

like image 154
user7860670 Avatar answered Dec 12 '25 01:12

user7860670



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!