diff options
| author | Martin Storsjo <martin@martin.st> | 2018-10-11 17:45:58 +0000 |
|---|---|---|
| committer | Martin Storsjo <martin@martin.st> | 2018-10-11 17:45:58 +0000 |
| commit | 8cc0f7126144d0336c78c3fa89ddb4f0a0ac0757 (patch) | |
| tree | 02b7687dea81c2266b6e75cc315a17819ad683f1 /lld/COFF/Chunks.cpp | |
| parent | 21eb363302bec770adf67b2494aa30ff2bcf5d65 (diff) | |
| download | bcm5719-llvm-8cc0f7126144d0336c78c3fa89ddb4f0a0ac0757.tar.gz bcm5719-llvm-8cc0f7126144d0336c78c3fa89ddb4f0a0ac0757.zip | |
[COFF] Add and use a Wordsize field in Config. NFCI.
Differential Revision: https://reviews.llvm.org/D53143
llvm-svn: 344265
Diffstat (limited to 'lld/COFF/Chunks.cpp')
| -rw-r--r-- | lld/COFF/Chunks.cpp | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/lld/COFF/Chunks.cpp b/lld/COFF/Chunks.cpp index 5fb33e1190c..9808c8be6b3 100644 --- a/lld/COFF/Chunks.cpp +++ b/lld/COFF/Chunks.cpp @@ -675,9 +675,7 @@ void LocalImportChunk::getBaserels(std::vector<Baserel> *Res) { Res->emplace_back(getRVA()); } -size_t LocalImportChunk::getSize() const { - return Config->is64() ? 8 : 4; -} +size_t LocalImportChunk::getSize() const { return Config->Wordsize; } void LocalImportChunk::writeTo(uint8_t *Buf) const { if (Config->is64()) { @@ -841,9 +839,7 @@ void MergeChunk::writeTo(uint8_t *Buf) const { } // MinGW specific. -size_t AbsolutePointerChunk::getSize() const { - return Config->is64() ? 8 : 4; -} +size_t AbsolutePointerChunk::getSize() const { return Config->Wordsize; } void AbsolutePointerChunk::writeTo(uint8_t *Buf) const { if (Config->is64()) { |

