[all-commits] [llvm/llvm-project] 25bcd9: [llvm-objcopy] Add --update-section
PiJoules via All-commits
all-commits at lists.llvm.org
Tue Nov 16 14:12:11 PST 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 25bcd94234530955c58c6530a9271c813827637c
https://github.com/llvm/llvm-project/commit/25bcd94234530955c58c6530a9271c813827637c
Author: Leonard Chan <leonardchan at google.com>
Date: 2021-11-16 (Tue, 16 Nov 2021)
Changed paths:
A llvm/test/tools/llvm-objcopy/ELF/update-section.test
M llvm/tools/llvm-objcopy/CommonConfig.h
M llvm/tools/llvm-objcopy/ConfigManager.cpp
M llvm/tools/llvm-objcopy/ELF/ELFObjcopy.cpp
M llvm/tools/llvm-objcopy/ELF/Object.cpp
M llvm/tools/llvm-objcopy/ELF/Object.h
M llvm/tools/llvm-objcopy/ObjcopyOpts.td
Log Message:
-----------
[llvm-objcopy] Add --update-section
This is another attempt at D59351 which attempted to add --update-section, but
with some heuristics for adjusting segment/section offsets/sizes in the event
the data copied into the section is larger than the original size of the section.
We are opting to not support this case. GNU's objcopy was able to do this because
the linker and objcopy are tightly coupled enough that segment reformatting was
simpler. This is not the case with llvm-objcopy and lld where they like to be separated.
This will attempt to copy data into the section without changing any other
properties of the parent segment (if the section is part of one).
Differential Revision: https://reviews.llvm.org/D112116
More information about the All-commits
mailing list