Tag
Raymond Chen explains how Windows hot-patching handles the case where a function has already been patched by unauthorized code: such functions are declared non-hot-patchable, forcing a reboot, and race conditions can leave a binary half-patched in memory. The post explains why only Windows Update is authorized to use the reserved hot-patch space, and why mixing hot-patching with other detours is dangerous.
Raymond Chen explains why Windows hot-patching exists for x86-32, x86-64, 64-bit ARM, and Itanium but not for older or other architectures like 32-bit ARM, MIPS, Alpha AXP, PowerPC, and SH-3: most predated the hot-patching rules, while 32-bit ARM was excluded because hot-patching is a Windows Server feature and no Server version existed for that architecture.
Raymond Chen's The Old New Thing explains how Windows on Itanium implemented hot-patching using fixed-size instruction bundles and a double-wide conditional long branch instruction, contrasting it with the AArch64 approach discussed previously.
Raymond Chen explains how Windows on AArch64 implements function hot-patching more simply than on x86, using a 12-byte patch space and a three-instruction trampoline via the xip0 scratch register, noting that pointer authentication (pacibsp) usually guards the function entry.