[PATCH] D49366: Add support for /FUNCTIONPADMIN command-line option

Stefan Reinalter via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 16 02:16:32 PDT 2018


stefan_reinalter created this revision.
stefan_reinalter added a reviewer: zturner.
stefan_reinalter added a project: lld.
Herald added a subscriber: MaskRay.

This patch adds support for the /FUNCTIONPADMIN command-line option (allowing an image to be hotpatched) described here: https://msdn.microsoft.com/en-us/library/ms173524.aspx

Even though LLD understands /FUNCTIONPADMIN, all it does is ignore it. 
I added parsing of this command-line option (note that it accepts an additional integer argument specifying the number of padding bytes, e.g. /FUNCTIONPADMIN:10) and added support for it in the section chunks and when writing PDB contributions.


Repository:
  rLLD LLVM Linker

https://reviews.llvm.org/D49366

Files:
  COFF/Chunks.cpp
  COFF/Chunks.h
  COFF/Config.h
  COFF/Driver.cpp
  COFF/Driver.h
  COFF/DriverUtils.cpp
  COFF/Options.td
  COFF/PDB.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D49366.155632.patch
Type: text/x-patch
Size: 23677 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180716/9db83d06/attachment.bin>


More information about the llvm-commits mailing list