diff options
author | Jez Ng <jezng@fb.com> | 2020-06-13 19:52:20 -0700 |
---|---|---|
committer | Jez Ng <jezng@fb.com> | 2020-06-14 16:35:23 -0700 |
commit | 53c796b948f04755f67e00ac45de91d45df2b656 (patch) | |
tree | 055ebe2bc6895421d9ddd1ccbc31925f0b77c034 /llvm/lib/CodeGen/MachineCombiner.cpp | |
parent | 51c5baacf36f5d5d0dbed00590a9e56a5f4a0d73 (diff) | |
download | llvm-53c796b948f04755f67e00ac45de91d45df2b656.zip llvm-53c796b948f04755f67e00ac45de91d45df2b656.tar.gz llvm-53c796b948f04755f67e00ac45de91d45df2b656.tar.bz2 |
[lld-macho] Properly handle & validate relocation r_length
Summary:
We should be reading / writing our addends / relocated addresses based on
r_length, and not just based on the type of the relocation. But since only
some r_length values are valid for a given reloc type, I've also added some
validation.
ld64 has code to allow for r_length = 0 in X86_64_RELOC_BRANCH relocs, but I'm
not sure how to create such a relocation...
Reviewed By: smeenai
Differential Revision: https://reviews.llvm.org/D80854
Diffstat (limited to 'llvm/lib/CodeGen/MachineCombiner.cpp')
0 files changed, 0 insertions, 0 deletions