I have activated the Control Flow Guard option (/guard:cf) to compile C++ programs in debug mode with Visual Studio 2017.
When I step inside a function with the debugger, Visual Studio shows the following page:
This is quite anoying. I would like to get rid of this page. Do you know where I can find or download the source of guard_dispatch.asm
?
In the following VC path, I see some assembly files like memcpy.asm
but there is no guard_dispatch.asm
:
C:\dev\vs150\VC\Tools\MSVC\14.16.27023\crt\src\i386
If I look the callstack, the debugger stops in _guard_dispatch_icall_nop ()
:
I've tried to define natstepfilter rule to don't step into this function but it doesn't help:
<?xml version="1.0" encoding="utf-8"?>
<StepFilter xmlns="http://schemas.microsoft.com/vstudio/debugger/natstepfilter/2010">
<Function><Name>_guard_dispatch_icall_nop</Name><Action>NoStepInto</Action></Function>
</StepFilter>
I've tried also to uncheck the checkbox at DEBUG / Options / Debugging / General / Enable address-level debugging / Show disassembly if source is not available
but it doesn't help.
Any ideas how to get ride of this page?
After experimenting various things during a day, I have found one solution to this issue. The page guard_dispatch.asm not found
doesn't appear if the code is compiled with the option /JMC
(Just My Code). From UI, this option can be set through: Configuration Properties / C/C++ / General / Support Just My Code Debugging
.