#
b07c22b0 |
| 08-May-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
[llvm-objcopy] Fix exit code
Set the exit code to 1 if no arguments are specified.
Test plan: make check-all
Differential revision: https://reviews.llvm.org/D46547
llvm-svn: 331776
|
#
cca69985 |
| 07-May-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
[tools] Introduce llvm-strip
llvm-strip is supposed to be a drop-in replacement for binutils strip. To start the ball rolling this diff adds the initial bits for llvm-strip, more features will be ad
[tools] Introduce llvm-strip
llvm-strip is supposed to be a drop-in replacement for binutils strip. To start the ball rolling this diff adds the initial bits for llvm-strip, more features will be added incrementally over time.
Test plan: make check-all
Differential revision: https://reviews.llvm.org/D46407
llvm-svn: 331663
show more ...
|
#
41695f8e |
| 02-May-2018 |
Paul Semel <semelpaul@gmail.com> |
[llvm-objcopy] Add --discard-all (-x) option
llvm-svn: 331400
|
#
2c0510f0 |
| 02-May-2018 |
Paul Semel <semelpaul@gmail.com> |
[llvm-objcopy] Add --weaken option
llvm-svn: 331397
|
#
3a8a56b8 |
| 27-Apr-2018 |
Paul Semel <semelpaul@gmail.com> |
[llvm-objcopy] Add --weaken-symbol (-W) option
llvm-svn: 331070
|
#
ee5be798 |
| 27-Apr-2018 |
Paul Semel <semelpaul@gmail.com> |
[llvm-objcopy] Add --globalize-symbol option
llvm-svn: 331068
|
#
40e9bdf9 |
| 26-Apr-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
[llvm-objcopy] Implement --redefine-sym option
This diff implements --redefine-sym option for changing the name of a symbol.
Test plan: make check-all
Differential revision: https://reviews.llvm.
[llvm-objcopy] Implement --redefine-sym option
This diff implements --redefine-sym option for changing the name of a symbol.
Test plan: make check-all
Differential revision: https://reviews.llvm.org/D46029
llvm-svn: 330973
show more ...
|
#
b492494c |
| 26-Apr-2018 |
Paul Semel <semelpaul@gmail.com> |
[llvm-objcopy] Add --localize-symbol option
llvm-svn: 330963
|
#
3326e785 |
| 24-Apr-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
[llvm-objcopy] Adjust the code for the old versions of msvc
Follow-up for r330685.
llvm-svn: 330686
|
#
d6884795 |
| 24-Apr-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
Recommit "[llvm-objcopy] Switch over to using TableGen for parsing arguments"
Add explicit dependency on ObjcopyTableGen and rerun the tests on Windows. I will double-check the build bots and rev
Recommit "[llvm-objcopy] Switch over to using TableGen for parsing arguments"
Add explicit dependency on ObjcopyTableGen and rerun the tests on Windows. I will double-check the build bots and revert this commit if necessary.
llvm-svn: 330685
show more ...
|
Revision tags: llvmorg-6.0.1-rc1 |
|
#
197194b6 |
| 13-Apr-2018 |
Rui Ueyama <ruiu@google.com> |
Define InitLLVM to do common initialization all at once.
We have a few functions that virtually all command wants to run on process startup/shutdown. This patch adds InitLLVM class to do that all at
Define InitLLVM to do common initialization all at once.
We have a few functions that virtually all command wants to run on process startup/shutdown. This patch adds InitLLVM class to do that all at once, so that we don't need to copy-n-paste boilerplate code to each llvm command's main() function.
Differential Revision: https://reviews.llvm.org/D45602
llvm-svn: 330046
show more ...
|
#
a8c689e7 |
| 12-Apr-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
Revert "[llvm-objcopy] Switch over to using TableGen for parsing arguments"
TableGen seems to work differently on windows. I'll need to revert this
This reverts commit 7a153ddea067b24da59f6a66c733d
Revert "[llvm-objcopy] Switch over to using TableGen for parsing arguments"
TableGen seems to work differently on windows. I'll need to revert this
This reverts commit 7a153ddea067b24da59f6a66c733d79205969501.
llvm-svn: 329867
show more ...
|
#
cafa1128 |
| 11-Apr-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Switch over to using TableGen for parsing arguments
Swithces from using the command line library to using TableGen. This will allow llvm-strip to exist and allow refinements of the co
[llvm-objcopy] Switch over to using TableGen for parsing arguments
Swithces from using the command line library to using TableGen. This will allow llvm-strip to exist and allow refinements of the command line syntax.
Differential Revision: https://reviews.llvm.org/D44236
llvm-svn: 329863
show more ...
|
Revision tags: llvmorg-5.0.2, llvmorg-5.0.2-rc2, llvmorg-5.0.2-rc1, llvmorg-6.0.0, llvmorg-6.0.0-rc3 |
|
#
fedb0160 |
| 09-Feb-2018 |
Alexander Shaposhnikov <shal1t712@gmail.com> |
[llvm-objcopy] Make modifications in-place if output is not specified
If the output file is not specified make the modifications in-place (like binutils objcopy does). In particular, this fixes th
[llvm-objcopy] Make modifications in-place if output is not specified
If the output file is not specified make the modifications in-place (like binutils objcopy does). In particular, this fixes the behavior of Clang -gsplit-dwarf (if Clang is configured to use llvm-objcopy), previously it was creating .dwo files, but still leaving *dwo* sections in the original binary.
Test plan: make check-all
Differential revision: https://reviews.llvm.org/D42873
llvm-svn: 324783
show more ...
|
Revision tags: llvmorg-6.0.0-rc2 |
|
#
76e9110f |
| 25-Jan-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Refactor llvm-objcopy to use reader and writer objects
While writing code for input and output formats in llvm-objcopy it became apparent that there was a code health problem. This ch
[llvm-objcopy] Refactor llvm-objcopy to use reader and writer objects
While writing code for input and output formats in llvm-objcopy it became apparent that there was a code health problem. This change attempts to solve that problem by refactoring the code to use Reader and Writer objects that can read in different objects in different formats, convert them to a single shared internal representation, and then write them to any other representation.
New classes: Reader: the base class used to construct instances of the internal representation Writer: the base class used to write out instances of the internal representation ELFBuilder: a helper class for ELFWriter that takes an ELFFile and converts it to a Object SectionVisitor: it became necessary to remove writeSection from SectionBase because, under the new Reader/Writer scheme, it's possible to convert between ELF Types such as ELF32LE and ELF32BE. This isn't possible with writeSection because it (dynamically) depends on the underlying section type *and* (statically) depends on the ELF type. Bad things would happen if the underlying sections for ELF32LE were used for writing to ELF64BE. To avoid this code smell (which would have compiled, run, and output some nonsesnse) I decoupled writing of sections from a class. SectionWriter: This is just the ELFT templated implementation of SectionVisitor. Many classes now have this class as a friend so that the writing methods in this class can write out private data. ELFWriter: This is the Writer that outputs to ELF BinaryWriter: This is the Writer that outputs to Binary ElfType: Because the ELF Type is not a part of the Object anymore we need a way to construct the correct default Writer based on properties of the Reader. This enum just keeps track of the ELF type of the input so it can be used as the default output type as well.
Object has correspondingly undergone some serious changes as well. It now has more generic methods for building and manipulating ELF binaries. This interface makes ELFBuilder easy enough to use and will make the BinaryReader/Builder easy to create as well. Most changes in this diff are cosmetic and deal with the fact that a method has been moved from one class to another or a change from a pointer to a reference. Almost no changes should result in a functional difference (this is after all a refactor). One minor functional change was made and the result can be seen in remove-shstrtab-error.test. The fact that it fails hasn't changed but the error message has changed because that failure is detected at a later point in the code now (because WriteSectionHeaders is a property of the ElfWriter *not* a property of the Object). I'd say roughly 80-90% of this code is cosmetically different, 10-19% is different but functionally the same, and 1-5% is functionally different despite not causing a change in tests.
Differential Revision: https://reviews.llvm.org/D42222
llvm-svn: 323480
show more ...
|
#
ea07d3cf |
| 25-Jan-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Add --add-gnu-debuglink
This change adds support for --add-gnu-debuglink to llvm-objcopy
Differential Revision: https://reviews.llvm.org/D41731
llvm-svn: 323477
|
#
4af88363 |
| 25-Jan-2018 |
Aaron Ballman <aaron@aaronballman.com> |
Revert r322132; it appears to be an accidental commit, based on the commit message. The original author of the commit has not commented on whether this was accidental or purposeful, so if this revert
Revert r322132; it appears to be an accidental commit, based on the commit message. The original author of the commit has not commented on whether this was accidental or purposeful, so if this revert is in error, the author can re-commit with an actual commit message.
llvm-svn: 323466
show more ...
|
#
09f46a76 |
| 25-Jan-2018 |
Aaron Ballman <aaron@aaronballman.com> |
Reverting r323463 as it appears to be an accidental commit. Regardless, it broke a lot of build bots, so reverting back to green.
http://lab.llvm.org:8011/builders/lldb-amd64-ninja-netbsd8/builds/92
Reverting r323463 as it appears to be an accidental commit. Regardless, it broke a lot of build bots, so reverting back to green.
http://lab.llvm.org:8011/builders/lldb-amd64-ninja-netbsd8/builds/9294 http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-ubuntu-fast/builds/24084 http://lab.llvm.org:8011/builders/clang-ppc64le-linux-lnt/builds/9567
llvm-svn: 323465
show more ...
|
#
df355940 |
| 25-Jan-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
tmp
llvm-svn: 323463
|
Revision tags: llvmorg-6.0.0-rc1 |
|
#
99482fda |
| 09-Jan-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
temp
llvm-svn: 322132
|
#
27a29b02 |
| 05-Jan-2018 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Add --localize-hidden option
This change adds support in llvm-objcopy for GNU objcopy's --localize-hidden option. This option changes every hidden or internal symbol into a local symb
[llvm-objcopy] Add --localize-hidden option
This change adds support in llvm-objcopy for GNU objcopy's --localize-hidden option. This option changes every hidden or internal symbol into a local symbol.
llvm-svn: 321884
show more ...
|
#
e8437de7 |
| 19-Dec-2017 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Add option to add a progbits section from a file
This change adds support for adding progbits sections with contents from a file
Differential Revision: https://reviews.llvm.org/D4121
[llvm-objcopy] Add option to add a progbits section from a file
This change adds support for adding progbits sections with contents from a file
Differential Revision: https://reviews.llvm.org/D41212
llvm-svn: 321047
show more ...
|
#
777fb00a |
| 15-Dec-2017 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Reformat everything using clang-format -i
Overtime some non-clang formatted code has creeped into llvm-objcopy. This patch fixes all of that.
Differential Revision: https://reviews.l
[llvm-objcopy] Reformat everything using clang-format -i
Overtime some non-clang formatted code has creeped into llvm-objcopy. This patch fixes all of that.
Differential Revision: https://reviews.llvm.org/D41262
llvm-svn: 320856
show more ...
|
Revision tags: llvmorg-5.0.1, llvmorg-5.0.1-rc3 |
|
#
ef3b80c5 |
| 30-Nov-2017 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Add support for --only-keep/-j and --keep
This change adds support for the --only-keep option and the -j alias as well. A common use case for these being used together is to dump a sp
[llvm-objcopy] Add support for --only-keep/-j and --keep
This change adds support for the --only-keep option and the -j alias as well. A common use case for these being used together is to dump a specific section's data. Additionally the --keep option is added (GNU objcopy doesn't have this) to avoid removing a bunch of things. This allows people to err on the side of stripping aggressively and then to keep the specific bits that they need for their application.
Differential Revision: https://reviews.llvm.org/D39021
llvm-svn: 319467
show more ...
|
Revision tags: llvmorg-5.0.1-rc2 |
|
#
6ad72d05 |
| 27-Nov-2017 |
Jake Ehrlich <jakehehrlich@google.com> |
[llvm-objcopy] Add --strip-all-gnu and change --strip-all
GNU's --strip-all doesn't strip as aggressively as it could in general. Currently llvm-objcopy copies the exact behavoir of GNU's --strip-al
[llvm-objcopy] Add --strip-all-gnu and change --strip-all
GNU's --strip-all doesn't strip as aggressively as it could in general. Currently llvm-objcopy copies the exact behavoir of GNU's --strip-all. eu-strip is used as a drop in replacement for GNU strip/objcopy in many many places without issue. eu-strip removes non-allocated sections and keeps .gnu.warning* sections. Because --strip-all will likely be the most widely used stripping option we should make --strip-all as aggressive as it can safely be. Since we have evidence from eu-strip that this is a safe option we should allow it. For those that might still have an issue afterwards I've added --strip-all-gnu as an exact drop in replacement for GNU's --strip-all as well.
llvm-svn: 319071
show more ...
|