[PATCH] D59170: [lld] [ELF] Print a better error for an archive containing a non-ELF file.
Petr Hosek via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 11 19:08:56 PDT 2019
phosek added a comment.
This seems to be failing on our Mac bots for some reason:
-- Testing: 2004 tests, 24 threads --
Testing: 0 .. 10.. 20.. 30.. 40
FAIL: lld :: ELF/invalid/invalid-elf.test (852 of 2004)
******************** TEST 'lld :: ELF/invalid/invalid-elf.test' FAILED ********************
Script:
--
: 'RUN: at line 2'; rm -rf /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp && mkdir -p /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp
: 'RUN: at line 3'; /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/llvm-mc /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/simple.o -filetype=obj -triple x86_64-pc-linux
: 'RUN: at line 4'; echo > /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/empty.o
: 'RUN: at line 5'; llvm-ar cr /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/not-elf.a /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/empty.o
: 'RUN: at line 7'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/simple.o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/not-elf.a -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=NOT-ELF /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
: 'RUN: at line 11'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/simple.o /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/Inputs/data-encoding.a -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=INVALID-DATA-ENC /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
: 'RUN: at line 15'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp/simple.o /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/Inputs/file-class.a -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=INVALID-FILE-CLASS /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
: 'RUN: at line 19'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/Inputs/binding.elf -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=INVALID-BINDING /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
: 'RUN: at line 23'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/Inputs/section-index.elf -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=INVALID-SECTION-INDEX-LLD /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
: 'RUN: at line 27'; not /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/ld.lld /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/Inputs/multiple-eh-relocs.elf -o /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/tools/lld/test/ELF/invalid/Output/invalid-elf.test.tmp2 2>&1 | /b/s/w/ir/k/recipe_cleanup/clangWrfRL9/llvm_build_dir/bin/FileCheck --check-prefix=INVALID-EH-RELOCS /b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test
--
Exit Code: 1
Command Output (stderr):
--
/b/s/w/ir/k/llvm-project/lld/test/ELF/invalid/invalid-elf.test:9:12: error: NOT-ELF: expected string not found in input
# NOT-ELF: not-elf.a(empty.o): not an ELF file
^
<stdin>:1:1: note: scanning from here
ld.lld: error: undefined symbol: foo
^
<stdin>:1:17: note: possible intended match here
ld.lld: error: undefined symbol: foo
^
--
********************
Testing: 0 .. 10.. 20.. 30.. 40.. 50.. 60.. 70.. 80.. 90..
Testing Time: 21.57s
********************
Failing Tests (1):
lld :: ELF/invalid/invalid-elf.test
Expected Passes : 1735
Unsupported Tests : 268
Unexpected Failures: 1
[451/523] Building CXX object unittests/Transforms/Vectorize/CMakeFiles/VectorizeTests.dir/VPlanPredicatorTest.cpp.o
FAILED: tools/lld/test/CMakeFiles/check-lld
The full log is here: https://logs.chromium.org/logs/fuchsia/buildbucket/cr-buildbucket.appspot.com/8919231700097735408/+/steps/clang/0/steps/test/0/stdout
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59170/new/
https://reviews.llvm.org/D59170
More information about the llvm-commits
mailing list