[PATCH] D82503: [llvm-objcopy][MachO] Fix segment size alignment

Alexander Shaposhnikov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 24 14:40:53 PDT 2020


alexshap created this revision.
alexshap added reviewers: smeenai, jhenderson, MaskRay, compnerd.
alexshap created this object with visibility "All Users".
Herald added a reviewer: rupprecht.
Herald added a subscriber: abrachet.
Herald added a project: LLVM.
alexshap updated this revision to Diff 273163.
alexshap added a comment.

Minor update


This diff addresses the old TODO in MachOObjcopy.cpp and correctly sets the page size used for alignment of segments.
In particular, now llvm-objcopy's output is consistent with the input (the alignment of vmsize doesn't change).

Test plan:

1. make check-all
2. verify that alignment of segment vmsize is not changed by llvm-objcopy for ios/watchos/osx binaries
3. verify that a binary copied via llvm-objcopy now correctly works on iOS.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D82503

Files:
  llvm/test/tools/llvm-objcopy/MachO/segment-size-alignment.test
  llvm/tools/llvm-objcopy/MachO/MachOObjcopy.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82503.273163.patch
Type: text/x-patch
Size: 27889 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200624/a7ba9cb7/attachment.bin>


More information about the llvm-commits mailing list