[LLVMdev] gsplit-dwarf broken on Linux?

Eric Christopher echristo at gmail.com
Fri Aug 23 00:22:39 PDT 2013


It should work and this looks like my fault with the pub names patch. I'll
get it in the morning if no one else has by then.
On Aug 23, 2013 12:11 AM, "Alexey Samsonov" <samsonov at google.com> wrote:

> Hi!
>
> Quick question - do you know if recent commits could cause this error, or
> I should go to bisect/debug this? Do we have tests that check that
> -gsplit-dwarf succeeds (i.e. compile and link step work)?
>
> $ cat a.cc
> int foo(int x) {
>   return x + 1;
> }
>
> int main() {
>   return foo(42);
> }
>
>
> $ ./bin/clang++ -gsplit-dwarf a.cc
> /tmp/a-005b1a.o(.debug_pubnames+0x6): error: undefined reference to
> '.L.debug_info_begin0'
> clang-3.3: error: linker command failed with exit code 1 (use -v to see
> invocation)
>
>
> $ ./bin/clang++ -gsplit-dwarf a.cc -###
> clang version 3.4 (189088)
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
>  "/llvm_build_clang/bin/clang-3.3" "-cc1" "-triple"
> "x86_64-unknown-linux-gnu" "-emit-obj" "-mrelax-all" "-disable-free"
> "-main-file-name" "a.cc" "-mrelocation-model" "static" "-mdisable-fp-elim"
> "-fmath-errno" "-masm-verbose" "-mconstructor-aliases" "-munwind-tables"
> "-target-cpu" "x86-64" "-g" "-backend-option" "-split-dwarf=Enable"
> "-resource-dir" "/llvm_build_clang/bin/../lib/clang/3.4"
> "-internal-isystem"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6"
> "-internal-isystem"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/x86_64-linux-gnu"
> "-internal-isystem"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/backward"
> "-internal-isystem"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/x86_64-linux-gnu/c++/4.6"
> "-internal-isystem" "/usr/local/include" "-internal-isystem"
> "/llvm_build_clang/bin/../lib/clang/3.4/include"
> "-internal-externc-isystem" "/usr/include/x86_64-linux-gnu"
> "-internal-externc-isystem" "/include" "-internal-externc-isystem"
> "/usr/include" "-fdeprecated-macro" "-fdebug-compilation-dir"
> "/llvm_build_clang" "-ferror-limit" "19" "-fmessage-length" "211"
> "-mstackrealign" "-fobjc-runtime=gcc"
> "-fobjc-default-synthesize-properties" "-fcxx-exceptions" "-fexceptions"
> "-fdiagnostics-show-option" "-fcolor-diagnostics" "-vectorize-slp" "-o"
> "/tmp/a-b567ef.o" "-x" "c++" "a.cc" "-split-dwarf-file" "a.dwo"
>  "/usr/bin/objcopy" "--extract-dwo" "/tmp/a-b567ef.o" "a.dwo"
>  "/usr/bin/objcopy" "--strip-dwo" "/tmp/a-b567ef.o"
>  "/usr/bin/ld" "-z" "relro" "--hash-style=gnu" "--build-id"
> "--eh-frame-hdr" "-m" "elf_x86_64" "-dynamic-linker"
> "/lib64/ld-linux-x86-64.so.2" "-o" "a.out"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu/crt1.o"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu/crti.o"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/crtbegin.o"
> "-L/usr/lib/gcc/x86_64-linux-gnu/4.6"
> "-L/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu"
> "-L/lib/x86_64-linux-gnu" "-L/lib/../lib64" "-L/usr/lib/x86_64-linux-gnu"
> "-L/usr/lib/gcc/x86_64-linux-gnu/4.6/../../.." "-L/lib" "-L/usr/lib"
> "/tmp/a-b567ef.o" "-lstdc++" "-lm" "-lgcc_s" "-lgcc" "-lc" "-lgcc_s"
> "-lgcc" "/usr/lib/gcc/x86_64-linux-gnu/4.6/crtend.o"
> "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu/crtn.o"
>
> $ ld --version
> GNU gold (GNU Binutils for Ubuntu 2.22) 1.11
> $ objcopy --version
> GNU objcopy (GNU Binutils) 2.23.2
>
> --
> Alexey Samsonov, MSK
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130823/0c87eab6/attachment.html>


More information about the llvm-dev mailing list