[PATCH] D41619: [llvm-objcopy] Use physical instead of virtual address when aligning and placing sections in binary
Owen Shaw via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 10 14:10:11 PST 2018
owenpshaw updated this revision to Diff 129336.
owenpshaw added a comment.
Updated according to suggestions. I didn't change to using member pointers, but can if you prefer. While I usually agree that de-duplication is best, in this case I feel like it makes the calling code more difficult to decipher in exchange for little gain in de-duplication.
std::stable_sort(start, end, compareSegmentsByOffset);
// vs
using namespace std::placeholders;
std::stable_sort(start, end, std::bind(compareSegmentsBy, &Segment::OriginalOffset, _1, _2))
https://reviews.llvm.org/D41619
Files:
test/tools/llvm-objcopy/basic-align-copy.test
test/tools/llvm-objcopy/binary-no-paddr.test
test/tools/llvm-objcopy/binary-paddr.test
test/tools/llvm-objcopy/binary-segment-layout.test
test/tools/llvm-objcopy/two-seg-remove-end.test
test/tools/llvm-objcopy/two-seg-remove-first.test
test/tools/llvm-objcopy/two-seg-remove-third-sec.test
tools/llvm-objcopy/Object.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41619.129336.patch
Type: text/x-patch
Size: 10120 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180110/47cb068e/attachment.bin>
More information about the llvm-commits
mailing list