History log of /llvm-project/llvm/lib/Object/MachOObjectFile.cpp (Results 101 – 125 of 491)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# de5209bd 08-Dec-2017 Michael Trent <mtrent@apple.com>

Updated llvm-objdump to display local relocations in Mach-O binaries

Summary:
llvm-objdump's Mach-O parser was updated in r306037 to display external
relocations for MH_KEXT_BUNDLE file types. This

Updated llvm-objdump to display local relocations in Mach-O binaries

Summary:
llvm-objdump's Mach-O parser was updated in r306037 to display external
relocations for MH_KEXT_BUNDLE file types. This change extends the Macho-O
parser to display local relocations for MH_PRELOAD files. When used with
the -macho option relocations will be displayed in a historical format.

rdar://35778019

Reviewers: enderby

Reviewed By: enderby

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D40867

llvm-svn: 320166

show more ...


Revision tags: llvmorg-5.0.1, llvmorg-5.0.1-rc3, llvmorg-5.0.1-rc2, llvmorg-5.0.1-rc1
# 6f43bd4b 18-Oct-2017 NAKAMURA Takumi <geek4civic@gmail.com>

Untabify.

llvm-svn: 316079


# 1a81dfba 17-Oct-2017 Jessica Paquette <jpaquette@apple.com>

Fix typo in checkTwoLevelHintsCommand

BigSize had a copy/paste typo in it. This fixes that.

llvm-svn: 316027


# 8af2387b 26-Sep-2017 Jonas Devlieghere <jonas@devlieghere.com>

[dwarfdump] Skip 'stripped' sections

When dsymutil generates the companion file, its strips all unnecessary
sections by omitting their body and setting the offset in their
corresponding load command

[dwarfdump] Skip 'stripped' sections

When dsymutil generates the companion file, its strips all unnecessary
sections by omitting their body and setting the offset in their
corresponding load command to zero.

One such section is the .eh_frame section, as it contains runtime
information rather than debug information and is part of the __TEXT
segment. When reading this section, we would just read the number of
bytes specified in the load command, starting from offset 0 (i.e. the
beginning of the file).

Rather than trying to parse this obviously invalid section, dwarfdump
now skips this.

Differential revision: https://reviews.llvm.org/D38135

llvm-svn: 314208

show more ...


# 81f5abe1 13-Sep-2017 Jonas Devlieghere <jonas@devlieghere.com>

[MachO] Prevent heap overflow when load command extends past EOF

This patch fixes a heap-buffer-overflow when a malformed Mach-O has a
load command who's size extends past the end of the binary.

Fi

[MachO] Prevent heap overflow when load command extends past EOF

This patch fixes a heap-buffer-overflow when a malformed Mach-O has a
load command who's size extends past the end of the binary.

Fixes: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3225

Differential revision: https://reviews.llvm.org/D37439

llvm-svn: 313145

show more ...


Revision tags: llvmorg-5.0.0, llvmorg-5.0.0-rc5, llvmorg-5.0.0-rc4
# a1e97a77 28-Aug-2017 NAKAMURA Takumi <geek4civic@gmail.com>

Untabify.

llvm-svn: 311875


Revision tags: llvmorg-5.0.0-rc3
# 760e00b0 20-Aug-2017 Benjamin Kramer <benny.kra@googlemail.com>

[MachO] Use Twines more efficiently.

llvm-svn: 311291


Revision tags: llvmorg-5.0.0-rc2
# e574034f 29-Jul-2017 Alexander Shaposhnikov <shal1t712@gmail.com>

[llvm] Update MachOObjectFile::exports interface

This diff removes the second argument of the method MachOObjectFile::exports.
In all in-tree uses this argument is equal to "this" and
without this

[llvm] Update MachOObjectFile::exports interface

This diff removes the second argument of the method MachOObjectFile::exports.
In all in-tree uses this argument is equal to "this" and
without this argument the interface seems to be cleaner.

Test plan: make check-all

llvm-svn: 309462

show more ...


Revision tags: llvmorg-5.0.0-rc1
# 8100cded 24-Jul-2017 Kevin Enderby <enderby@apple.com>

Small tweak to one check in error handling to the dyld compact export
entries in libObject (done in r308690). In the case when the last node
has no children setting State.Current = Children + 1; whe

Small tweak to one check in error handling to the dyld compact export
entries in libObject (done in r308690). In the case when the last node
has no children setting State.Current = Children + 1; where that would be past
Trie.end() is actually ok since the pointer is not used with zero children.

rdar://33490512

llvm-svn: 308924

show more ...


# 3e95bd22 20-Jul-2017 Kevin Enderby <enderby@apple.com>

Add error handling to the dyld compact export entries in libObject.

lld needs a matching change for this will be my next commit.
Expect it to fail build until that matching commit is picked up by th

Add error handling to the dyld compact export entries in libObject.

lld needs a matching change for this will be my next commit.
Expect it to fail build until that matching commit is picked up by the bots.

Like the changes in r296527 for dyld bind entires and the changes in
r298883 for lazy bind, weak bind and rebase entries the export
entries are the last of the dyld compact info to have error handling added.

This follows the model of iterators that can fail that Lang Hanes
designed when fixing the problem for bad archives r275316 (or r275361).

So that iterating through the exports now terminates if there is an error
and returns an llvm::Error with an error message in all cases for malformed
input.

This change provides the plumbing for the error handling, all the needed
testing of error conditions and test cases for all of the unique error messages.

llvm-svn: 308690

show more ...


# abf10f2d 22-Jun-2017 Kevin Enderby <enderby@apple.com>

Updated llvm-objdump symbolic disassembly with x86_64 Mach-O MH_KEXT_BUNDLE
file types so it symbolically disassembles operands using the external
relocation entries.

rdar://31521343

llvm-svn: 3060

Updated llvm-objdump symbolic disassembly with x86_64 Mach-O MH_KEXT_BUNDLE
file types so it symbolically disassembles operands using the external
relocation entries.

rdar://31521343

llvm-svn: 306037

show more ...


Revision tags: llvmorg-4.0.1, llvmorg-4.0.1-rc3
# 264b5d9e 07-Jun-2017 Zachary Turner <zturner@google.com>

Move Object format code to lib/BinaryFormat.

This creates a new library called BinaryFormat that has all of
the headers from llvm/Support containing structure and layout
definitions for various type

Move Object format code to lib/BinaryFormat.

This creates a new library called BinaryFormat that has all of
the headers from llvm/Support containing structure and layout
definitions for various types of binary formats like dwarf, coff,
elf, etc as well as the code for identifying a file from its
magic.

Differential Revision: https://reviews.llvm.org/D33843

llvm-svn: 304864

show more ...


# 6bda14b3 06-Jun-2017 Chandler Carruth <chandlerc@gmail.com>

Sort the remaining #include lines in include/... and lib/....

I did this a long time ago with a janky python script, but now
clang-format has built-in support for this. I fed clang-format every
line

Sort the remaining #include lines in include/... and lib/....

I did this a long time ago with a janky python script, but now
clang-format has built-in support for this. I fed clang-format every
line with a #include and let it re-sort things according to the precise
LLVM rules for include ordering baked into clang-format these days.

I've reverted a number of files where the results of sorting includes
isn't healthy. Either places where we have legacy code relying on
particular include ordering (where possible, I'll fix these separately)
or where we have particular formatting around #include lines that
I didn't want to disturb in this patch.

This patch is *entirely* mechanical. If you get merge conflicts or
anything, just ignore the changes in this patch and run clang-format
over your #include lines in the files.

Sorry for any noise here, but it is important to keep these things
stable. I was seeing an increasing number of patches with irrelevant
re-ordering of #include lines because clang-format was used. This patch
at least isolates that churn, makes it easy to skip when resolving
conflicts, and gets us to a clean baseline (again).

llvm-svn: 304787

show more ...


# 77d3e938 06-Jun-2017 Wolfgang Pieb <Wolfgang.Pieb@sony.com>

[DWARF] Adding support for the DWARF v5 string offsets table (consumer/reader part only).

Reviewers: dblaikie, aprantl

Differential Revision: https://reviews.llvm.org/D32779

llvm-svn: 304759


# 97e2cf87 31-May-2017 Steven Wu <stevenwu@apple.com>

[MachOObject] Fix bind opcode parser error on valid opcode sequence

BIND_OPCODE_SET_DYLIB_SPECIAL_IMM(0) is a valid way to setp library
ordinal. MachOObject should set LibraryOrdinalSet even when IM

[MachOObject] Fix bind opcode parser error on valid opcode sequence

BIND_OPCODE_SET_DYLIB_SPECIAL_IMM(0) is a valid way to setp library
ordinal. MachOObject should set LibraryOrdinalSet even when IMM is zero.

llvm-svn: 304362

show more ...


Revision tags: llvmorg-4.0.1-rc2
# a25d329b 27-May-2017 George Rimar <grimar@accesssoftek.com>

Recommit "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

With fix of uninitialized variable.

Original commit message:

This change is intended to use for LLD

Recommit "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

With fix of uninitialized variable.

Original commit message:

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we need to know section which address range belongs to.

Previously it was solved on LLD side by providing fake section addresses with use of llvm::LoadedObjectInfo
interface. We assigned file offsets as addressed. Then after obtaining ranges lists, for each range we had to find section ID's.
That not only was slow, but also complicated implementation and was the reason of incorrect behavior when
sections share the same offsets, like D33176 shows.

This patch makes DWARF parsers to return section index as well. That solves problem mentioned above.

Differential revision: https://reviews.llvm.org/D33184

llvm-svn: 304078

show more ...


# 1f9cab6b 26-May-2017 George Rimar <grimar@accesssoftek.com>

Revert r304002 "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

Revert it again. Now another bot unhappy: http://lab.llvm.org:8011/builders/clang-s390x-linux/b

Revert r304002 "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

Revert it again. Now another bot unhappy: http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/8750

llvm-svn: 304011

show more ...


# bc223c63 26-May-2017 George Rimar <grimar@accesssoftek.com>

[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we ne

[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we need to know section which address range belongs to.

Previously it was solved on LLD side by providing fake section addresses with use of llvm::LoadedObjectInfo
interface. We assigned file offsets as addressed. Then after obtaining ranges lists, for each range we had to find section ID's.
That not only was slow, but also complicated implementation and was the reason of incorrect behavior when
sections share the same offsets, like D33176 shows.

This patch makes DWARF parsers to return section index as well. That solves problem mentioned above.

Differential revision: https://reviews.llvm.org/D33184

llvm-svn: 304002

show more ...


# a8403a64 26-May-2017 George Rimar <grimar@accesssoftek.com>

Revert "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

Broked BB again:

TEST 'LLVM :: DebugInfo/X86/dbg-value-regmask-clobber.ll' FAILED
...
LLVM ERROR: Sect

Revert "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

Broked BB again:

TEST 'LLVM :: DebugInfo/X86/dbg-value-regmask-clobber.ll' FAILED
...
LLVM ERROR: Section was outside of section table.

llvm-svn: 303984

show more ...


# 655b7b63 26-May-2017 George Rimar <grimar@accesssoftek.com>

Recommit r303978 "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

With fix of test compilation.

Initial commit message:

This change is intended to use for LL

Recommit r303978 "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

With fix of test compilation.

Initial commit message:

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we need to know section
which address range belongs to.

Previously it was solved on LLD side by providing fake section addresses
with use of llvm::LoadedObjectInfo interface. We assigned file offsets as addressed.
Then after obtaining ranges lists, for each range we had to find section ID's.
That not only was slow, but also complicated implementation and was the reason
of incorrect behavior when
sections share the same offsets, like D33176 shows.

This patch makes DWARF parsers to return section index as well.
That solves problem mentioned above.

Differential revision: https://reviews.llvm.org/D33184

llvm-svn: 303983

show more ...


# 7d5f1218 26-May-2017 George Rimar <grimar@accesssoftek.com>

Revert r303978 "[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC"

It failed BB.

llvm-svn: 303981


# 732f268a 26-May-2017 George Rimar <grimar@accesssoftek.com>

[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we ne

[DWARF] - Make collectAddressRanges() return section index in addition to Low/High PC

This change is intended to use for LLD in D33183.
Problem we have in LLD when building .gdb_index is that we need to know section
which address range belongs to.

Previously it was solved on LLD side by providing fake section addresses
with use of llvm::LoadedObjectInfo interface. We assigned file offsets as addressed.
Then after obtaining ranges lists, for each range we had to find section ID's.
That not only was slow, but also complicated implementation and was the reason
of incorrect behavior when
sections share the same offsets, like D33176 shows.

This patch makes DWARF parsers to return section index as well.
That solves problem mentioned above.

Differential revision: https://reviews.llvm.org/D33184

llvm-svn: 303978

show more ...


Revision tags: llvmorg-4.0.1-rc1
# 9f5094df 21-Apr-2017 Eugene Zelenko <eugene.zelenko@gmail.com>

[Object] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).

llvm-svn: 301049


# e1f12fad 11-Apr-2017 Vassil Vassilev <v.g.vassilev@gmail.com>

Remove unused functions. Remove static qualifier from functions in header files. NFC.

llvm-svn: 299947


# cad12491 30-Mar-2017 Juergen Ributzka <juergen@ributzka.de>

[Object] Remove check for BIND_OPCODE_DONE/REBASE_OPCODE_DONE.

BIND_OPCODE_DONE/REBASE_OPCODE_DONE may appear at the end of the opcode array,
but they are not required to. The linker only adds them

[Object] Remove check for BIND_OPCODE_DONE/REBASE_OPCODE_DONE.

BIND_OPCODE_DONE/REBASE_OPCODE_DONE may appear at the end of the opcode array,
but they are not required to. The linker only adds them as padding to align the
opcodes to pointer size.

This fixes rdar://problem/31285560.

llvm-svn: 299104

show more ...


12345678910>>...20