[llvm-bugs] [Bug 34648] New: segfault while linking LLVM's readline library
via llvm-bugs
llvm-bugs at lists.llvm.org
Sun Sep 17 01:43:43 PDT 2017
https://bugs.llvm.org/show_bug.cgi?id=34648
Bug ID: 34648
Summary: segfault while linking LLVM's readline library
Product: lld
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: ELF
Assignee: unassignedbugs at nondot.org
Reporter: phosek at chromium.org
CC: llvm-bugs at lists.llvm.org
Reproducer is https://storage.googleapis.com/fuchsia-build/lld-crash.cpio
"/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/./bin/ld.lld"
--sysroot=/usr/local/google/home/phosek/fuchsia/build/linux/sysroot
--hash-style=both --eh-frame-hdr -m elf_x86_64 -shared -o lib/readline.so
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu/crti.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/crtbeginS.o
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib/x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib/../lib64
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../..
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib -z defs
--color-diagnostics -soname readline.so
tools/lldb/scripts/Python/modules/readline/CMakeFiles/readline.dir/readline.cpp.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/x86_64-linux-gnu/libpython2.7.a
-ledit -lstdc++ -lm -lgcc_s -lc -lgcc_s
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/crtendS.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu/crtn.o
--reproduce lld-crash.cpio
#0 0x00000000022b4049 llvm::sys::PrintStackTrace(llvm::raw_ostream&)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../lib/Support/Unix/Signals.inc:398:11
#1 0x00000000022b41f9 PrintStackTraceSignalHandler(void*)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../lib/Support/Unix/Signals.inc:462:1
#2 0x00000000022b27a3 llvm::sys::RunSignalHandlers()
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../lib/Support/Signals.cpp:0:5
#3 0x00000000022b4554 SignalHandler(int)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../lib/Support/Unix/Signals.inc:252:1
#4 0x00007fe85b3820c0 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x110c0)
#5 0x00000000024fab22
lld::elf::EhFrameSection<llvm::object::ELFType<(llvm::support::endianness)1,
true> >::finalizeContents()
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/SyntheticSections.cpp:541:30
#6 0x000000000257fb65 (anonymous
namespace)::Writer<llvm::object::ELFType<(llvm::support::endianness)1, true>
>::finalizeSections()::{lambda(lld::elf::SyntheticSection*)#1}::operator()(lld::elf::SyntheticSection*)
const
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Writer.cpp:1263:69
#7 0x000000000257fa22 std::_Function_handler<void
(lld::elf::SyntheticSection*), (anonymous
namespace)::Writer<llvm::object::ELFType<(llvm::support::endianness)1, true>
>::finalizeSections()::{lambda(lld::elf::SyntheticSection*)#1}>::_M_invoke(std::_Any_data
const&, lld::elf::SyntheticSection*&&)
/usr/lib/gcc/x86_64-linux-gnu/6.3.0/../../../../include/c++/6.3.0/functional:1733:7
#8 0x0000000002596ed8 std::function<void
(lld::elf::SyntheticSection*)>::operator()(lld::elf::SyntheticSection*) const
/usr/lib/gcc/x86_64-linux-gnu/6.3.0/../../../../include/c++/6.3.0/functional:2127:7
#9 0x0000000002562c03 applySynthetic(std::vector<lld::elf::SyntheticSection*,
std::allocator<lld::elf::SyntheticSection*> > const&, std::function<void
(lld::elf::SyntheticSection*)>)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Writer.cpp:1158:3
#10 0x000000000257a598 (anonymous
namespace)::Writer<llvm::object::ELFType<(llvm::support::endianness)1, true>
>::finalizeSections()
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Writer.cpp:1262:3
#11 0x000000000255bdfc (anonymous
namespace)::Writer<llvm::object::ELFType<(llvm::support::endianness)1, true>
>::run()
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Writer.cpp:190:3
#12 0x000000000258f712 void
lld::elf::writeResult<llvm::object::ELFType<(llvm::support::endianness)1, true>
>()
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Writer.cpp:123:64
#13 0x00000000023a6cb0 void
lld::elf::LinkerDriver::link<llvm::object::ELFType<(llvm::support::endianness)1,
true> >(llvm::opt::InputArgList&)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Driver.cpp:1091:1
#14 0x0000000002394e8a lld::elf::LinkerDriver::main(llvm::ArrayRef<char
const*>, bool)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Driver.cpp:386:5
#15 0x000000000239468d lld::elf::link(llvm::ArrayRef<char const*>, bool,
llvm::raw_ostream&)
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/ELF/Driver.cpp:87:3
#16 0x00000000021f02e8 main
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/../../tools/lld/tools/lld/lld.cpp:116:12
#17 0x00007fe859b4a2b1 __libc_start_main
(/lib/x86_64-linux-gnu/libc.so.6+0x202b1)
#18 0x00000000021f002a _start
(/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/./bin/ld.lld+0x21f002a)
Stack dump:
0. Program arguments:
/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/./bin/ld.lld
--sysroot=/usr/local/google/home/phosek/fuchsia/build/linux/sysroot
--hash-style=both --eh-frame-hdr -m elf_x86_64 -shared -o lib/readline.so
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu/crti.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/crtbeginS.o
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib/x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib/../lib64
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/x86_64-linux-gnu
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../..
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/lib
-L/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib -z defs
--color-diagnostics -soname readline.so
tools/lldb/scripts/Python/modules/readline/CMakeFiles/readline.dir/readline.cpp.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/x86_64-linux-gnu/libpython2.7.a
-ledit -lstdc++ -lm -lgcc_s -lc -lgcc_s
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/crtendS.o
/usr/local/google/home/phosek/fuchsia/build/linux/sysroot/usr/lib/gcc/x86_64-linux-gnu/6/../../../x86_64-linux-gnu/crtn.o
--reproduce lld-crash.cpio
zsh: segmentation fault
"/usr/local/google/home/phosek/clang-llvm/llvm/out/lld/./bin/ld.lld" -m
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20170917/dc6c737b/attachment-0001.html>
More information about the llvm-bugs
mailing list