diff options
| author | Martin Storsjo <martin@martin.st> | 2019-01-11 13:47:37 +0000 |
|---|---|---|
| committer | Martin Storsjo <martin@martin.st> | 2019-01-11 13:47:37 +0000 |
| commit | d1cc64fe12dc37147723e0615fd4b140197210b0 (patch) | |
| tree | 248233f1b913127af3fa24cac4dc07e858da7e9d /llvm/test/tools/llvm-objcopy/COFF/basic-copy.test | |
| parent | 37c1e2e7a9d00b90eb48c754b2b138b1670313bc (diff) | |
| download | bcm5719-llvm-d1cc64fe12dc37147723e0615fd4b140197210b0.tar.gz bcm5719-llvm-d1cc64fe12dc37147723e0615fd4b140197210b0.zip | |
[llvm-objcopy] [COFF] Fix writing object files without symbols/string table
Previously, this was broken - by setting PointerToSymbolTable to zero
but still actually writing the string table length, the object file
header was corrupted.
Differential Revision: https://reviews.llvm.org/D56584
llvm-svn: 350926
Diffstat (limited to 'llvm/test/tools/llvm-objcopy/COFF/basic-copy.test')
| -rw-r--r-- | llvm/test/tools/llvm-objcopy/COFF/basic-copy.test | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/test/tools/llvm-objcopy/COFF/basic-copy.test b/llvm/test/tools/llvm-objcopy/COFF/basic-copy.test index ddd12dcaf2f..ecdf430faf1 100644 --- a/llvm/test/tools/llvm-objcopy/COFF/basic-copy.test +++ b/llvm/test/tools/llvm-objcopy/COFF/basic-copy.test @@ -40,3 +40,9 @@ RUN: llvm-objcopy %t.x86_64.exe %t.x86_64-copy.exe RUN: obj2yaml %t.x86_64.exe > %t.x86_64.exe.yaml RUN: obj2yaml %t.x86_64-copy.exe > %t.x86_64-copy.exe.yaml RUN: cmp %t.x86_64.exe.yaml %t.x86_64-copy.exe.yaml + +RUN: yaml2obj %p/Inputs/no-symbols.yaml > %t.no-symbols.o +RUN: llvm-objcopy %t.no-symbols.o %t.no-symbols-copy.o +RUN: obj2yaml %t.no-symbols.o > %t.no-symbols.o.yaml +RUN: obj2yaml %t.no-symbols-copy.o > %t.no-symbols-copy.o.yaml +RUN: cmp %t.no-symbols.o.yaml %t.no-symbols-copy.o.yaml |

