Export (0) Print
Expand All
Expand Minimize

/hotpatch (Create Hotpatchable Image)

Prepares an image for hotpatching.

/hotpatch

When /hotpatch is used in a compilation, the compiler ensures that first instruction of each function is at least two bytes, which is required for hot patching.

After compiling with /hotpatch, you must link with /FUNCTIONPADMIN (Create Hotpatchable Image), which completes the preparation for making an image hotpatchable. When you compile and link an image with a single invocation of cl.exe, /hotpatch implies /functionpadmin.

Because instructions are always two bytes or larger on the ARM and Itanium Processor Family (IPF) architectures, and because x64 compilation is always treated as if /hotpatch has been specified, it's not necessary to specify /hotpatch when compiling for these targets, however you must still link with /functionpadmin to create hotpatchable images for these targets. The /hotpatch compiler option only affects x86 compilation.

To set this compiler option in the Visual Studio development environment

  1. Open the project's Property Pages dialog box. For details, see How to: Open Project Property Pages.

  2. Click the C/C++ folder.

  3. Click the Command Line property page.

  4. Type the compiler option in the Additional Options box.

To set this compiler option programmatically

Guidance

For more information about update management, see "Security Guidance for Update Management" at http://www.microsoft.com/technet/security/guidance/PatchManagement.mspx.

Show:
© 2014 Microsoft