[PATCH] D75416: [PowerPC][ELF] Place .toc in the same COMDAT group as the target object

Brandon Bergren via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 1 17:08:33 PST 2020


Bdragon28 added a comment.

Still working on testing this one.

I'm not sure if this is an artifact of my attempts to force clang to be an external toolchain or if this is a break yet.

  --- all_subdir_lib/libdevdctl ---
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in event.pico
  >>> referenced by event.cc:268 (/usr/src/lib/libdevdctl/event.cc:268)
  >>>               event.pico:(DevdCtl::Event::GetTimestamp() const)
  >>> referenced by event.cc:268 (/usr/src/lib/libdevdctl/event.cc:268)
  >>>               event.pico:(DevdCtl::Event::GetTimestamp() const)
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in exception.pico
  >>> referenced by exception.cc:94 (/usr/src/lib/libdevdctl/exception.cc:94)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by exception.cc:94 (/usr/src/lib/libdevdctl/exception.cc:94)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in exception.pico
  >>> referenced by sstream:911 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/sstream:911)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by sstream:911 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/sstream:911)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in exception.pico
  >>> referenced by istream:191 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/istream:191)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by istream:191 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/istream:191)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in exception.pico
  >>> referenced by sstream:244 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/sstream:244)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by sstream:244 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/sstream:244)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  ld: error: relocation refers to a discarded section: .toc
  >>> defined in exception.pico
  >>> referenced by iosfwd:139 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/iosfwd:139)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by iosfwd:139 (/usr/obj/usr/src/powerpc.powerpc64/tmp/usr/include/c++/v1/iosfwd:139)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by exception.cc:0 (/usr/src/lib/libdevdctl/exception.cc:0)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  >>> referenced by exception.cc:0 (/usr/src/lib/libdevdctl/exception.cc:0)
  >>>               exception.pico:(DevdCtl::ParseException::ParseException(DevdCtl::ParseException::Type, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned long))
  clang++: error: linker command failed with exit code 1 (use -v to see invocation)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75416/new/

https://reviews.llvm.org/D75416





More information about the llvm-commits mailing list